3v4l.org

run code in 300+ PHP versions simultaneously
<?php $foo; $bar; $baz = 2; echo($foo ?? $bar ?? $baz); echo((isset($foo) && $foo !== null) ? $foo : $bar);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 8, Position 2 = 10
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 11, Position 2 = 13
Branch analysis from position: 11
1 jumps found. (Code = 42) Position 1 = 14
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
filename:       /in/CI9de
function name:  (null)
number of ops:  16
compiled vars:  !0 = $foo, !1 = $bar, !2 = $baz
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !2, 2
    5     1        COALESCE                                         ~4      !0
          2        COALESCE                                         ~5      !1
          3        QM_ASSIGN                                        ~5      !2
          4        QM_ASSIGN                                        ~4      ~5
          5        ECHO                                                     ~4
    6     6        ISSET_ISEMPTY_CV                                 ~6      !0
          7      > JMPZ_EX                                          ~6      ~6, ->10
          8    >   TYPE_CHECK                                  1020  ~7      !0
          9        BOOL                                             ~6      ~7
         10    > > JMPZ                                                     ~6, ->13
         11    >   QM_ASSIGN                                        ~8      !0
         12      > JMP                                                      ->14
         13    >   QM_ASSIGN                                        ~8      !1
         14    >   ECHO                                                     ~8
         15      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
157.09 ms | 939 KiB | 14 Q