3v4l.org

run code in 300+ PHP versions simultaneously
<?php $weight = (int) '5'; $height = (int) '4'; $unit = 'metric'; $message = ""; if($unit == "metric") { $bmiCalc = $weight/($height*$height); #This Line $message = "Metric BMI: $bmiCalc"; } else { $bmiCalc = ($weight * 703)/($height * $height); $message = "Imperial BMI: $bmiCalc"; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 15
Branch analysis from position: 8
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/AASDL
function name:  (null)
number of ops:  23
compiled vars:  !0 = $weight, !1 = $height, !2 = $unit, !3 = $message, !4 = $bmiCalc
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   CAST                                          4  ~5      '5'
          1        ASSIGN                                                   !0, ~5
    5     2        CAST                                          4  ~7      '4'
          3        ASSIGN                                                   !1, ~7
    6     4        ASSIGN                                                   !2, 'metric'
    7     5        ASSIGN                                                   !3, ''
    9     6        IS_EQUAL                                                 !2, 'metric'
          7      > JMPZ                                                     ~11, ->15
   11     8    >   MUL                                              ~12     !1, !1
          9        DIV                                              ~13     !0, ~12
         10        ASSIGN                                                   !4, ~13
   12    11        NOP                                                      
         12        FAST_CONCAT                                      ~15     'Metric+BMI%3A+', !4
         13        ASSIGN                                                   !3, ~15
         14      > JMP                                                      ->22
   16    15    >   MUL                                              ~17     !0, 703
         16        MUL                                              ~18     !1, !1
         17        DIV                                              ~19     ~17, ~18
         18        ASSIGN                                                   !4, ~19
   17    19        NOP                                                      
         20        FAST_CONCAT                                      ~21     'Imperial+BMI%3A+', !4
         21        ASSIGN                                                   !3, ~21
   18    22    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
190.3 ms | 1398 KiB | 13 Q