3v4l.org

run code in 300+ PHP versions simultaneously
<?php $tries = 0; $regenerateLimit = 10; do { if ($tries++ > $regenerateLimit) { throw new \RuntimeException(sprintf('Generation failed after %d tries', $tries)); } if ($tries == 1) { $orderNumber = 2; } else if ($tries == 2) { $orderNumber = 5; } else { $orderNumber = 7; } } while (in_array($orderNumber, [2, 5])); echo $orderNumber;
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 13
Branch analysis from position: 5
1 jumps found. (Code = 108) Position 1 = -2
Branch analysis from position: 13
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 17
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
2 jumps found. (Code = 44) Position 1 = 27, Position 2 = 2
Branch analysis from position: 27
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 2
Branch analysis from position: 17
2 jumps found. (Code = 43) Position 1 = 19, Position 2 = 21
Branch analysis from position: 19
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
Branch analysis from position: 21
2 jumps found. (Code = 44) Position 1 = 27, Position 2 = 2
Branch analysis from position: 27
Branch analysis from position: 2
filename:       /in/p7Cge
function name:  (null)
number of ops:  29
compiled vars:  !0 = $tries, !1 = $regenerateLimit, !2 = $orderNumber
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 0
    4     1        ASSIGN                                                   !1, 10
    8     2    >   POST_INC                                         ~5      !0
          3        IS_SMALLER                                               !1, ~5
          4      > JMPZ                                                     ~6, ->13
    9     5    >   NEW                                              $7      'RuntimeException'
          6        INIT_FCALL                                               'sprintf'
          7        SEND_VAL                                                 'Generation+failed+after+%25d+tries'
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                         $8      
         10        SEND_VAR_NO_REF_EX                                       $8
         11        DO_FCALL                                      0          
         12      > THROW                                         0          $7
   12    13    >   IS_EQUAL                                                 !0, 1
         14      > JMPZ                                                     ~10, ->17
   13    15    >   ASSIGN                                                   !2, 2
         16      > JMP                                                      ->22
   14    17    >   IS_EQUAL                                                 !0, 2
         18      > JMPZ                                                     ~12, ->21
   15    19    >   ASSIGN                                                   !2, 5
         20      > JMP                                                      ->22
   17    21    >   ASSIGN                                                   !2, 7
   20    22    >   INIT_FCALL                                               'in_array'
         23        SEND_VAR                                                 !2
         24        SEND_VAL                                                 <array>
         25        DO_ICALL                                         $15     
         26      > JMPNZ                                                    $15, ->2
   22    27    >   ECHO                                                     !2
         28      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
159.41 ms | 1396 KiB | 17 Q