3v4l.org

run code in 500+ PHP versions simultaneously
<?php $data = ['_', '@', ...range(-10, 10), ...range('A', 'F'), ...range('a', 'f') ]; $negatives = []; $uppers = []; $integers = []; foreach ($data as $v) { $negatives[] = $v < 0; $uppers[] = ctype_upper((string) $v); $integers[] = is_int($v); } array_multisort( $negatives, SORT_DESC, $uppers, SORT_DESC, $integers, $data ); var_export($data);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 22, Position 2 = 36
Branch analysis from position: 22
2 jumps found. (Code = 78) Position 1 = 23, Position 2 = 36
Branch analysis from position: 23
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
Branch analysis from position: 36
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 36
filename:       /in/cdEUp
function name:  (null)
number of ops:  49
compiled vars:  !0 = $data, !1 = $negatives, !2 = $uppers, !3 = $integers, !4 = $v
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   INIT_ARRAY                                           ~5      '_'
          1        ADD_ARRAY_ELEMENT                                    ~5      '%40'
          2        INIT_FCALL                                                   'range'
          3        SEND_VAL                                                     -10
          4        SEND_VAL                                                     10
          5        DO_ICALL                                             $6      
          6        ADD_ARRAY_UNPACK                                     ~5      $6
          7        INIT_FCALL                                                   'range'
          8        SEND_VAL                                                     'A'
          9        SEND_VAL                                                     'F'
         10        DO_ICALL                                             $7      
         11        ADD_ARRAY_UNPACK                                     ~5      $7
         12        INIT_FCALL                                                   'range'
         13        SEND_VAL                                                     'a'
         14        SEND_VAL                                                     'f'
         15        DO_ICALL                                             $8      
         16        ADD_ARRAY_UNPACK                                     ~5      $8
         17        ASSIGN                                                       !0, ~5
    5    18        ASSIGN                                                       !1, <array>
    6    19        ASSIGN                                                       !2, <array>
    7    20        ASSIGN                                                       !3, <array>
    8    21      > FE_RESET_R                                           $13     !0, ->36
         22    > > FE_FETCH_R                                                   $13, !4, ->36
    9    23    >   IS_SMALLER                                           ~15     !4, 0
         24        ASSIGN_DIM                                                   !1
         25        OP_DATA                                                      ~15
   10    26        INIT_FCALL                                                   'ctype_upper'
         27        CAST                                              6  ~17     !4
         28        SEND_VAL                                                     ~17
         29        DO_ICALL                                             $18     
         30        ASSIGN_DIM                                                   !2
         31        OP_DATA                                                      $18
   11    32        TYPE_CHECK                                       16  ~20     !4
         33        ASSIGN_DIM                                                   !3
         34        OP_DATA                                                      ~20
    8    35      > JMP                                                          ->22
         36    >   FE_FREE                                                      $13
   14    37        INIT_FCALL                                                   'array_multisort'
   15    38        SEND_REF                                                     !1
   16    39        SEND_VAL                                                     3
   17    40        SEND_REF                                                     !2
   18    41        SEND_VAL                                                     3
   19    42        SEND_REF                                                     !3
   20    43        SEND_REF                                                     !0
   14    44        DO_ICALL                                                     
   22    45        INIT_FCALL                                                   'var_export'
         46        SEND_VAR                                                     !0
         47        DO_ICALL                                                     
         48      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
163.48 ms | 1787 KiB | 17 Q