3v4l.org

run code in 300+ PHP versions simultaneously
<?php function gen($a) { try { $b = yield $a; yield $a + $b + 1; } catch (Exception $e) { echo "Caught Exception: {$e->getMessage()}\n"; } } function yf() { yield from gen(1); yield from gen(4); } $g = yf(); $g->current(); $g->throw(new Exception("Whoa there lassie")); echo "Sup son!\n";

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.0180.00416.50
8.3.50.0160.00321.91
8.3.40.0110.01119.02
8.3.30.0180.00318.71
8.3.20.0040.00420.16
8.3.10.0080.00023.52
8.3.00.0080.00019.26
8.2.180.0090.01218.41
8.2.170.0080.00622.96
8.2.160.0070.01122.18
8.2.150.0040.00424.18
8.2.140.0000.00724.66
8.2.130.0090.00017.60
8.2.120.0020.00526.35
8.2.110.0090.00020.38
8.2.100.0090.00318.03
8.2.90.0000.00819.05
8.2.80.0030.00617.97
8.2.70.0060.00317.63
8.2.60.0000.00817.80
8.2.50.0030.00518.07
8.2.40.0040.00419.39
8.2.30.0040.00420.61
8.2.20.0000.00817.66
8.2.10.0030.00518.12
8.2.00.0030.00518.11
8.1.280.0090.00925.92
8.1.270.0060.00322.10
8.1.260.0040.00428.09
8.1.250.0040.00428.09
8.1.240.0030.00622.03
8.1.230.0040.00817.66
8.1.220.0050.00317.74
8.1.210.0060.00318.77
8.1.200.0060.00317.48
8.1.190.0000.00817.23
8.1.180.0040.00418.10
8.1.170.0050.00318.71
8.1.160.0040.00422.06
8.1.150.0030.00618.89
8.1.140.0040.00419.54
8.1.130.0040.00417.81
8.1.120.0000.00717.36
8.1.110.0030.00517.53
8.1.100.0060.00317.43
8.1.90.0040.00417.46
8.1.80.0050.00317.30
8.1.70.0070.00017.38
8.1.60.0040.00417.46
8.1.50.0040.00417.41
8.1.40.0030.00517.40
8.1.30.0060.00317.70
8.1.20.0000.00717.66
8.1.10.0040.00417.57
8.1.00.0060.00317.54
8.0.300.0040.00418.77
8.0.290.0000.00716.75
8.0.280.0070.00018.32
8.0.270.0040.00417.25
8.0.260.0000.00617.17
8.0.250.0070.00017.07
8.0.240.0000.00717.06
8.0.230.0000.00717.00
8.0.220.0030.00317.03
8.0.210.0030.00316.84
8.0.200.0000.00617.11
8.0.190.0000.01017.00
8.0.180.0070.00017.03
8.0.170.0040.00416.88
8.0.160.0000.00816.95
8.0.150.0000.00716.96
8.0.140.0080.00316.89
8.0.130.0060.00013.34
8.0.120.0000.00816.93
8.0.110.0040.00416.87
8.0.100.0080.00017.01
8.0.90.0000.00717.07
8.0.80.0070.01317.01
8.0.70.0080.00017.00
8.0.60.0070.00016.83
8.0.50.0040.00416.85
8.0.30.0070.01217.12
8.0.20.0060.01417.40
8.0.10.0020.00516.99
8.0.00.0060.01116.89
7.4.330.0000.00516.70
7.4.320.0070.00016.51
7.4.300.0000.00616.59
7.4.290.0030.00316.42
7.4.280.0000.01016.48
7.4.270.0000.00816.66
7.4.260.0030.00316.39
7.4.250.0030.00516.41
7.4.240.0040.00316.61
7.4.230.0030.00316.34
7.4.220.0170.01116.67
7.4.210.0070.01016.70
7.4.200.0040.00416.52
7.4.160.0100.00616.52
7.4.150.0100.00717.40
7.4.140.0180.00817.86
7.4.130.0070.01016.60
7.4.120.0100.00816.46
7.4.110.0090.00916.50
7.4.100.0060.01216.70
7.4.90.0090.01216.67
7.4.80.0080.01119.39
7.4.70.0060.01616.55
7.4.60.0150.00316.43
7.4.50.0030.01016.55
7.4.40.0090.00616.48
7.4.30.0090.00916.36
7.4.10.0060.01115.00
7.4.00.0050.01214.89
7.3.330.0030.00313.32
7.3.320.0030.00313.36
7.3.310.0000.00716.40
7.3.300.0030.00316.37
7.3.290.0040.01016.31
7.3.280.0120.00716.36
7.3.270.0130.01017.40
7.3.260.0060.01216.40
7.3.250.0110.00716.47
7.3.240.0120.00816.41
7.3.230.0120.00416.50
7.3.210.0130.01016.38
7.3.200.0100.01116.62
7.3.190.0140.00616.28
7.3.180.0130.00316.42
7.3.170.0110.01116.59
7.3.160.0130.01016.32
7.3.130.0070.01014.83
7.3.120.0080.00914.90
7.3.110.0080.00814.67
7.3.100.0030.01314.91
7.3.90.0050.00914.91
7.3.80.0060.00714.91
7.3.70.0050.00814.67
7.3.60.0060.00714.84
7.3.50.0060.00714.87
7.3.40.0070.00814.74
7.3.30.0050.00714.82
7.3.20.0060.00816.61
7.3.10.0100.00416.62
7.3.00.0060.00816.74
7.2.330.0120.00916.79
7.2.320.0060.01316.40
7.2.310.0060.00916.38
7.2.300.0090.00616.80
7.2.290.0040.01816.81
7.2.260.0120.00414.97
7.2.250.0070.01114.99
7.2.240.0070.00915.07
7.2.230.0040.01115.09
7.2.220.0050.01115.14
7.2.210.0050.01015.01
7.2.200.0050.00914.84
7.2.190.0090.00415.11
7.2.180.0030.01015.11
7.2.170.0040.00715.08
7.2.160.0060.00715.12
7.2.150.0020.01016.91
7.2.140.0080.00516.98
7.2.130.0060.00716.88
7.2.120.0040.00916.88
7.2.110.0050.00717.03
7.2.100.0080.00817.05
7.2.90.0060.00716.76
7.2.80.0070.00616.97
7.2.70.0050.01116.94
7.2.60.0070.00516.93
7.2.50.0070.00716.98
7.2.40.0040.00817.05
7.2.30.0080.00916.95
7.2.20.0050.00816.90
7.2.10.0090.00616.81
7.2.00.0060.00917.43
7.1.330.0050.00815.70
7.1.320.0070.00615.76
7.1.310.0050.00615.85
7.1.300.0050.00715.62
7.1.290.0070.00515.64
7.1.280.0080.00515.55
7.1.270.0080.00715.71
7.1.260.0040.00615.85
7.1.250.0040.00815.72
7.1.240.0040.01015.74
7.1.230.0040.00915.69
7.1.220.0070.00615.77
7.1.210.0070.00615.77
7.1.200.0070.00515.60
7.1.190.0040.00915.83
7.1.180.0050.00615.66
7.1.170.0050.00815.66
7.1.160.0050.00815.74
7.1.150.0050.00915.73
7.1.140.0060.00515.71
7.1.130.0060.00615.70
7.1.120.0070.00615.71
7.1.110.0020.00915.74
7.1.100.0060.00516.26
7.1.90.0080.00315.67
7.1.80.0050.00715.79
7.1.70.0050.00716.01
7.1.60.0040.01016.54
7.1.50.0090.00715.84
7.1.40.0040.00715.68
7.1.30.0050.00715.67
7.1.20.0040.01015.77
7.1.10.0060.01015.68
7.1.00.0090.01817.03
7.0.330.0050.00815.34
7.0.320.0020.01215.40
7.0.310.0020.01115.29
7.0.300.0030.00815.39
7.0.290.0060.00715.27
7.0.280.0030.01015.41
7.0.270.0070.00615.41
7.0.260.0060.00715.44
7.0.250.0060.00615.32
7.0.240.0060.00715.37
7.0.230.0060.00615.46
7.0.220.0020.01015.38
7.0.210.0040.00815.37
7.0.200.0100.00815.16
7.0.190.0060.00815.42
7.0.180.0030.00815.42
7.0.170.0060.00615.22
7.0.160.0040.00815.31
7.0.150.0060.00715.36
7.0.140.0080.00215.26
7.0.130.0060.00815.45
7.0.120.0030.00715.39
7.0.110.0070.00515.34
7.0.100.0030.00815.46
7.0.90.0040.00715.35
7.0.80.0050.00715.45
7.0.70.0080.00415.56
7.0.60.0060.01916.66
7.0.50.0070.02115.80
7.0.40.0080.01314.84
7.0.30.0090.02014.83
7.0.20.0060.01614.86
7.0.10.0070.02114.84
7.0.00.0080.01614.75
5.6.400.0080.00614.18
5.6.390.0050.00614.17
5.6.380.0050.00914.18
5.6.370.0050.00714.19
5.6.360.0020.00814.17
5.6.350.0060.00814.17
5.6.340.0070.00614.13
5.6.330.0040.01014.14
5.6.320.0090.00414.05
5.6.310.0080.00614.20
5.6.300.0040.01014.05
5.6.290.0080.00514.07
5.6.280.0030.01715.63
5.6.270.0050.00514.14
5.6.260.0050.00714.10
5.6.250.0040.00914.12
5.6.240.0050.00714.12
5.6.230.0090.00314.12
5.6.220.0010.00814.02
5.6.210.0050.02415.35
5.6.200.0040.02214.96
5.6.190.0080.01415.41
5.6.180.0120.01415.38
5.6.170.0120.01615.41
5.6.160.0030.02315.38
5.6.150.0090.01914.83
5.6.140.0060.01514.93
5.6.130.0060.01714.97
5.6.120.0060.02115.47
5.6.110.0060.01515.53
5.6.100.0060.02715.44
5.6.90.0080.02215.45
5.6.80.0060.01815.35
5.6.70.0040.00914.17
5.6.60.0040.01014.03
5.6.50.0060.00814.19
5.6.40.0050.00713.96
5.6.30.0060.00813.89
5.6.20.0060.00913.99
5.6.10.0070.00814.04
5.6.00.0070.00714.12
5.5.380.0080.00614.06
5.5.370.0060.00714.12
5.5.360.0040.00714.17
5.5.350.0090.02115.26
5.5.340.0050.02214.76
5.5.330.0050.01515.42
5.5.320.0160.02115.30
5.5.310.0090.01515.25
5.5.300.0050.01514.75
5.5.290.0070.01414.82
5.5.280.0030.02515.38
5.5.270.0080.01815.40
5.5.260.0050.02315.53
5.5.250.0070.01415.43
5.5.240.0030.02315.27
5.5.230.0040.00913.97
5.5.220.0060.00713.92
5.5.210.0070.00513.95
5.5.200.0070.00814.10
5.5.190.0030.00914.00
5.5.180.0050.00713.92
5.5.170.0060.00813.95
5.5.160.0070.00613.99
5.5.150.0020.00913.93
5.5.140.0050.00814.00
5.5.130.0050.00914.02
5.5.120.0050.00713.82
5.5.110.0060.00614.01
5.5.100.0060.00713.80
5.5.90.0030.00813.82
5.5.80.0060.00614.05
5.5.70.0040.00713.87
5.5.60.0070.00713.95
5.5.50.0060.00614.10
5.5.40.0060.00613.96
5.5.30.0050.00613.90
5.5.20.0080.00513.95
5.5.10.0070.00713.77
5.5.00.0050.00813.96

preferences:
54.94 ms | 401 KiB | 5 Q