3v4l.org

run code in 300+ PHP versions simultaneously
<?php function fwrite_with_retry($sock, &$data) { $bytes_to_write = strlen($data); $bytes_written = 0; while ( $bytes_written < $bytes_to_write ) { if ( $bytes_written == 0 ) { $rv = fwrite($sock, $data); } else { $rv = fwrite($sock, substr($data, $bytes_written)); } if ( $rv === false || $rv == 0 ) return( $bytes_written == 0 ? false : $bytes_written ); $bytes_written += $rv; } return $bytes_written; } $fp = fsockopen("127.0.0.1", 80, $errno, $errstr, 30); if (!$fp) { echo "$errstr ($errno)<br />\n"; } else { $out = "GET / HTTP/1.1\r\n"; $out .= "Host: 3v4l.org\r\n"; $out .= "Connection: Close\r\n\r\n"; fwrite_with_retry($fp, $out); while (!feof($fp)) { echo fgets($fp, 128); } fclose($fp); }

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.00418.55
8.3.50.0070.01321.97
8.3.40.0170.00318.67
8.3.30.0150.00019.18
8.3.20.0040.00420.43
8.3.10.0080.00021.85
8.3.00.0050.00317.93
8.2.180.0120.00616.75
8.2.170.0090.00922.96
8.2.160.0040.01120.65
8.2.150.0040.00424.18
8.2.140.0050.00224.66
8.2.130.0070.00026.16
8.2.120.0040.00421.22
8.2.110.0030.00722.43
8.2.100.0030.00919.70
8.2.90.0080.00019.17
8.2.80.0050.00317.97
8.2.70.0030.00617.50
8.2.60.0040.00418.05
8.2.50.0050.00318.07
8.2.40.0000.00818.34
8.2.30.0050.00318.22
8.2.20.0050.00317.81
8.2.10.0040.00418.10
8.2.00.0020.00517.72
8.1.280.0070.01025.92
8.1.270.0000.00924.02
8.1.260.0050.00326.35
8.1.250.0090.00628.09
8.1.240.0030.00624.09
8.1.230.0080.00319.21
8.1.220.0050.00317.74
8.1.210.0000.00918.77
8.1.200.0150.00217.38
8.1.190.0030.00617.23
8.1.180.0000.00818.10
8.1.170.0050.00318.63
8.1.160.0040.00422.15
8.1.150.0040.00418.95
8.1.140.0040.00417.64
8.1.130.0030.00317.88
8.1.120.0050.00217.51
8.1.110.0030.00617.51
8.1.100.0040.00417.48
8.1.90.0050.00517.51
8.1.80.0000.00717.53
8.1.70.0030.00317.39
8.1.60.0040.00417.78
8.1.50.0040.00417.59
8.1.40.0050.00317.58
8.1.30.0000.00817.75
8.1.20.0040.00417.70
8.1.10.0080.00017.54
8.1.00.0000.00817.51
8.0.300.0050.00318.77
8.0.290.0000.00816.75
8.0.280.0000.00718.64
8.0.270.0000.00817.44
8.0.260.0030.00317.40
8.0.250.0050.00217.08
8.0.240.0030.00317.05
8.0.230.0000.00717.07
8.0.220.0070.00016.94
8.0.210.0070.00017.08
8.0.200.0000.00617.15
8.0.190.0000.00817.05
8.0.180.0000.00717.14
8.0.170.0000.00717.03
8.0.160.0000.00717.03
8.0.150.0040.00416.93
8.0.140.0040.00317.02
8.0.130.0000.00713.42
8.0.120.0030.00516.96
8.0.110.0000.00816.94
8.0.100.0000.00717.14
8.0.90.0050.00317.14
8.0.80.0090.01116.97
8.0.70.0030.00716.98
8.0.60.0050.00216.91
8.0.50.0040.00417.14
8.0.30.0100.00917.14
8.0.20.0130.01017.49
8.0.10.0000.00817.14
8.0.00.0110.01016.80
7.4.330.0030.00315.00
7.4.320.0030.00316.63
7.4.300.0000.00616.58
7.4.290.0070.00016.60
7.4.280.0050.00316.63
7.4.270.0040.00416.64
7.4.260.0040.00416.65
7.4.250.0040.00416.54
7.4.240.0030.00416.68
7.4.230.0030.00316.56
7.4.220.0040.01516.72
7.4.210.0100.01016.66
7.4.200.0000.00716.65
7.4.160.0130.00316.35
7.4.150.0100.01717.40
7.4.140.0110.00517.86
7.4.130.0110.00816.65
7.4.120.0070.01116.67
7.4.110.0140.02716.64
7.4.100.0080.01616.68
7.4.90.0070.01316.67
7.4.80.0150.00319.39
7.4.70.0130.01016.55
7.4.60.0060.01216.55
7.4.50.0000.00916.66
7.4.40.0100.00716.50
7.4.30.0110.00516.64
7.4.00.0060.00614.88
7.3.330.0030.00313.45
7.3.320.0050.00013.36
7.3.310.0070.00016.43
7.3.300.0000.00716.37
7.3.290.0000.02216.41
7.3.280.0120.00916.46
7.3.270.0090.00917.40
7.3.260.0080.00916.67
7.3.250.0130.00516.57
7.3.240.0150.00416.48
7.3.230.0090.00916.57
7.3.210.0060.01016.46
7.3.200.0060.01219.39
7.3.190.0070.00716.57
7.3.180.0090.00616.66
7.3.170.0030.01316.52
7.3.160.0090.01316.54
7.3.120.0180.00015.10
7.3.110.0060.01215.04
7.3.100.0030.01314.75
7.3.90.0070.00315.00
7.3.80.0070.01014.88
7.3.70.0070.00414.69
7.3.60.0030.01014.83
7.3.50.0090.00014.78
7.3.40.0040.00815.01
7.3.30.0100.00314.63
7.3.20.0060.00616.84
7.3.10.0060.00916.80
7.3.00.0040.00816.80
7.2.330.0200.00416.73
7.2.320.0130.01016.84
7.2.310.0100.00716.74
7.2.300.0120.00616.91
7.2.290.0120.01016.70
7.2.240.0060.01214.79
7.2.230.0080.00815.06
7.2.220.0030.01014.89
7.2.210.0060.00915.07
7.2.200.0060.00914.97
7.2.190.0030.01314.72
7.2.180.0060.00615.06
7.2.170.0100.00315.10
7.2.160.0090.00615.12
7.2.150.0090.00617.13
7.2.140.0090.00616.71
7.2.130.0080.00416.61
7.2.120.0090.00916.95
7.2.110.0030.01217.00
7.2.100.0100.00716.68
7.2.90.0060.00617.04
7.2.80.0060.00617.02
7.2.70.0000.01116.79
7.2.60.0100.00316.75
7.2.50.0030.01016.99
7.2.40.0000.01316.73
7.2.30.0130.00316.95
7.2.20.0100.00717.10
7.2.10.0090.00616.92
7.2.00.0080.00318.31
7.1.330.0070.01015.98
7.1.320.0030.01015.97
7.1.310.0070.00315.98
7.1.300.0070.00716.04
7.1.290.0030.00915.84
7.1.280.0040.01115.61
7.1.270.0070.00415.67
7.1.260.0030.01015.71
7.1.250.0050.00515.99
7.1.200.0030.01115.55
7.1.100.0090.00618.39
7.1.70.0030.00317.40
7.1.60.0100.01619.25
7.1.50.0120.00916.73
7.1.00.0070.07322.43
7.0.200.0000.00716.75
7.0.140.0030.07022.13
7.0.60.0030.07320.00
7.0.50.0070.08717.98
7.0.40.0030.06320.09
7.0.30.0530.06720.20
7.0.20.0300.05720.29
7.0.10.0070.04720.21
7.0.00.0000.08020.29
5.6.280.0000.07720.94
5.6.210.0270.06320.77
5.6.200.0030.04718.40
5.6.190.0100.07320.52
5.6.180.0330.07020.46
5.6.170.0330.06020.68
5.6.160.0030.04020.66
5.6.150.0070.06718.34
5.6.140.0030.04318.41
5.6.130.0100.07718.30
5.6.120.0130.07721.23
5.6.110.0070.09021.03
5.6.100.0070.08321.02
5.6.90.0070.05321.07
5.6.80.0100.08020.57
5.5.350.0300.07020.53
5.5.340.0070.05318.00
5.5.330.0030.09020.42
5.5.320.0330.05020.38
5.5.310.0270.04720.37
5.5.300.0070.03718.14
5.5.290.0000.04318.11
5.5.280.0030.05320.98
5.5.270.0030.06020.84
5.5.260.0030.04020.86
5.5.250.0130.08020.66
5.5.240.0230.07020.11
5.4.450.0300.04719.47
5.4.440.0130.03319.29
5.4.430.0300.03719.47
5.4.420.0630.04319.44
5.4.410.0200.04719.57
5.4.400.0270.04319.16
5.4.390.0230.03319.00
5.4.380.0330.05718.83
5.4.370.0300.07718.96
5.4.360.0430.07718.84
5.4.350.0400.04718.59
5.4.340.0400.05018.85
5.4.320.0050.03512.54
5.4.310.0040.04212.54
5.4.300.0030.04212.54
5.4.290.0040.04012.53
5.4.280.0060.03512.43
5.4.270.0040.03812.43
5.4.260.0050.04012.43
5.4.250.0040.04012.43
5.4.240.0090.03312.43
5.4.230.0060.03712.42
5.4.220.0020.04012.42
5.4.210.0050.03712.42
5.4.200.0080.03612.42
5.4.190.0030.03912.42
5.4.180.0030.04012.41
5.4.170.0070.03512.43
5.4.160.0050.03912.42
5.4.150.0080.04212.41
5.4.140.0080.03812.11
5.4.130.0090.03112.09
5.4.120.0050.03612.04
5.4.110.0020.04012.05
5.4.100.0040.03712.05
5.4.90.0060.03612.04
5.4.80.0060.03612.04
5.4.70.0040.03612.04
5.4.60.0060.03612.04
5.4.50.0060.03512.04
5.4.40.0120.03012.03
5.4.30.0060.03612.03
5.4.20.0050.03612.02
5.4.10.0040.03712.02
5.4.00.0030.03811.52
5.3.290.0060.05012.80
5.3.280.0070.03712.71
5.3.270.0070.03812.72
5.3.260.0110.03412.72
5.3.250.0070.03612.72
5.3.240.0070.04412.72
5.3.230.0080.03612.71
5.3.220.0050.05112.68
5.3.210.0060.04512.68
5.3.200.0080.03512.68
5.3.190.0080.03612.68
5.3.180.0050.04012.68
5.3.170.0070.03612.67
5.3.160.0040.03812.68
5.3.150.0060.03812.67
5.3.140.0050.04112.67
5.3.130.0070.03912.66
5.3.120.0050.04212.66
5.3.110.0040.04212.66
5.3.100.0060.03912.15
5.3.90.0070.03712.13
5.3.80.0050.03912.12
5.3.70.0100.03412.13
5.3.60.0070.03812.11
5.3.50.0040.03812.05
5.3.40.0070.03812.05
5.3.30.0070.03412.01
5.3.20.0070.04211.80
5.3.10.0030.03711.76
5.3.00.0070.03511.75
5.2.170.0070.0329.25
5.2.160.0050.0289.25
5.2.150.0050.0309.25
5.2.140.0050.0309.24
5.2.130.0060.0289.21
5.2.120.0050.0289.21
5.2.110.0060.0289.21
5.2.100.0050.0289.21
5.2.90.0070.0319.21
5.2.80.0020.0349.20
5.2.70.0050.0319.20
5.2.60.0080.0289.16
5.2.50.0040.0319.13
5.2.40.0050.0309.10
5.2.30.0050.0349.08
5.2.20.0020.0349.07
5.2.10.0040.0348.98
5.2.00.0030.0328.84
5.1.60.0060.0278.12
5.1.50.0060.0338.12
5.1.40.0040.0358.09
5.1.30.0040.0268.45
5.1.20.0050.0378.47
5.1.10.0170.0348.19
5.1.00.0050.0258.20
5.0.50.0020.0246.67
5.0.40.0040.0196.53
5.0.30.0050.0296.35
5.0.20.0020.0246.29
5.0.10.0030.0216.27
5.0.00.0060.0316.27
4.4.90.0030.0184.78
4.4.80.0040.0154.75
4.4.70.0010.0194.75
4.4.60.0040.0154.75
4.4.50.0050.0194.77
4.4.40.0020.0294.71
4.4.30.0060.0184.76
4.4.20.0020.0184.84
4.4.10.0050.0194.84
4.4.00.0030.0284.76
4.3.110.0030.0154.67
4.3.100.0020.0164.66
4.3.90.0010.0164.63
4.3.80.0040.0244.58
4.3.70.0030.0174.63
4.3.60.0040.0154.63
4.3.50.0030.0154.63
4.3.40.0050.0274.54
4.3.30.0040.0203.34
4.3.20.0010.0173.31
4.3.10.0030.0163.21
4.3.00.0000.01315.27

preferences:
39.56 ms | 401 KiB | 5 Q