3v4l.org

run code in 300+ PHP versions simultaneously
<?php $ar= array(); function ad($a=''){ if(is_int($a)){ $ar[] = $a.'int'; }else{ $ar[] = $a.'not'; } } ad(); ad(2); ad('2'); ad(2.5); ad(0); ad(1); print_r($ar);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hUCU0
function name:  (null)
number of ops:  22
compiled vars:  !0 = $ar
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
   10     1        INIT_FCALL                                               'ad'
          2        DO_FCALL                                      0          
   11     3        INIT_FCALL                                               'ad'
          4        SEND_VAL                                                 2
          5        DO_FCALL                                      0          
   12     6        INIT_FCALL                                               'ad'
          7        SEND_VAL                                                 '2'
          8        DO_FCALL                                      0          
   13     9        INIT_FCALL                                               'ad'
         10        SEND_VAL                                                 2.5
         11        DO_FCALL                                      0          
   14    12        INIT_FCALL                                               'ad'
         13        SEND_VAL                                                 0
         14        DO_FCALL                                      0          
   15    15        INIT_FCALL                                               'ad'
         16        SEND_VAL                                                 1
         17        DO_FCALL                                      0          
   16    18        INIT_FCALL                                               'print_r'
         19        SEND_VAR                                                 !0
         20        DO_ICALL                                                 
         21      > RETURN                                                   1

Function ad:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 7
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hUCU0
function name:  ad
number of ops:  11
compiled vars:  !0 = $a, !1 = $ar
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV_INIT                                        !0      ''
    4     1        TYPE_CHECK                                   16          !0
          2      > JMPZ                                                     ~2, ->7
    5     3    >   CONCAT                                           ~4      !0, 'int'
          4        ASSIGN_DIM                                               !1
          5        OP_DATA                                                  ~4
          6      > JMP                                                      ->10
    7     7    >   CONCAT                                           ~6      !0, 'not'
          8        ASSIGN_DIM                                               !1
          9        OP_DATA                                                  ~6
    9    10    > > RETURN                                                   null

End of function ad

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.76 ms | 1399 KiB | 21 Q