3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Container { private $a; private $b; private $c; public function __construct($a, $b, $c) { $this->a = $a; $this->b = $b; $this->c = $c; } public function getA() { return $this->a; } public function getB() { return $this->a; } public function getC() { return $this->a; } } class Clazz { private $a; private $b; private $c; private $d; private $e; public function __construct(Container $container, $d, $e) { $this->a = $container->getA(); $this->b = $container->getB(); $this->c = $container->getC(); $this->d = $d; $this->e = $e; } } $classes = array(); for ($i = 0; $i < 50000; $i++) { $classes[] = new Clazz(new Container('a', 'b', 'c'), 'd', 'e'); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 16
Branch analysis from position: 16
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 3
Branch analysis from position: 18
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 3
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 3
Branch analysis from position: 18
Branch analysis from position: 3
filename:       /in/pZTGj
function name:  (null)
number of ops:  19
compiled vars:  !0 = $classes, !1 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   50     0  E >   ASSIGN                                                   !0, <array>
   52     1        ASSIGN                                                   !1, 0
          2      > JMP                                                      ->16
   53     3    >   NEW                                              $5      'Clazz'
          4        NEW                                              $6      'Container'
          5        SEND_VAL_EX                                              'a'
          6        SEND_VAL_EX                                              'b'
          7        SEND_VAL_EX                                              'c'
          8        DO_FCALL                                      0          
          9        SEND_VAR_NO_REF_EX                                       $6
         10        SEND_VAL_EX                                              'd'
         11        SEND_VAL_EX                                              'e'
         12        DO_FCALL                                      0          
         13        ASSIGN_DIM                                               !0
         14        OP_DATA                                                  $5
   52    15        PRE_INC                                                  !1
         16    >   IS_SMALLER                                               !1, 50000
         17      > JMPNZ                                                    ~10, ->3
   54    18    > > RETURN                                                   1

Class Container:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pZTGj
function name:  __construct
number of ops:  10
compiled vars:  !0 = $a, !1 = $b, !2 = $c
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
   11     3        ASSIGN_OBJ                                               'a'
          4        OP_DATA                                                  !0
   12     5        ASSIGN_OBJ                                               'b'
          6        OP_DATA                                                  !1
   13     7        ASSIGN_OBJ                                               'c'
          8        OP_DATA                                                  !2
   14     9      > RETURN                                                   null

End of function __construct

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

End of function geta

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

End of function getb

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

End of function getc

End of class Container.

Class Clazz:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pZTGj
function name:  __construct
number of ops:  20
compiled vars:  !0 = $container, !1 = $d, !2 = $e
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   40     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
   42     3        INIT_METHOD_CALL                                         !0, 'getA'
          4        DO_FCALL                                      0  $4      
          5        ASSIGN_OBJ                                               'a'
          6        OP_DATA                                                  $4
   43     7        INIT_METHOD_CALL                                         !0, 'getB'
          8        DO_FCALL                                      0  $6      
          9        ASSIGN_OBJ                                               'b'
         10        OP_DATA                                                  $6
   44    11        INIT_METHOD_CALL                                         !0, 'getC'
         12        DO_FCALL                                      0  $8      
         13        ASSIGN_OBJ                                               'c'
         14        OP_DATA                                                  $8
   45    15        ASSIGN_OBJ                                               'd'
         16        OP_DATA                                                  !1
   46    17        ASSIGN_OBJ                                               'e'
         18        OP_DATA                                                  !2
   47    19      > RETURN                                                   null

End of function __construct

End of class Clazz.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.53 ms | 1399 KiB | 13 Q