3v4l.org

run code in 300+ PHP versions simultaneously
<?php function which_is_lower($a, $b) { if ( $a < $b ) { return $a; } else { return $b; } } function compare_comparisons($a, $b) { echo 'min() gives: '; var_dump( min($a, $b) ); echo 'comparison with < gives: '; var_dump( which_is_lower($a, $b) ); } compare_comparisons(100, TRUE);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pRSYi
function name:  (null)
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   23     0  E >   INIT_FCALL                                               'compare_comparisons'
          1        SEND_VAL                                                 100
          2        SEND_VAL                                                 <true>
          3        DO_FCALL                                      0          
          4      > RETURN                                                   1

Function which_is_lower:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 6
Branch analysis from position: 4
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pRSYi
function name:  which_is_lower
number of ops:  8
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    5     2        IS_SMALLER                                               !0, !1
          3      > JMPZ                                                     ~2, ->6
    7     4    > > RETURN                                                   !0
          5*       JMP                                                      ->7
   11     6    > > RETURN                                                   !1
   13     7*     > RETURN                                                   null

End of function which_is_lower

Function compare_comparisons:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pRSYi
function name:  compare_comparisons
number of ops:  19
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   17     2        ECHO                                                     'min%28%29+gives%3A+'
   18     3        INIT_FCALL                                               'var_dump'
          4        INIT_FCALL                                               'min'
          5        SEND_VAR                                                 !0
          6        SEND_VAR                                                 !1
          7        DO_ICALL                                         $2      
          8        SEND_VAR                                                 $2
          9        DO_ICALL                                                 
   19    10        ECHO                                                     'comparison+with+%3C+gives%3A+'
   20    11        INIT_FCALL                                               'var_dump'
         12        INIT_FCALL                                               'which_is_lower'
         13        SEND_VAR                                                 !0
         14        SEND_VAR                                                 !1
         15        DO_FCALL                                      0  $4      
         16        SEND_VAR                                                 $4
         17        DO_ICALL                                                 
   21    18      > RETURN                                                   null

End of function compare_comparisons

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
157.74 ms | 1390 KiB | 19 Q