3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Example { static $count; function __construct() { $this->count++; } function getCount() { return $this->count; } } $instance = new Example(); echo $instance->getCount(); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/mW024
function name:  (null)
number of ops:  7
compiled vars:  !0 = $instance
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   21     0  E >   NEW                                              $1      'Example'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   22     3        INIT_METHOD_CALL                                         !0, 'getCount'
          4        DO_FCALL                                      0  $4      
          5        ECHO                                                     $4
   24     6      > RETURN                                                   1

Class Example:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/mW024
function name:  __construct
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   PRE_INC_OBJ                                              'count'
   11     1      > RETURN                                                   null

End of function __construct

Function getcount:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/mW024
function name:  getCount
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   FETCH_OBJ_R                                      ~0      'count'
          1      > RETURN                                                   ~0
   17     2*     > RETURN                                                   null

End of function getcount

End of class Example.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.15 ms | 1394 KiB | 13 Q