3v4l.org

run code in 300+ PHP versions simultaneously
<?php $p = 80; $c = 0.05; $s = 837; $f = 15; $w = 4; $h = 0; for ($m=0; $m <= $w; $m++) { $j = 0; for ($i=0; $i<$s * $p; $i++) { if (mt_rand(0, 100) <= $c * 100) { $h = max($h, $j); $j = 0; } else { $j += $f; } } } var_dump($h);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 31
Branch analysis from position: 31
2 jumps found. (Code = 44) Position 1 = 33, Position 2 = 8
Branch analysis from position: 33
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 11
Branch analysis from position: 30
2 jumps found. (Code = 44) Position 1 = 33, Position 2 = 8
Branch analysis from position: 33
Branch analysis from position: 8
Branch analysis from position: 11
2 jumps found. (Code = 43) Position 1 = 18, Position 2 = 25
Branch analysis from position: 18
1 jumps found. (Code = 42) Position 1 = 26
Branch analysis from position: 26
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 11
Branch analysis from position: 30
Branch analysis from position: 11
Branch analysis from position: 25
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 11
Branch analysis from position: 30
Branch analysis from position: 11
filename:       /in/YfY1f
function name:  (null)
number of ops:  37
compiled vars:  !0 = $p, !1 = $c, !2 = $s, !3 = $f, !4 = $w, !5 = $h, !6 = $m, !7 = $j, !8 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 80
    4     1        ASSIGN                                                   !1, 0.05
    5     2        ASSIGN                                                   !2, 837
    6     3        ASSIGN                                                   !3, 15
    7     4        ASSIGN                                                   !4, 4
    9     5        ASSIGN                                                   !5, 0
   11     6        ASSIGN                                                   !6, 0
          7      > JMP                                                      ->31
   12     8    >   ASSIGN                                                   !7, 0
   13     9        ASSIGN                                                   !8, 0
         10      > JMP                                                      ->27
   14    11    >   INIT_FCALL                                               'mt_rand'
         12        SEND_VAL                                                 0
         13        SEND_VAL                                                 100
         14        DO_ICALL                                         $18     
         15        MUL                                              ~19     !1, 100
         16        IS_SMALLER_OR_EQUAL                                      $18, ~19
         17      > JMPZ                                                     ~20, ->25
   15    18    >   INIT_FCALL                                               'max'
         19        SEND_VAR                                                 !5
         20        SEND_VAR                                                 !7
         21        DO_ICALL                                         $21     
         22        ASSIGN                                                   !5, $21
   16    23        ASSIGN                                                   !7, 0
         24      > JMP                                                      ->26
   18    25    >   ASSIGN_OP                                     1          !7, !3
   13    26    >   PRE_INC                                                  !8
         27    >   MUL                                              ~26     !2, !0
         28        IS_SMALLER                                               !8, ~26
         29      > JMPNZ                                                    ~27, ->11
   11    30    >   PRE_INC                                                  !6
         31    >   IS_SMALLER_OR_EQUAL                                      !6, !4
         32      > JMPNZ                                                    ~29, ->8
   23    33    >   INIT_FCALL                                               'var_dump'
         34        SEND_VAR                                                 !5
         35        DO_ICALL                                                 
         36      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.58 ms | 1400 KiB | 19 Q