3v4l.org

run code in 300+ PHP versions simultaneously
<?php function bcfact($n){ $factorial=$n; while (--$n>1) $factorial=bcmul($factorial,$n); return $factorial; } print bcfact(50);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/NZUHT
function name:  (null)
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   INIT_FCALL                                               'bcfact'
          1        SEND_VAL                                                 50
          2        DO_FCALL                                      0  $0      
          3        ECHO                                                     $0
          4      > RETURN                                                   1

Function bcfact:
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 = 11, Position 2 = 3
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 3
2 jumps found. (Code = 44) Position 1 = 11, Position 2 = 3
Branch analysis from position: 11
Branch analysis from position: 3
filename:       /in/NZUHT
function name:  bcfact
number of ops:  13
compiled vars:  !0 = $n, !1 = $factorial
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        ASSIGN                                                   !1, !0
    5     2      > JMP                                                      ->8
          3    >   INIT_FCALL_BY_NAME                                       'bcmul'
          4        SEND_VAR_EX                                              !1
          5        SEND_VAR_EX                                              !0
          6        DO_FCALL                                      0  $3      
          7        ASSIGN                                                   !1, $3
          8    >   PRE_DEC                                          ~5      !0
          9        IS_SMALLER                                               1, ~5
         10      > JMPNZ                                                    ~6, ->3
    6    11    > > RETURN                                                   !1
    7    12*     > RETURN                                                   null

End of function bcfact

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.23 ms | 1398 KiB | 14 Q