3v4l.org

run code in 300+ PHP versions simultaneously
<?php $b = function ($i) { return 'Called '.$i.' times'; }; for ($i = 0; $i < 5000; $i++) { call_user_func($b, $i); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
2 jumps found. (Code = 44) Position 1 = 10, Position 2 = 4
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 4
2 jumps found. (Code = 44) Position 1 = 10, Position 2 = 4
Branch analysis from position: 10
Branch analysis from position: 4
filename:       /in/K7NPh
function name:  (null)
number of ops:  11
compiled vars:  !0 = $b, !1 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FK7NPh%3A3%240'
          1        ASSIGN                                                   !0, ~2
    7     2        ASSIGN                                                   !1, 0
          3      > JMP                                                      ->8
    8     4    >   INIT_USER_CALL                                1          'call_user_func', !0
          5        SEND_USER                                                !1
          6        DO_FCALL                                      0          
    7     7        PRE_INC                                                  !1
          8    >   IS_SMALLER                                               !1, 5000
          9      > JMPNZ                                                    ~7, ->4
    9    10    > > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FK7NPh%3A3%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/K7NPh
function name:  {closure}
number of ops:  5
compiled vars:  !0 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        CONCAT                                           ~1      'Called+', !0
          2        CONCAT                                           ~2      ~1, '+times'
          3      > RETURN                                                   ~2
    5     4*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FK7NPh%3A3%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
141.35 ms | 1393 KiB | 13 Q