3v4l.org

run code in 300+ PHP versions simultaneously
<?php function test($v1,$v2){ if($v1["id"]===$v2["id"]) return 0; else return -1; } $array2=NULL; $array=array( array("id"=>1,"data"=>1), array("id"=>1,"data"=>2), array("id"=>1,"data"=>3), array("id"=>3,"data"=>5), array("id"=>8,"data"=>1), array("id"=>10,"data"=>10) ); print_r(array_udiff_assoc($array, $array, null,'test'));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/H39LI
function name:  (null)
number of ops:  12
compiled vars:  !0 = $array2, !1 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   ASSIGN                                                   !0, null
    8     1        ASSIGN                                                   !1, <array>
   16     2        INIT_FCALL                                               'print_r'
          3        INIT_FCALL                                               'array_udiff_assoc'
          4        SEND_VAR                                                 !1
          5        SEND_VAR                                                 !1
          6        SEND_VAL                                                 null
          7        SEND_VAL                                                 'test'
          8        DO_ICALL                                         $4      
          9        SEND_VAR                                                 $4
         10        DO_ICALL                                                 
         11      > RETURN                                                   1

Function test:
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 = 62) Position 1 = -2
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/H39LI
function name:  test
number of ops:  10
compiled vars:  !0 = $v1, !1 = $v2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    3     2        FETCH_DIM_R                                      ~2      !0, 'id'
          3        FETCH_DIM_R                                      ~3      !1, 'id'
          4        IS_IDENTICAL                                             ~2, ~3
          5      > JMPZ                                                     ~4, ->8
          6    > > RETURN                                                   0
          7*       JMP                                                      ->9
    4     8    > > RETURN                                                   -1
    6     9*     > RETURN                                                   null

End of function test

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
142.46 ms | 1395 KiB | 17 Q