3v4l.org

run code in 300+ PHP versions simultaneously
<?php function encode($to_encode){ return (bin2hex($to_encode)); } function decode($numberstr){ return hex2bin(($numberstr)); } $str="the quick brown fox jumps over the lazy dog こどものじかん"; var_dump($str,encode($str),decode(encode($str)));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SePk1
function name:  (null)
number of ops:  16
compiled vars:  !0 = $str
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, 'the+quick+brown+fox+jumps+over+the+lazy+dog+%E3%81%93%E3%81%A9%E3%82%82%E3%81%AE%E3%81%98%E3%81%8B%E3%82%93'
    5     1        INIT_FCALL                                               'var_dump'
          2        SEND_VAR                                                 !0
          3        INIT_FCALL                                               'encode'
          4        SEND_VAR                                                 !0
          5        DO_FCALL                                      0  $2      
          6        SEND_VAR                                                 $2
          7        INIT_FCALL                                               'decode'
          8        INIT_FCALL                                               'encode'
          9        SEND_VAR                                                 !0
         10        DO_FCALL                                      0  $3      
         11        SEND_VAR                                                 $3
         12        DO_FCALL                                      0  $4      
         13        SEND_VAR                                                 $4
         14        DO_ICALL                                                 
         15      > RETURN                                                   1

Function encode:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SePk1
function name:  encode
number of ops:  6
compiled vars:  !0 = $to_encode
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
          1        INIT_FCALL                                               'bin2hex'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $1      
          4      > RETURN                                                   $1
          5*     > RETURN                                                   null

End of function encode

Function decode:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SePk1
function name:  decode
number of ops:  6
compiled vars:  !0 = $numberstr
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        INIT_FCALL                                               'hex2bin'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $1      
          4      > RETURN                                                   $1
          5*     > RETURN                                                   null

End of function decode

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.4 ms | 1398 KiB | 22 Q