3v4l.org

run code in 300+ PHP versions simultaneously
<?php $content = "foobar"; $salt = substr(hash('sha256', $content), 0, 22); echo password_hash($content, PASSWORD_DEFAULT, ['salt' => $salt]); //
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/6WuE8
function name:  (null)
number of ops:  19
compiled vars:  !0 = $content, !1 = $salt
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'foobar'
    5     1        INIT_FCALL                                               'substr'
          2        INIT_FCALL                                               'hash'
          3        SEND_VAL                                                 'sha256'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $3      
          6        SEND_VAR                                                 $3
          7        SEND_VAL                                                 0
          8        SEND_VAL                                                 22
          9        DO_ICALL                                         $4      
         10        ASSIGN                                                   !1, $4
    7    11        INIT_FCALL                                               'password_hash'
         12        SEND_VAR                                                 !0
         13        SEND_VAL                                                 '2y'
         14        INIT_ARRAY                                       ~6      !1, 'salt'
         15        SEND_VAL                                                 ~6
         16        DO_ICALL                                         $7      
         17        ECHO                                                     $7
   15    18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.89 ms | 1394 KiB | 19 Q