3v4l.org

run code in 300+ PHP versions simultaneously
<?php $size = 9; $space = " "; $center = ceil($size/2); $maxPost = abs($center - $size); for ($i=0; $i<$size; $i++) { $post = abs($center + $i - $size); $pre = $maxPost - $post; echo str_repeat($space,$pre); echo "x "; echo str_repeat($space, $post); if ($post > 0) { echo str_repeat($space, $post-1); echo "x "; echo str_repeat($space, $pre); } echo "\n"; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 49
Branch analysis from position: 49
2 jumps found. (Code = 44) Position 1 = 51, Position 2 = 14
Branch analysis from position: 51
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 14
2 jumps found. (Code = 43) Position 1 = 35, Position 2 = 47
Branch analysis from position: 35
2 jumps found. (Code = 44) Position 1 = 51, Position 2 = 14
Branch analysis from position: 51
Branch analysis from position: 14
Branch analysis from position: 47
filename:       /in/3IdMk
function name:  (null)
number of ops:  52
compiled vars:  !0 = $size, !1 = $space, !2 = $center, !3 = $maxPost, !4 = $i, !5 = $post, !6 = $pre
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 9
    4     1        ASSIGN                                                   !1, '++'
    6     2        INIT_FCALL                                               'ceil'
          3        DIV                                              ~9      !0, 2
          4        SEND_VAL                                                 ~9
          5        DO_ICALL                                         $10     
          6        ASSIGN                                                   !2, $10
    7     7        INIT_FCALL                                               'abs'
          8        SUB                                              ~12     !2, !0
          9        SEND_VAL                                                 ~12
         10        DO_ICALL                                         $13     
         11        ASSIGN                                                   !3, $13
    8    12        ASSIGN                                                   !4, 0
         13      > JMP                                                      ->49
    9    14    >   INIT_FCALL                                               'abs'
         15        ADD                                              ~16     !2, !4
         16        SUB                                              ~17     ~16, !0
         17        SEND_VAL                                                 ~17
         18        DO_ICALL                                         $18     
         19        ASSIGN                                                   !5, $18
   10    20        SUB                                              ~20     !3, !5
         21        ASSIGN                                                   !6, ~20
   12    22        INIT_FCALL                                               'str_repeat'
         23        SEND_VAR                                                 !1
         24        SEND_VAR                                                 !6
         25        DO_ICALL                                         $22     
         26        ECHO                                                     $22
   13    27        ECHO                                                     'x+'
   14    28        INIT_FCALL                                               'str_repeat'
         29        SEND_VAR                                                 !1
         30        SEND_VAR                                                 !5
         31        DO_ICALL                                         $23     
         32        ECHO                                                     $23
   16    33        IS_SMALLER                                               0, !5
         34      > JMPZ                                                     ~24, ->47
   17    35    >   INIT_FCALL                                               'str_repeat'
         36        SEND_VAR                                                 !1
         37        SUB                                              ~25     !5, 1
         38        SEND_VAL                                                 ~25
         39        DO_ICALL                                         $26     
         40        ECHO                                                     $26
   18    41        ECHO                                                     'x+'
   19    42        INIT_FCALL                                               'str_repeat'
         43        SEND_VAR                                                 !1
         44        SEND_VAR                                                 !6
         45        DO_ICALL                                         $27     
         46        ECHO                                                     $27
   21    47    >   ECHO                                                     '%0A'
    8    48        PRE_INC                                                  !4
         49    >   IS_SMALLER                                               !4, !0
         50      > JMPNZ                                                    ~29, ->14
   22    51    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
148.39 ms | 1400 KiB | 19 Q