3v4l.org

run code in 500+ PHP versions simultaneously
<?php $order_list = array ( array ("tangible", 1, 8, 1, 19000), array ("tangible", 6, 2, 10, NULL), array ("tangible", 1, 17, 1, 28000) ); usort($order_list, function ($a, $b) { if( ($c = $a[1] - $b[1]) !== 0) { return $c; } else { return $b[2] - $a[2]; } }); print_r($order_list);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ueart
function name:  (null)
number of ops:  10
compiled vars:  !0 = $order_list
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, <array>
    9     1        INIT_FCALL                                                   'usort'
          2        SEND_REF                                                     !0
          3        DECLARE_LAMBDA_FUNCTION                              ~2      [0]
   15     4        SEND_VAL                                                     ~2
    9     5        DO_ICALL                                                     
   17     6        INIT_FCALL                                                   'print_r'
          7        SEND_VAR                                                     !0
          8        DO_ICALL                                                     
          9      > RETURN                                                       1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 10
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ueart
function name:  {closure:/in/ueart:9}
number of ops:  15
compiled vars:  !0 = $a, !1 = $b, !2 = $c
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    9     0  E >   RECV                                                 !0      
          1        RECV                                                 !1      
   10     2        FETCH_DIM_R                                          ~3      !0, 1
          3        FETCH_DIM_R                                          ~4      !1, 1
          4        SUB                                                  ~5      ~3, ~4
          5        ASSIGN                                               ~6      !2, ~5
          6        IS_NOT_IDENTICAL                                             ~6, 0
          7      > JMPZ                                                         ~7, ->10
   11     8    > > RETURN                                                       !2
   10     9*       JMP                                                          ->14
   13    10    >   FETCH_DIM_R                                          ~8      !1, 2
         11        FETCH_DIM_R                                          ~9      !0, 2
         12        SUB                                                  ~10     ~8, ~9
         13      > RETURN                                                       ~10
   15    14*     > RETURN                                                       null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
221.09 ms | 2205 KiB | 15 Q