3v4l.org

run code in 300+ PHP versions simultaneously
<?php $root = new DOMDocument(); $root->loadXML('<article id=""></article>'); for($i=0;$i<=3000;$i++){ $node = new DOMDocument(); $node->loadXML('<section id="'.$i.'"><h1>Überschrift1</h1><h2>Überschrift2</h2><p>Content</p></section>'); $node = $root->importNode($node->documentElement, true); $root->documentElement->appendChild($node); } print $root->saveXML();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 28
Branch analysis from position: 28
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 8
Branch analysis from position: 30
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 8
Branch analysis from position: 30
Branch analysis from position: 8
filename:       /in/f6WVY
function name:  (null)
number of ops:  34
compiled vars:  !0 = $root, !1 = $i, !2 = $node
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $3      'DOMDocument'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $3
    4     3        INIT_METHOD_CALL                                         !0, 'loadXML'
          4        SEND_VAL_EX                                              '%3Carticle+id%3D%22%22%3E%3C%2Farticle%3E'
          5        DO_FCALL                                      0          
    5     6        ASSIGN                                                   !1, 0
          7      > JMP                                                      ->28
    6     8    >   NEW                                              $8      'DOMDocument'
          9        DO_FCALL                                      0          
         10        ASSIGN                                                   !2, $8
    7    11        INIT_METHOD_CALL                                         !2, 'loadXML'
         12        CONCAT                                           ~11     '%3Csection+id%3D%22', !1
         13        CONCAT                                           ~12     ~11, '%22%3E%3Ch1%3E%C3%9Cberschrift1%3C%2Fh1%3E%3Ch2%3E%C3%9Cberschrift2%3C%2Fh2%3E%3Cp%3EContent%3C%2Fp%3E%3C%2Fsection%3E'
         14        SEND_VAL_EX                                              ~12
         15        DO_FCALL                                      0          
    9    16        INIT_METHOD_CALL                                         !0, 'importNode'
         17        CHECK_FUNC_ARG                                           
         18        FETCH_OBJ_FUNC_ARG                               $14     !2, 'documentElement'
         19        SEND_FUNC_ARG                                            $14
         20        SEND_VAL_EX                                              <true>
         21        DO_FCALL                                      0  $15     
         22        ASSIGN                                                   !2, $15
   10    23        FETCH_OBJ_R                                      ~17     !0, 'documentElement'
         24        INIT_METHOD_CALL                                         ~17, 'appendChild'
         25        SEND_VAR_EX                                              !2
         26        DO_FCALL                                      0          
    5    27        PRE_INC                                                  !1
         28    >   IS_SMALLER_OR_EQUAL                                      !1, 3000
         29      > JMPNZ                                                    ~20, ->8
   12    30    >   INIT_METHOD_CALL                                         !0, 'saveXML'
         31        DO_FCALL                                      0  $21     
         32        ECHO                                                     $21
         33      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.29 ms | 1395 KiB | 13 Q