3v4l.org

run code in 500+ PHP versions simultaneously
<?php // $_GET['myvar'] isn't set... echo ($_GET['myvar'] ?? '') == 'hello' ? "hello!\n" : "goodbye!\n"; // $_GET['myvar'] is set but != 'hello' $_GET['myvar'] = 'farewell'; echo ($_GET['myvar'] ?? '') == 'hello' ? "hello!\n" : "goodbye!\n"; // $_GET['myvar'] is set and == 'hello' $_GET['myvar'] = 'hello'; echo ($_GET['myvar'] ?? '') == 'hello' ? "hello!\n" : "goodbye!\n";
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 8
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
2 jumps found. (Code = 43) Position 1 = 19, Position 2 = 21
Branch analysis from position: 19
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
2 jumps found. (Code = 43) Position 1 = 32, Position 2 = 34
Branch analysis from position: 32
1 jumps found. (Code = 42) Position 1 = 35
Branch analysis from position: 35
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 34
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 21
2 jumps found. (Code = 43) Position 1 = 32, Position 2 = 34
Branch analysis from position: 32
Branch analysis from position: 34
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 19, Position 2 = 21
Branch analysis from position: 19
Branch analysis from position: 21
filename:       /in/A58l0
function name:  (null)
number of ops:  37
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    4     0  E >   FETCH_IS                                             ~0      '_GET'
          1        FETCH_DIM_IS                                         ~1      ~0, 'myvar'
          2        COALESCE                                             ~2      ~1
          3        QM_ASSIGN                                            ~2      ''
          4        IS_EQUAL                                                     ~2, 'hello'
          5      > JMPZ                                                         ~3, ->8
          6    >   QM_ASSIGN                                            ~4      'hello%21%0A'
          7      > JMP                                                          ->9
          8    >   QM_ASSIGN                                            ~4      'goodbye%21%0A'
          9    >   ECHO                                                         ~4
    7    10        FETCH_W                          global              $5      '_GET'
         11        ASSIGN_DIM                                                   $5, 'myvar'
         12        OP_DATA                                                      'farewell'
    8    13        FETCH_IS                                             ~7      '_GET'
         14        FETCH_DIM_IS                                         ~8      ~7, 'myvar'
         15        COALESCE                                             ~9      ~8
         16        QM_ASSIGN                                            ~9      ''
         17        IS_EQUAL                                                     ~9, 'hello'
         18      > JMPZ                                                         ~10, ->21
         19    >   QM_ASSIGN                                            ~11     'hello%21%0A'
         20      > JMP                                                          ->22
         21    >   QM_ASSIGN                                            ~11     'goodbye%21%0A'
         22    >   ECHO                                                         ~11
   11    23        FETCH_W                          global              $12     '_GET'
         24        ASSIGN_DIM                                                   $12, 'myvar'
         25        OP_DATA                                                      'hello'
   12    26        FETCH_IS                                             ~14     '_GET'
         27        FETCH_DIM_IS                                         ~15     ~14, 'myvar'
         28        COALESCE                                             ~16     ~15
         29        QM_ASSIGN                                            ~16     ''
         30        IS_EQUAL                                                     ~16, 'hello'
         31      > JMPZ                                                         ~17, ->34
         32    >   QM_ASSIGN                                            ~18     'hello%21%0A'
         33      > JMP                                                          ->35
         34    >   QM_ASSIGN                                            ~18     'goodbye%21%0A'
         35    >   ECHO                                                         ~18
         36      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
164.29 ms | 1861 KiB | 13 Q