3v4l.org

run code in 300+ PHP versions simultaneously
<?php define('DB_NAME', 'messages'); define('DB_USER', 'root'); define('DB_PASSWORD', ''); define('DB_HOST', 'localhost'); $link = mysql_connect(DB_HOST, DB_USER, DB_PASSWORD); if (!$link) { die('Could not connect: ' . mysql_error()); } $db_selected = mysql_select_db(DB_NAME, $link); if (!$db_selected) { die('Can\'t use ' . DB_NAME . ': ' . mysql_error()); } echo 'Connected succesfuly'; ?>

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.0110.00618.43
8.3.50.0040.01116.16
8.3.40.0180.00418.82
8.3.30.0100.00318.69
8.3.20.0000.00823.61
8.3.10.0080.00023.63
8.3.00.0080.00017.76
8.2.180.0090.00618.66
8.2.170.0160.00022.96
8.2.160.0070.00720.92
8.2.150.0080.00024.18
8.2.140.0050.00324.66
8.2.130.0050.00222.20
8.2.120.0030.00526.35
8.2.110.0050.00521.04
8.2.100.0080.00317.84
8.2.90.0030.00619.23
8.2.80.0000.00817.97
8.2.70.0030.00517.59
8.2.60.0000.00817.93
8.2.50.0000.00818.10
8.2.40.0050.00320.53
8.2.30.0100.00019.24
8.2.20.0050.00217.91
8.2.10.0000.00717.93
8.2.00.0000.00717.88
8.1.270.0040.00423.88
8.1.260.0070.00026.35
8.1.250.0060.00328.09
8.1.240.0080.00321.88
8.1.230.0040.00820.90
8.1.220.0030.00617.74
8.1.210.0050.00318.77
8.1.200.0090.00017.22
8.1.190.0100.00017.23
8.1.180.0090.00018.10
8.1.170.0050.00318.57
8.1.160.0050.00318.70
8.1.150.0040.00420.14
8.1.140.0000.00719.51
8.1.130.0040.00418.76
8.1.120.0000.00717.33
8.1.110.0000.00717.39
8.1.100.0000.00717.29
8.1.90.0050.00317.41
8.1.80.0040.00417.36
8.1.70.0040.00417.35
8.1.60.0000.00817.38
8.1.50.0050.00317.49
8.1.40.0070.00017.50
8.1.30.0040.00417.59
8.1.20.0040.00417.54
8.1.10.0040.00417.55
8.1.00.0080.00017.37
8.0.300.0040.00418.77
8.0.290.0050.00216.75
8.0.280.0050.00218.38
8.0.270.0000.00717.07
8.0.260.0040.00416.75
8.0.250.0070.00016.88
8.0.240.0000.00817.00
8.0.230.0030.00516.96
8.0.220.0000.00716.91
8.0.210.0070.00016.80
8.0.200.0000.00716.98
8.0.190.0060.00317.00
8.0.180.0000.00716.96
8.0.170.0000.00716.95
8.0.160.0090.00016.89
8.0.150.0030.00316.82
8.0.140.0030.00516.91
8.0.130.0060.00013.38
8.0.120.0000.00816.79
8.0.110.0000.00716.88
8.0.100.0030.00316.79
8.0.90.0080.00016.94
8.0.80.0040.01216.91
8.0.70.0050.00316.78
8.0.60.0000.00716.94
8.0.50.0000.00716.73
8.0.30.0110.00517.12
8.0.20.0090.01017.40
8.0.10.0000.00716.74
8.0.00.0090.01116.58
7.4.330.0000.00615.55
7.4.320.0000.00716.45
7.4.300.0030.00316.45
7.4.290.0060.00316.55
7.4.280.0000.00816.49
7.4.270.0040.00416.53
7.4.260.0000.00513.24
7.4.250.0030.00316.39
7.4.240.0030.00316.54
7.4.230.0070.00016.64
7.4.220.0090.01816.47
7.4.210.0050.01016.63
7.4.200.0040.00416.34
7.4.160.0140.00216.45
7.4.150.0040.01617.40
7.4.140.0080.00917.86
7.4.130.0120.00816.43
7.4.120.0110.01016.47
7.4.110.0140.00416.57
7.4.100.0110.00516.56
7.4.90.0090.00916.45
7.4.80.0170.00319.39
7.4.70.0140.00316.54
7.4.60.0100.00716.32
7.4.50.0090.00616.44
7.4.40.0100.00716.42
7.4.30.0060.00916.50
7.4.00.0030.01314.89
7.3.330.0050.00412.95
7.3.320.0000.00513.15
7.3.310.0040.00416.21
7.3.300.0000.00716.13
7.3.290.0070.00716.28
7.3.280.0070.00816.29
7.3.270.0130.00317.40
7.3.260.0070.01116.37
7.3.250.0110.01016.32
7.3.240.0160.00216.42
7.3.230.0140.00616.44
7.3.210.0100.00716.25
7.3.200.0090.00816.24
7.3.190.0030.01316.29
7.3.180.0130.00316.42
7.3.170.0100.01016.33
7.3.160.0190.00316.44
7.2.330.0100.01016.48
7.2.320.0060.01216.30
7.2.310.0030.01316.23
7.2.300.0070.01016.49
7.2.290.0140.00316.67
7.2.110.0070.00716.41
7.2.80.0030.00916.27
7.2.60.0060.01016.75
7.2.50.0070.00316.87
7.2.00.0030.00919.43
7.1.200.0040.00815.66
7.1.70.0000.01017.16
7.1.60.0430.01733.39
7.1.50.0470.01332.88
7.1.40.0570.00332.54
7.1.30.0470.01732.74
7.1.20.0500.00732.86
7.1.10.0700.01714.57
7.1.00.0330.01014.80
7.0.200.0370.01014.82
7.0.190.0370.00714.90
7.0.180.0470.00714.43
7.0.170.0430.00314.43
7.0.160.0400.00714.32
7.0.150.0370.01014.29
7.0.140.0370.00714.38
7.0.130.0330.01014.52
7.0.120.0330.01314.54
7.0.110.0470.01014.37
7.0.100.0430.01714.32
7.0.90.0300.01314.55
7.0.80.0400.00314.41
7.0.70.0370.01014.30
7.0.60.0330.01014.13
7.0.50.0430.00314.48
7.0.40.0570.00714.74
7.0.30.0900.01014.53
7.0.20.0630.01014.40
7.0.10.0300.01714.40
7.0.00.0330.01014.39

preferences:
51.89 ms | 400 KiB | 5 Q