3v4l.org

run code in 300+ PHP versions simultaneously
<?php $link = mysql_connect('localhost', 'mysql_user', 'mysql_password'); if (!$link) { die('Could not connect: ' . mysql_error()); } echo 'Connected successfully'; mysql_close($link);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 12
Branch analysis from position: 8
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/8un76
function name:  (null)
number of ops:  17
compiled vars:  !0 = $link
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL_BY_NAME                                       'mysql_connect'
          1        SEND_VAL_EX                                              'localhost'
          2        SEND_VAL_EX                                              'mysql_user'
          3        SEND_VAL_EX                                              'mysql_password'
          4        DO_FCALL                                      0  $1      
          5        ASSIGN                                                   !0, $1
    4     6        BOOL_NOT                                         ~3      !0
          7      > JMPZ                                                     ~3, ->12
    5     8    >   INIT_FCALL_BY_NAME                                       'mysql_error'
          9        DO_FCALL                                      0  $4      
         10        CONCAT                                           ~5      'Could+not+connect%3A+', $4
         11      > EXIT                                                     ~5
    7    12    >   ECHO                                                     'Connected+successfully'
    8    13        INIT_FCALL_BY_NAME                                       'mysql_close'
         14        SEND_VAR_EX                                              !0
         15        DO_FCALL                                      0          
         16      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.79 ms | 1393 KiB | 13 Q