3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = "someString"; echo ord('z'); function rot13($str) { for ($i = 0,$l = strlen($str);$i<$l;$i++) { $str[$i] = chr(((ord($str[$i])-84)%26)+97); } } echo rot13('z').php_rot13('z');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Xs4mn
function name:  (null)
number of ops:  11
compiled vars:  !0 = $string
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'someString'
    3     1        ECHO                                                     122
    9     2        INIT_FCALL                                               'rot13'
          3        SEND_VAL                                                 'z'
          4        DO_FCALL                                      0  $2      
          5        INIT_FCALL_BY_NAME                                       'php_rot13'
          6        SEND_VAL_EX                                              'z'
          7        DO_FCALL                                      0  $3      
          8        CONCAT                                           ~4      $2, $3
          9        ECHO                                                     ~4
         10      > RETURN                                                   1

Function rot13:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 18
Branch analysis from position: 18
2 jumps found. (Code = 44) Position 1 = 20, Position 2 = 5
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
2 jumps found. (Code = 44) Position 1 = 20, Position 2 = 5
Branch analysis from position: 20
Branch analysis from position: 5
filename:       /in/Xs4mn
function name:  rot13
number of ops:  21
compiled vars:  !0 = $str, !1 = $i, !2 = $l
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
    5     1        ASSIGN                                                   !1, 0
          2        STRLEN                                           ~4      !0
          3        ASSIGN                                                   !2, ~4
          4      > JMP                                                      ->18
    6     5    >   INIT_FCALL                                               'chr'
          6        INIT_FCALL                                               'ord'
          7        FETCH_DIM_R                                      ~7      !0, !1
          8        SEND_VAL                                                 ~7
          9        DO_ICALL                                         $8      
         10        SUB                                              ~9      $8, 84
         11        MOD                                              ~10     ~9, 26
         12        ADD                                              ~11     ~10, 97
         13        SEND_VAL                                                 ~11
         14        DO_ICALL                                         $12     
         15        ASSIGN_DIM                                               !0, !1
         16        OP_DATA                                                  $12
    5    17        PRE_INC                                                  !1
         18    >   IS_SMALLER                                               !1, !2
         19      > JMPNZ                                                    ~14, ->5
    8    20    > > RETURN                                                   null

End of function rot13

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.57 ms | 1399 KiB | 18 Q