3v4l.org

run code in 300+ PHP versions simultaneously
<?php $old = <<<'NOWDOC' <?php // Connect $link = mysql_connect('mysql_host', 'mysql_user', 'mysql_password') OR die(mysql_error()); // Query $query = sprintf("SELECT * FROM users WHERE user='%s' AND password='%s'", mysql_real_escape_string($user), mysql_real_escape_string($password)); ?> NOWDOC; echo preg_replace('/mysql_([a-zA-Z_]+)\(/', 'mysqli_$1($GLOBALS[\'link\'], ');

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
8.3.60.0100.01018.56
8.3.50.0060.00921.97
8.3.40.0070.00718.79
8.3.30.0070.00718.95
8.3.20.0080.00020.39
8.3.10.0040.00421.96
8.3.00.0040.00422.58
8.2.180.0070.00716.63
8.2.170.0070.00722.96
8.2.160.0100.00319.04
8.2.150.0070.01124.18
8.2.140.0030.00524.66
8.2.130.0070.00026.16
8.2.120.0080.00017.75
8.2.110.0090.00022.25
8.2.100.0060.00619.52
8.2.90.0050.00319.04
8.2.80.0040.00417.97
8.2.70.0050.00317.50
8.2.60.0070.00317.90
8.2.50.0030.00718.07
8.2.40.0060.00318.09
8.2.30.0030.00717.96
8.2.20.0050.00317.59
8.2.10.0080.00019.41
8.2.00.0000.00817.67
8.1.280.0000.01425.92
8.1.270.0000.00823.96
8.1.260.0080.00026.35
8.1.250.0000.00828.09
8.1.240.0060.00323.72
8.1.230.0080.00319.03
8.1.220.0040.00417.74
8.1.210.0030.00518.77
8.1.200.0040.00417.48
8.1.190.0060.00317.53
8.1.180.0000.00918.10
8.1.170.0000.00818.59
8.1.160.0000.00721.95
8.1.150.0040.00418.58
8.1.140.0050.00217.36
8.1.130.0020.00517.82
8.1.120.0040.00417.39
8.1.110.0000.00817.39
8.1.100.0000.00717.35
8.1.90.0030.00717.40
8.1.80.0070.00017.45
8.1.70.0040.00417.35
8.1.60.0050.00317.40
8.1.50.0040.00417.40
8.1.40.0040.00417.53
8.1.30.0040.00417.61
8.1.20.0040.00417.64
8.1.10.0000.00717.58
8.1.00.0060.00317.44
8.0.300.0040.00418.77
8.0.290.0080.00017.05
8.0.280.0070.00018.29
8.0.270.0080.00017.11
8.0.260.0030.00316.72
8.0.250.0070.00016.91
8.0.240.0070.00016.90
8.0.230.0030.00316.90
8.0.220.0040.00416.75
8.0.210.0030.00316.78
8.0.200.0000.00616.83
8.0.190.0040.00416.83
8.0.180.0000.00716.80
8.0.170.0040.00416.82
8.0.160.0030.00516.91
8.0.150.0030.00316.81
8.0.140.0040.00416.68
8.0.130.0050.00013.27
8.0.120.0070.00016.74
8.0.110.0040.00416.79
8.0.100.0040.00416.70
8.0.90.0070.00016.74
8.0.80.0080.00716.77
8.0.70.0050.00216.98
8.0.60.0000.00716.83
8.0.50.0020.00516.93
8.0.30.0070.01217.00
8.0.20.0090.00917.40
8.0.10.0050.00216.99
8.0.00.0150.00616.94
7.4.330.0000.00715.00
7.4.320.0030.00316.49
7.4.300.0030.00316.47
7.4.290.0030.00316.32
7.4.280.0030.00316.43
7.4.270.0000.00716.46
7.4.260.0000.00513.16
7.4.250.0000.00716.48
7.4.240.0010.00616.41
7.4.230.0040.00416.43
7.4.220.0150.00416.57
7.4.210.0090.00816.45
7.4.200.0040.00416.41
7.4.190.0070.00016.57
7.4.160.0090.00616.54
7.4.150.0130.00317.40
7.4.140.0090.00917.86
7.4.130.0110.00816.38
7.4.120.0080.01116.48
7.4.110.0100.00716.48
7.4.100.0120.00616.53
7.4.90.0030.01316.58
7.4.80.0080.01119.39
7.4.70.0110.00616.34
7.4.60.0100.00616.31
7.4.50.0030.00316.30
7.4.40.0090.00622.77
7.4.30.0030.01316.43
7.4.00.0070.01115.03
7.3.330.0000.00513.12
7.3.320.0000.00513.05
7.3.310.0000.00716.15
7.3.300.0030.00316.20
7.3.290.0030.01616.15
7.3.280.0120.00716.22
7.3.270.0140.00317.40
7.3.260.0120.00916.28
7.3.250.0080.01116.30
7.3.240.0070.01016.57
7.3.230.0100.00616.39
7.3.210.0160.00316.15
7.3.200.0090.01019.39
7.3.190.0070.01016.34
7.3.180.0130.00316.44
7.3.170.0100.00616.27
7.3.160.0060.01116.19
7.3.120.0040.00714.70
7.3.10.0000.01416.29
7.3.00.0040.00816.46
7.2.330.0140.00416.56
7.2.320.0120.00916.64
7.2.310.0100.00716.19
7.2.300.0060.00916.39
7.2.290.0120.00916.41
7.2.130.0040.00916.96
7.2.120.0070.00716.80
7.2.110.0000.01116.80
7.2.100.0040.00416.50
7.2.90.0080.00416.82
7.2.80.0060.00316.82
7.2.70.0060.00616.80
7.2.60.0070.00516.67
7.2.50.0040.00416.90
7.2.40.0040.01216.59
7.2.30.0050.00516.89
7.2.20.0000.00816.88
7.2.10.0030.01216.99
7.2.00.0040.00816.96
7.1.250.0060.00615.60
7.1.200.0040.00815.82
7.1.70.0000.00917.05
7.1.60.0110.01519.82
7.1.50.0000.01116.77
7.1.00.0030.07022.51
7.0.200.0070.00316.69
7.0.140.0070.07021.97
7.0.60.0070.08019.94
7.0.50.0030.04017.85
7.0.40.0100.08720.09
7.0.30.0330.07320.02
7.0.20.0200.05720.18
7.0.10.0130.03320.17
7.0.00.0000.05019.95
5.6.280.0070.07320.91
5.6.210.0030.04020.72
5.6.200.0070.05318.13
5.6.190.0170.07020.27
5.6.180.3930.04720.41
5.6.170.0470.03320.36
5.6.160.0030.09320.35
5.6.150.0070.08718.13
5.6.140.0030.08318.18
5.6.130.0070.07318.18
5.6.120.0070.08720.89
5.6.110.0100.08021.11
5.6.100.0070.03721.11
5.6.90.0070.06720.99
5.6.80.0030.07020.52
5.6.70.4930.03720.37
5.5.350.0130.09020.44
5.5.340.0070.04717.97
5.5.330.0070.04020.56
5.5.320.4100.04020.27
5.5.310.0330.06320.27
5.5.300.0170.06318.00
5.5.290.0070.05017.89
5.5.280.0130.04320.87
5.5.270.0130.04320.75
5.5.260.0070.06720.86
5.5.250.0100.04020.49
5.5.240.0270.06720.36
5.4.450.1030.05719.48
5.4.440.0830.06019.27
5.4.430.0170.05019.46
5.4.420.0170.04719.32
5.4.410.0130.05719.40
5.4.400.0100.05318.77
5.4.390.0200.04718.78
5.4.380.0300.06018.76
5.4.370.0200.04718.70
5.4.360.0130.05318.73
5.4.350.0230.04718.83
5.4.340.0130.05318.46
5.4.320.0060.04512.45
5.4.310.0080.04212.45
5.4.300.0070.03512.45
5.4.290.0050.04312.45
5.4.280.0040.04212.35
5.4.270.0070.06718.91
5.4.260.0100.06018.88
5.4.250.0130.06018.89
5.4.240.0100.05318.84
5.4.230.0100.05318.90
5.4.220.0170.07018.92
5.4.210.0070.05318.87
5.4.200.0100.06718.70
5.4.190.0100.05018.75
5.4.180.0100.05018.70
5.4.170.0170.04319.00
5.4.160.0070.05719.02
5.4.150.0070.05718.86
5.4.140.0130.06716.40
5.4.130.0130.05016.38
5.4.120.0070.07016.20
5.4.110.0130.07716.32
5.4.100.0300.04716.33
5.4.90.0070.05316.33
5.4.80.0000.06016.55
5.4.70.0130.04316.38
5.4.60.0070.07016.34
5.4.50.0170.06716.37
5.4.40.0030.07316.29
5.4.30.0100.06316.34
5.4.20.0070.07316.29
5.4.10.0170.06716.45
5.4.00.0230.05315.64
5.3.290.0090.03812.80
5.3.280.0100.04714.61
5.3.270.0130.06714.60
5.3.260.0130.05314.61
5.3.250.0100.05314.75
5.3.240.0070.06014.39
5.3.230.0130.06714.61
5.3.220.0070.07314.26
5.3.210.0070.05714.57
5.3.200.0100.06714.41
5.3.190.0000.07714.59
5.3.180.0170.06314.33
5.3.170.0030.06014.71
5.3.160.0100.06314.41
5.3.150.0070.06314.71
5.3.140.0130.05314.56
5.3.130.0070.07314.55
5.3.120.0100.06014.54
5.3.110.0000.08714.38
5.3.100.0000.06014.20
5.3.90.0170.06313.88
5.3.80.0070.06013.90
5.3.70.0100.06713.79
5.3.60.0170.06313.94
5.3.50.0070.05313.72
5.3.40.0100.07313.72
5.3.30.0100.04713.79
5.3.20.0100.08713.60
5.3.10.0070.08313.50
5.3.00.0170.07013.58
5.2.170.0070.05711.25
5.2.160.0070.06311.05
5.2.150.0000.04710.90
5.2.140.0130.04711.07
5.2.130.0030.05010.85
5.2.120.0030.06011.05
5.2.110.0030.06311.25
5.2.100.0030.04011.11
5.2.90.0070.04311.25
5.2.80.0130.05311.18
5.2.70.0030.04311.09
5.2.60.0200.04711.06
5.2.50.0170.04310.95
5.2.40.0130.03710.89
5.2.30.0000.04710.89
5.2.20.0100.05310.98
5.2.10.0170.04710.64
5.2.00.0070.04010.80
5.1.60.0070.03310.23
5.1.50.0100.0439.95
5.1.40.0100.0439.94
5.1.30.0070.03710.40
5.1.20.0100.03710.11
5.1.10.0100.04710.15
5.1.00.0070.03710.02
5.0.50.0070.0278.57
5.0.40.0030.0278.34
5.0.30.0000.0508.28
5.0.20.0100.0278.19
5.0.10.0000.0308.16
5.0.00.0070.0407.98
4.4.90.0100.0236.85
4.4.80.0000.0336.85
4.4.70.0030.0236.85
4.4.60.0100.0176.85
4.4.50.0030.0206.85
4.4.40.0030.0476.85
4.4.30.0030.0236.85
4.4.20.0030.0236.85
4.4.10.0000.0336.85
4.4.00.0030.0336.85
4.3.110.0100.0176.85
4.3.100.0030.0206.85
4.3.90.0000.0236.85
4.3.80.0000.0376.85
4.3.70.0030.0306.85
4.3.60.0070.0206.85
4.3.50.0070.0206.85
4.3.40.0030.0436.85
4.3.30.0030.0206.85
4.3.20.0000.0306.85
4.3.10.0030.0276.85
4.3.00.0100.0237.39

preferences:
35.72 ms | 401 KiB | 5 Q