3v4l.org

run code in 300+ PHP versions simultaneously
<?php function a() { $count = 2; if ($count >= 5) return false; for($suffix = 0; $suffix <= 4; $suffix++){ if($suffix == 0 || $suffix == 1) { if ($count++ >= 4) return false; } } return true; } var_dump(a());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/nShjr
function name:  (null)
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   INIT_FCALL                                               'var_dump'
          1        INIT_FCALL                                               'a'
          2        DO_FCALL                                      0  $0      
          3        SEND_VAR                                                 $0
          4        DO_ICALL                                                 
          5      > RETURN                                                   1

Function a:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 4
Branch analysis from position: 3
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 16
Branch analysis from position: 16
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 6
Branch analysis from position: 18
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 6
2 jumps found. (Code = 47) Position 1 = 8, Position 2 = 10
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 11, Position 2 = 15
Branch analysis from position: 11
2 jumps found. (Code = 43) Position 1 = 14, Position 2 = 15
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 15
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 6
Branch analysis from position: 18
Branch analysis from position: 6
Branch analysis from position: 15
Branch analysis from position: 10
filename:       /in/nShjr
function name:  a
number of ops:  20
compiled vars:  !0 = $count, !1 = $suffix
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, 2
    5     1        IS_SMALLER_OR_EQUAL                                      5, !0
          2      > JMPZ                                                     ~3, ->4
          3    > > RETURN                                                   <false>
    6     4    >   ASSIGN                                                   !1, 0
          5      > JMP                                                      ->16
    7     6    >   IS_EQUAL                                         ~5      !1, 0
          7      > JMPNZ_EX                                         ~5      ~5, ->10
          8    >   IS_EQUAL                                         ~6      !1, 1
          9        BOOL                                             ~5      ~6
         10    > > JMPZ                                                     ~5, ->15
    8    11    >   POST_INC                                         ~7      !0
         12        IS_SMALLER_OR_EQUAL                                      4, ~7
         13      > JMPZ                                                     ~8, ->15
         14    > > RETURN                                                   <false>
    6    15    >   PRE_INC                                                  !1
         16    >   IS_SMALLER_OR_EQUAL                                      !1, 4
         17      > JMPNZ                                                    ~10, ->6
   11    18    > > RETURN                                                   <true>
   12    19*     > RETURN                                                   null

End of function a

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.98 ms | 1398 KiB | 16 Q