3v4l.org

run code in 300+ PHP versions simultaneously
<?php declare(strict_types=1); function sum(int ...$numbers): int { $acc = 0; foreach ($numbers as $n) { $acc += $n; } return $acc; } echo sum(1, 2, 3, 4);

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.80.0040.00418.55
8.3.70.0070.00716.75
8.3.60.0140.00418.43
8.3.50.0120.00717.21
8.3.40.0130.00318.75
8.3.30.0090.00618.85
8.3.20.0030.00519.28
8.3.10.0080.00019.29
8.3.00.0040.00423.56
8.2.200.0040.00716.38
8.2.190.0070.01116.58
8.2.180.0060.00918.29
8.2.170.0120.00922.96
8.2.160.0070.01019.39
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0120.00419.82
8.2.120.0040.00426.35
8.2.110.0090.00020.56
8.2.100.0110.00417.91
8.2.90.0030.00617.66
8.2.80.0080.00018.22
8.2.70.0040.00417.63
8.2.60.0090.00017.63
8.2.50.0080.00019.48
8.2.40.0000.00817.63
8.2.30.0040.00419.41
8.2.20.0040.00418.03
8.2.10.0050.00217.98
8.2.00.0040.00419.43
8.1.290.0040.00430.84
8.1.280.0110.00325.92
8.1.270.0080.00022.20
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0100.00023.85
8.1.230.0040.00720.86
8.1.220.0040.00417.76
8.1.210.0040.00418.98
8.1.200.0060.00317.23
8.1.190.0080.00017.10
8.1.180.0000.00818.10
8.1.170.0040.00418.82
8.1.160.0070.00018.85
8.1.150.0050.00218.77
8.1.140.0040.00417.66
8.1.130.0080.00418.95
8.1.120.0000.00817.44
8.1.110.0090.00017.36
8.1.100.0000.00917.42
8.1.90.0030.00617.38
8.1.80.0040.00417.35
8.1.70.0070.00017.36
8.1.60.0040.00417.59
8.1.50.0000.00817.51
8.1.40.0030.00517.41
8.1.30.0060.00317.53
8.1.20.0000.00717.66
8.1.10.0000.00817.59
8.1.00.0040.00417.47
8.0.300.0070.00019.86
8.0.290.0000.00716.63
8.0.280.0050.00318.50
8.0.270.0000.00717.27
8.0.260.0060.00017.21
8.0.250.0080.00016.97
8.0.240.0040.00416.83
8.0.230.0000.00716.95
8.0.220.0060.00316.91
8.0.210.0040.00416.85
8.0.200.0030.00317.05
8.0.190.0030.00516.95
8.0.180.0070.00016.96
8.0.170.0060.00316.82
8.0.160.0000.00916.93
8.0.150.0050.00516.82
8.0.140.0040.00416.75
8.0.130.0000.00613.31
8.0.120.0080.00016.80
8.0.110.0030.00316.71
8.0.100.0070.00016.84
8.0.90.0030.00516.89
8.0.80.0130.00716.79
8.0.70.0040.00416.93
8.0.60.0000.00716.71
8.0.50.0000.00816.71
8.0.30.0080.00817.00
8.0.20.0070.01117.40
8.0.10.0000.00717.06
8.0.00.0090.00916.68
7.4.330.0000.00415.55
7.4.320.0060.00016.61
7.4.300.0060.00016.59
7.4.290.0000.00716.54
7.4.280.0000.00716.61
7.4.270.0060.00316.50
7.4.260.0050.00216.58
7.4.250.0000.00916.32
7.4.240.0020.00516.41
7.4.230.0000.00716.70
7.4.220.0000.00816.35
7.4.210.0080.00716.56
7.4.200.0000.00716.58
7.4.160.0080.00716.49
7.4.140.0170.00717.86
7.4.130.0140.00416.47
7.4.120.0110.00816.55
7.4.110.0130.00716.00
7.4.100.0080.01016.30
7.4.90.0080.01016.44
7.4.80.0080.01017.87
7.4.70.0110.01016.24
7.4.60.0120.01116.31
7.4.50.0080.01016.25
7.4.40.0100.00716.36
7.4.30.0130.00816.28
7.4.20.0100.01116.24
7.4.10.0080.01316.25
7.4.00.0070.01015.67
7.3.330.0000.00513.39
7.3.320.0030.00313.35
7.3.310.0000.00716.42
7.3.300.0000.00616.38
7.3.290.0030.00316.38
7.3.280.0080.00616.38
7.3.260.0080.01016.47
7.3.240.0100.01016.41
7.3.230.0070.01016.26
7.3.220.0070.01016.43
7.3.210.0110.00816.63
7.3.200.0100.01016.38
7.3.190.0050.01216.38
7.3.180.0120.00716.30
7.3.170.0100.00916.43
7.3.160.0130.00316.48
7.3.150.0210.00016.48
7.3.140.0060.01216.28
7.3.130.0080.01116.12
7.3.120.0090.00916.30
7.3.110.0000.01816.17
7.3.100.0150.00915.98
7.3.90.0120.00616.39
7.3.80.0180.00016.26
7.3.70.0060.01215.98
7.3.60.0100.00716.23
7.3.50.0050.01316.04
7.3.40.0100.00616.38
7.3.30.0070.01016.13
7.3.20.0030.01316.17
7.3.10.0100.00616.56
7.3.00.0080.01016.45
7.2.340.0170.00016.34
7.2.330.0120.00716.44
7.2.320.0080.01216.61
7.2.310.0140.00616.45
7.2.300.0140.00316.38
7.2.290.0110.00816.60
7.2.280.0170.00416.47
7.2.270.0070.01116.46
7.2.260.0030.01416.52
7.2.250.0040.01316.28
7.2.240.0150.00316.23
7.2.230.0130.00616.48
7.2.220.0140.00316.23
7.2.210.0130.00316.30
7.2.200.0070.01116.36
7.2.190.0070.01116.30
7.2.180.0070.01016.40
7.2.170.0090.00916.17
7.2.160.0090.01516.28
7.2.150.0140.00416.40
7.2.140.0060.01316.43
7.2.130.0220.00616.61
7.2.120.0080.00816.45
7.2.110.0080.00916.58
7.2.100.0100.00316.65
7.2.90.0110.00516.66
7.2.80.0090.00516.67
7.2.70.0100.00616.62
7.2.60.0450.00816.07
7.2.50.0370.00415.96
7.2.40.0540.01016.14
7.2.30.0460.01016.23
7.2.20.0530.00416.23
7.2.10.0510.01116.29
7.2.00.0490.01016.26
7.1.330.0140.00515.32
7.1.320.0100.00615.34
7.1.310.0160.00315.32
7.1.300.0070.01115.59
7.1.290.0090.00915.63
7.1.280.0120.00815.73
7.1.270.0140.00315.09
7.1.260.0130.00315.00
7.1.250.0050.00815.59
7.1.240.0130.00415.54
7.1.230.0100.00615.32
7.1.220.0030.01415.35
7.1.210.0130.00315.55
7.1.200.0120.00215.67
7.1.190.0130.00515.43
7.1.180.0100.01315.45
7.1.170.0710.00614.39
7.1.160.0680.01116.06
7.1.150.0680.01316.13
7.1.140.0880.00916.07
7.1.130.0710.01016.06
7.1.120.0860.00816.16
7.1.110.0830.00415.83
7.1.100.0770.00916.02
7.1.90.0970.00815.64
7.1.80.0700.01215.60
7.1.70.0780.00715.28
7.1.60.0930.00824.36
7.1.50.0810.01124.25
7.1.40.1020.01324.08
7.1.30.0900.01224.02
7.1.20.0900.01224.10
7.1.10.0720.01115.16
7.1.00.0940.00615.00
7.0.330.0140.00015.02
7.0.320.0060.00914.91
7.0.310.0130.00315.08
7.0.300.0040.01214.99
7.0.290.0070.01115.12
7.0.280.0090.00915.04
7.0.270.0100.00714.78
7.0.260.0000.01515.04
7.0.250.0110.00615.05
7.0.240.0090.00715.36
7.0.230.0030.01314.80
7.0.220.0140.00514.96
7.0.210.0070.00715.07
7.0.200.0040.01115.26
7.0.190.0040.01215.14
7.0.180.0080.00815.03
7.0.170.0030.01315.12
7.0.160.0080.00815.25
7.0.150.0080.01115.11
7.0.140.0070.01015.29
7.0.130.0070.01015.24
7.0.120.0070.01015.16
7.0.110.0080.00815.17
7.0.100.0100.00715.10
7.0.90.0120.00415.04
7.0.80.0060.01515.11
7.0.70.0180.00315.03
7.0.60.0120.00315.09
7.0.50.0090.01215.16
7.0.40.0040.01115.08
7.0.30.0060.00915.13
7.0.20.0090.00615.18
7.0.10.0060.00915.05
7.0.00.0130.00315.08
5.6.400.0160.00315.39
5.6.390.0100.00715.55
5.6.380.0080.01115.54
5.6.370.0030.01615.56
5.6.360.0150.00315.70
5.6.350.0080.01115.36
5.6.340.0000.01815.80
5.6.330.0140.00715.32
5.6.320.0090.00915.80
5.6.310.0090.00915.70
5.6.300.0040.01415.52
5.6.290.0060.01315.78
5.6.280.0140.01015.63
5.6.270.0100.01015.75
5.6.260.0080.01215.69
5.6.250.0130.01015.63
5.6.240.0110.00815.46
5.6.230.0090.00915.41
5.6.220.0090.00915.58
5.6.210.0220.00315.43
5.6.200.0170.00015.64
5.6.190.0120.00615.63
5.6.180.0100.00715.25
5.6.170.0110.00615.62
5.6.160.0120.00615.68
5.6.150.0120.00615.42
5.6.140.0110.00715.28
5.6.130.0120.00615.46
5.6.120.0060.01215.67
5.6.110.0030.01615.25
5.6.100.0100.01315.83
5.6.90.0040.01515.55
5.6.80.0070.01315.87
5.6.70.0090.00915.35
5.6.60.0160.00615.32
5.6.50.0160.00315.26
5.6.40.0120.01215.45
5.6.30.0070.01315.36
5.6.20.0110.00715.49
5.6.10.0070.01315.45
5.6.00.0130.01015.53

preferences:
28.64 ms | 401 KiB | 5 Q