3v4l.org

run code in 300+ PHP versions simultaneously
<?php function genRandomString($length=10 ,$characters = '0123456789abcdefghijklmnopqrstuvwxyz',$string = '') { for ($p = 0; $p < $length; $p++) { $string .= $characters[mt_rand(0, strlen($characters)-1)]; } return $string; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/S6Yep
function name:  (null)
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E > > RETURN                                                   1

Function genrandomstring:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 14
Branch analysis from position: 14
2 jumps found. (Code = 44) Position 1 = 16, Position 2 = 5
Branch analysis from position: 16
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
2 jumps found. (Code = 44) Position 1 = 16, Position 2 = 5
Branch analysis from position: 16
Branch analysis from position: 5
filename:       /in/S6Yep
function name:  genRandomString
number of ops:  18
compiled vars:  !0 = $length, !1 = $characters, !2 = $string, !3 = $p
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV_INIT                                        !0      10
          1        RECV_INIT                                        !1      '0123456789abcdefghijklmnopqrstuvwxyz'
          2        RECV_INIT                                        !2      ''
    4     3        ASSIGN                                                   !3, 0
          4      > JMP                                                      ->14
    5     5    >   INIT_FCALL                                               'mt_rand'
          6        SEND_VAL                                                 0
          7        STRLEN                                           ~5      !1
          8        SUB                                              ~6      ~5, 1
          9        SEND_VAL                                                 ~6
         10        DO_ICALL                                         $7      
         11        FETCH_DIM_R                                      ~8      !1, $7
         12        ASSIGN_OP                                     8          !2, ~8
    4    13        PRE_INC                                                  !3
         14    >   IS_SMALLER                                               !3, !0
         15      > JMPNZ                                                    ~11, ->5
    8    16    > > RETURN                                                   !2
         17*     > RETURN                                                   null

End of function genrandomstring

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.87 ms | 1387 KiB | 15 Q