3v4l.org

run code in 300+ PHP versions simultaneously
<?php function test($var) { //$GLOBALS['a']++; //$var++; //debug_zval_dump($var); //$GLOBALS['var']++; echo $var; //echo $GLOBALS['a']; // echo $GLOBALS['var']; } $a = 0; $GLOBALS['a']++; debug_zval_dump($a); test($a); echo $GLOBALS['a']; echo $a;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sJL96
function name:  (null)
number of ops:  15
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   ASSIGN                                                   !0, 0
   16     1        FETCH_RW                     global              $2      'GLOBALS'
          2        FETCH_DIM_RW                                     $3      $2, 'a'
          3        PRE_INC                                                  $3
   17     4        INIT_FCALL                                               'debug_zval_dump'
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                                 
   18     7        INIT_FCALL                                               'test'
          8        SEND_VAR                                                 !0
          9        DO_FCALL                                      0          
   19    10        FETCH_R                      global              ~7      'GLOBALS'
         11        FETCH_DIM_R                                      ~8      ~7, 'a'
         12        ECHO                                                     ~8
   20    13        ECHO                                                     !0
         14      > RETURN                                                   1

Function test:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sJL96
function name:  test
number of ops:  3
compiled vars:  !0 = $var
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
   10     1        ECHO                                                     !0
   13     2      > RETURN                                                   null

End of function test

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.46 ms | 1397 KiB | 16 Q