3v4l.org

run code in 300+ PHP versions simultaneously
<?php function how_much_i_love_you($nb_petals) { $count = 0; $phrases = array( "I love you", "a little", "a lot", "passionately", "madly", "not at all" ); while($count < $nb_petals) { if ($count == $nb_petals) { break; } else { $count++; if ($count == 6) { $count = 0; } } } echo $phrases[$count]; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/kKB7M
function name:  (null)
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   26     0  E > > RETURN                                                   1

Function how_much_i_love_you:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
2 jumps found. (Code = 44) Position 1 = 14, Position 2 = 4
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 4
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 8
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 14
Branch analysis from position: 14
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 11, Position 2 = 12
Branch analysis from position: 11
2 jumps found. (Code = 44) Position 1 = 14, Position 2 = 4
Branch analysis from position: 14
Branch analysis from position: 4
Branch analysis from position: 12
filename:       /in/kKB7M
function name:  how_much_i_love_you
number of ops:  17
compiled vars:  !0 = $nb_petals, !1 = $count, !2 = $phrases
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        ASSIGN                                                   !1, 0
    5     2        ASSIGN                                                   !2, <array>
   14     3      > JMP                                                      ->12
   15     4    >   IS_EQUAL                                                 !1, !0
          5      > JMPZ                                                     ~5, ->8
   16     6    > > JMP                                                      ->14
          7*       JMP                                                      ->12
   18     8    >   PRE_INC                                                  !1
   19     9        IS_EQUAL                                                 !1, 6
         10      > JMPZ                                                     ~7, ->12
   20    11    >   ASSIGN                                                   !1, 0
   14    12    >   IS_SMALLER                                               !1, !0
         13      > JMPNZ                                                    ~9, ->4
   25    14    >   FETCH_DIM_R                                      ~10     !2, !1
         15        ECHO                                                     ~10
   26    16      > RETURN                                                   null

End of function how_much_i_love_you

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
169.93 ms | 1394 KiB | 13 Q