3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array('a', 'a', 'b'); $b = array('a', 'b', 'b'); if (sizeof($a)==sizeof($b) AND array_diff($a,$b)==array()) { echo 'fail' . "\n"; } if (count(array_diff(array_merge($a, $b), array_intersect($a, $b))) === 0) { echo 'fail2' . "\n"; } ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 6, Position 2 = 12
Branch analysis from position: 6
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 14
Branch analysis from position: 13
2 jumps found. (Code = 43) Position 1 = 29, Position 2 = 30
Branch analysis from position: 29
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 30
Branch analysis from position: 14
Branch analysis from position: 12
filename:       /in/FNc69
function name:  (null)
number of ops:  31
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        ASSIGN                                                   !1, <array>
    5     2        COUNT                                            ~4      !0
          3        COUNT                                            ~5      !1
          4        IS_EQUAL                                         ~6      ~4, ~5
          5      > JMPZ_EX                                          ~6      ~6, ->12
          6    >   INIT_FCALL                                               'array_diff'
          7        SEND_VAR                                                 !0
          8        SEND_VAR                                                 !1
          9        DO_ICALL                                         $7      
         10        IS_EQUAL                                         ~8      $7, <array>
         11        BOOL                                             ~6      ~8
         12    > > JMPZ                                                     ~6, ->14
    7    13    >   ECHO                                                     'fail%0A'
   10    14    >   INIT_FCALL                                               'array_diff'
         15        INIT_FCALL                                               'array_merge'
         16        SEND_VAR                                                 !0
         17        SEND_VAR                                                 !1
         18        DO_ICALL                                         $9      
         19        SEND_VAR                                                 $9
         20        INIT_FCALL                                               'array_intersect'
         21        SEND_VAR                                                 !0
         22        SEND_VAR                                                 !1
         23        DO_ICALL                                         $10     
         24        SEND_VAR                                                 $10
         25        DO_ICALL                                         $11     
         26        COUNT                                            ~12     $11
         27        IS_IDENTICAL                                             ~12, 0
         28      > JMPZ                                                     ~13, ->30
   12    29    >   ECHO                                                     'fail2%0A'
   14    30    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.06 ms | 1396 KiB | 19 Q