3v4l.org

run code in 300+ PHP versions simultaneously
<?php if ($foo = rand() && 'asdf' != 'qwer') { var_dump($foo); } if (($foo = rand()) && 'asdf' != 'qwer') { var_dump($foo); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 3, Position 2 = 4
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 9
Branch analysis from position: 6
2 jumps found. (Code = 46) Position 1 = 13, Position 2 = 14
Branch analysis from position: 13
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 18
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 18
Branch analysis from position: 14
Branch analysis from position: 9
Branch analysis from position: 4
filename:       /in/ZVFni
function name:  (null)
number of ops:  19
compiled vars:  !0 = $foo
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'rand'
          1        DO_ICALL                                         $1      
          2      > JMPZ_EX                                          ~2      $1, ->4
          3    >   BOOL                                             ~2      <true>
          4    >   ASSIGN                                           ~3      !0, ~2
          5      > JMPZ                                                     ~3, ->9
    3     6    >   INIT_FCALL                                               'var_dump'
          7        SEND_VAR                                                 !0
          8        DO_ICALL                                                 
    6     9    >   INIT_FCALL                                               'rand'
         10        DO_ICALL                                         $5      
         11        ASSIGN                                           ~6      !0, $5
         12      > JMPZ_EX                                          ~6      ~6, ->14
         13    >   BOOL                                             ~6      <true>
         14    > > JMPZ                                                     ~6, ->18
    7    15    >   INIT_FCALL                                               'var_dump'
         16        SEND_VAR                                                 !0
         17        DO_ICALL                                                 
    8    18    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
164.78 ms | 1395 KiB | 17 Q