3v4l.org

run code in 300+ PHP versions simultaneously
<?php curl_setopt($ch, CURLOPT_URL, "http://www.example.com/"); curl_setopt($ch, CURLOPT_HEADER, 0); curl_exec($ch); curl_close($ch); $var = "testing module"; $statement = 'This is a $var'; echo ($statement); $var = "testing module"; $statement = "This is a $var"; echo ($statement); $arr = array("foo","bar","baz"); for ( $i = 0; $i < count($arr); $i++){ $item = $arr[$i]; } echo "<pre>"; print_r($item); echo "</pre>"; $a = 3; print '$a'; echo '$a'; print "$a"; echo "$a"; $array = array(array(141,151,161), 2, 3, array(101, 202, 303)); function DisplayArray($array) { foreach ($array as $value) { if (is_array($value)) { DisplayArray($value); } else { echo $value . " "; } } } DisplayArray($array); echo 0x10; ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 32
Branch analysis from position: 32
2 jumps found. (Code = 44) Position 1 = 35, Position 2 = 29
Branch analysis from position: 35
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 29
2 jumps found. (Code = 44) Position 1 = 35, Position 2 = 29
Branch analysis from position: 35
Branch analysis from position: 29
filename:       /in/3vms9
function name:  (null)
number of ops:  53
compiled vars:  !0 = $ch, !1 = $var, !2 = $statement, !3 = $arr, !4 = $i, !5 = $item, !6 = $a, !7 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL_BY_NAME                                       'curl_setopt'
          1        SEND_VAR_EX                                              !0
          2        FETCH_CONSTANT                                   ~8      'CURLOPT_URL'
          3        SEND_VAL_EX                                              ~8
          4        SEND_VAL_EX                                              'http%3A%2F%2Fwww.example.com%2F'
          5        DO_FCALL                                      0          
    3     6        INIT_FCALL_BY_NAME                                       'curl_setopt'
          7        SEND_VAR_EX                                              !0
          8        FETCH_CONSTANT                                   ~10     'CURLOPT_HEADER'
          9        SEND_VAL_EX                                              ~10
         10        SEND_VAL_EX                                              0
         11        DO_FCALL                                      0          
    4    12        INIT_FCALL_BY_NAME                                       'curl_exec'
         13        SEND_VAR_EX                                              !0
         14        DO_FCALL                                      0          
    5    15        INIT_FCALL_BY_NAME                                       'curl_close'
         16        SEND_VAR_EX                                              !0
         17        DO_FCALL                                      0          
    6    18        ASSIGN                                                   !1, 'testing+module'
    7    19        ASSIGN                                                   !2, 'This+is+a+%24var'
    8    20        ECHO                                                     !2
   10    21        ASSIGN                                                   !1, 'testing+module'
   11    22        NOP                                                      
         23        FAST_CONCAT                                      ~17     'This+is+a+', !1
         24        ASSIGN                                                   !2, ~17
   12    25        ECHO                                                     !2
   13    26        ASSIGN                                                   !3, <array>
   14    27        ASSIGN                                                   !4, 0
         28      > JMP                                                      ->32
   15    29    >   FETCH_DIM_R                                      ~21     !3, !4
         30        ASSIGN                                                   !5, ~21
   14    31        PRE_INC                                                  !4
         32    >   COUNT                                            ~24     !3
         33        IS_SMALLER                                               !4, ~24
         34      > JMPNZ                                                    ~25, ->29
   17    35    >   ECHO                                                     '%3Cpre%3E'
   18    36        INIT_FCALL                                               'print_r'
         37        SEND_VAR                                                 !5
         38        DO_ICALL                                                 
   19    39        ECHO                                                     '%3C%2Fpre%3E'
   21    40        ASSIGN                                                   !6, 3
   22    41        ECHO                                                     '%24a'
   23    42        ECHO                                                     '%24a'
   24    43        CAST                                          6  ~28     !6
         44        ECHO                                                     ~28
   25    45        CAST                                          6  ~29     !6
         46        ECHO                                                     ~29
   26    47        ASSIGN                                                   !7, <array>
   37    48        INIT_FCALL                                               'displayarray'
         49        SEND_VAR                                                 !7
         50        DO_FCALL                                      0          
   38    51        ECHO                                                     16
   39    52      > RETURN                                                   1

Function displayarray:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 12
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 12
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 9
Branch analysis from position: 5
1 jumps found. (Code = 42) Position 1 = 11
Branch analysis from position: 11
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 12
filename:       /in/3vms9
function name:  DisplayArray
number of ops:  14
compiled vars:  !0 = $array, !1 = $value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   27     0  E >   RECV                                             !0      
   28     1      > FE_RESET_R                                       $2      !0, ->12
          2    > > FE_FETCH_R                                               $2, !1, ->12
   29     3    >   TYPE_CHECK                                  128          !1
          4      > JMPZ                                                     ~3, ->9
   30     5    >   INIT_FCALL_BY_NAME                                       'DisplayArray'
          6        SEND_VAR_EX                                              !1
          7        DO_FCALL                                      0          
          8      > JMP                                                      ->11
   32     9    >   CONCAT                                           ~5      !1, '%0A'
         10        ECHO                                                     ~5
   28    11    > > JMP                                                      ->2
         12    >   FE_FREE                                                  $2
   36    13      > RETURN                                                   null

End of function displayarray

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
167.46 ms | 1403 KiB | 16 Q