3v4l.org

run code in 300+ PHP versions simultaneously
<?php if (($status = $_GET['st'] ?: '') != 'ac' && $status != 'ar') { echo "1: \$_GET invalid\n"; } $_GET['st'] = 'x'; if (($status = $_GET['st'] ?: '') != 'ac' && $status != 'ar') { echo "2: \$_GET invalid\n"; } $_GET['st'] = 'ac'; if (($status = $_GET['st'] ?: '') != 'ac' && $status != 'ar') { echo "3: \$_GET invalid\n"; } $_GET['st'] = 'ar'; if (($status = $_GET['st'] ?: '') != 'ac' && $status != 'ar') { echo "4: \$_GET invalid\n"; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 7, Position 2 = 9
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 11
Branch analysis from position: 10
2 jumps found. (Code = 46) Position 1 = 21, Position 2 = 23
Branch analysis from position: 21
2 jumps found. (Code = 43) Position 1 = 24, Position 2 = 25
Branch analysis from position: 24
2 jumps found. (Code = 46) Position 1 = 35, Position 2 = 37
Branch analysis from position: 35
2 jumps found. (Code = 43) Position 1 = 38, Position 2 = 39
Branch analysis from position: 38
2 jumps found. (Code = 46) Position 1 = 49, Position 2 = 51
Branch analysis from position: 49
2 jumps found. (Code = 43) Position 1 = 52, Position 2 = 53
Branch analysis from position: 52
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 53
Branch analysis from position: 51
Branch analysis from position: 39
Branch analysis from position: 37
Branch analysis from position: 25
Branch analysis from position: 23
Branch analysis from position: 11
Branch analysis from position: 9
filename:       /in/49pRp
function name:  (null)
number of ops:  54
compiled vars:  !0 = $status
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   FETCH_R                      global              ~1      '_GET'
          1        FETCH_DIM_R                                      ~2      ~1, 'st'
          2        JMP_SET                                          ~3      ~2, ->4
          3        QM_ASSIGN                                        ~3      ''
          4        ASSIGN                                           ~4      !0, ~3
          5        IS_NOT_EQUAL                                     ~5      ~4, 'ac'
          6      > JMPZ_EX                                          ~5      ~5, ->9
          7    >   IS_NOT_EQUAL                                     ~6      !0, 'ar'
          8        BOOL                                             ~5      ~6
          9    > > JMPZ                                                     ~5, ->11
         10    >   ECHO                                                     '1%3A+%24_GET+invalid%0A'
    4    11    >   FETCH_W                      global              $7      '_GET'
         12        ASSIGN_DIM                                               $7, 'st'
         13        OP_DATA                                                  'x'
    5    14        FETCH_R                      global              ~9      '_GET'
         15        FETCH_DIM_R                                      ~10     ~9, 'st'
         16        JMP_SET                                          ~11     ~10, ->18
         17        QM_ASSIGN                                        ~11     ''
         18        ASSIGN                                           ~12     !0, ~11
         19        IS_NOT_EQUAL                                     ~13     ~12, 'ac'
         20      > JMPZ_EX                                          ~13     ~13, ->23
         21    >   IS_NOT_EQUAL                                     ~14     !0, 'ar'
         22        BOOL                                             ~13     ~14
         23    > > JMPZ                                                     ~13, ->25
         24    >   ECHO                                                     '2%3A+%24_GET+invalid%0A'
    6    25    >   FETCH_W                      global              $15     '_GET'
         26        ASSIGN_DIM                                               $15, 'st'
         27        OP_DATA                                                  'ac'
    7    28        FETCH_R                      global              ~17     '_GET'
         29        FETCH_DIM_R                                      ~18     ~17, 'st'
         30        JMP_SET                                          ~19     ~18, ->32
         31        QM_ASSIGN                                        ~19     ''
         32        ASSIGN                                           ~20     !0, ~19
         33        IS_NOT_EQUAL                                     ~21     ~20, 'ac'
         34      > JMPZ_EX                                          ~21     ~21, ->37
         35    >   IS_NOT_EQUAL                                     ~22     !0, 'ar'
         36        BOOL                                             ~21     ~22
         37    > > JMPZ                                                     ~21, ->39
         38    >   ECHO                                                     '3%3A+%24_GET+invalid%0A'
    8    39    >   FETCH_W                      global              $23     '_GET'
         40        ASSIGN_DIM                                               $23, 'st'
         41        OP_DATA                                                  'ar'
    9    42        FETCH_R                      global              ~25     '_GET'
         43        FETCH_DIM_R                                      ~26     ~25, 'st'
         44        JMP_SET                                          ~27     ~26, ->46
         45        QM_ASSIGN                                        ~27     ''
         46        ASSIGN                                           ~28     !0, ~27
         47        IS_NOT_EQUAL                                     ~29     ~28, 'ac'
         48      > JMPZ_EX                                          ~29     ~29, ->51
         49    >   IS_NOT_EQUAL                                     ~30     !0, 'ar'
         50        BOOL                                             ~29     ~30
         51    > > JMPZ                                                     ~29, ->53
         52    >   ECHO                                                     '4%3A+%24_GET+invalid%0A'
         53    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.97 ms | 1012 KiB | 13 Q