3v4l.org

run code in 300+ PHP versions simultaneously
<?php $cls0 = new stdClass(); $cls1 = new stdClass(); $cls2 = new stdClass(); $cls3 = new stdClass(); $cls4 = new stdClass(); $cls5 = new stdClass(); $cls6 = new stdClass(); $cls7 = new stdClass(); $cls8 = new stdClass(); $cls9 = new stdClass(); $arr = array($cls0, $cls1, $cls2, $cls3, $cls4, $cls5, $cls6, $cls7, $cls8, $cls9); foreach ($arr as $obj) { $obj->name = 'test'; }

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.00718.33
8.3.50.0160.01017.29
8.3.40.0090.00618.54
8.3.30.0030.01318.67
8.3.20.0050.00318.68
8.3.10.0050.00320.46
8.3.00.0100.00619.38
8.2.180.0030.01416.32
8.2.170.0090.00922.96
8.2.160.0090.00622.18
8.2.150.0000.00824.18
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0080.00019.89
8.2.110.0030.00622.27
8.2.100.0160.00217.91
8.2.90.0000.00817.63
8.2.80.0050.00319.11
8.2.70.0060.00317.93
8.2.60.0030.00618.22
8.2.50.0040.00418.10
8.2.40.0080.00020.45
8.2.30.0000.00818.02
8.2.20.0070.00017.72
8.2.10.0050.00317.71
8.2.00.0000.00717.69
8.1.280.0070.00725.92
8.1.270.0000.00823.99
8.1.260.0030.00526.35
8.1.250.0040.00428.09
8.1.240.0030.00623.80
8.1.230.0040.00719.08
8.1.220.0030.00617.74
8.1.210.0060.00318.77
8.1.200.0000.01017.35
8.1.190.0030.00617.13
8.1.180.0030.00618.10
8.1.170.0000.00818.65
8.1.160.0070.00018.88
8.1.150.0070.00018.55
8.1.140.0000.00717.45
8.1.130.0000.00717.77
8.1.120.0040.00417.36
8.1.110.0000.00717.35
8.1.100.0000.00817.34
8.1.90.0070.00017.49
8.1.80.0030.00417.54
8.1.70.0040.00417.41
8.1.60.0000.00817.63
8.1.50.0050.00517.45
8.1.40.0080.00017.55
8.1.30.0050.00317.71
8.1.20.0030.00517.70
8.1.10.0040.00417.54
8.1.00.0000.00817.53
8.0.300.0050.00321.52
8.0.290.0090.00016.63
8.0.280.0030.00318.40
8.0.270.0000.00717.17
8.0.260.0000.00818.39
8.0.250.0040.00417.01
8.0.240.0060.00316.90
8.0.230.0040.00416.92
8.0.220.0000.00816.87
8.0.210.0030.00516.82
8.0.200.0020.00516.97
8.0.190.0030.00516.98
8.0.180.0000.00716.93
8.0.170.0000.01116.92
8.0.160.0000.00716.79
8.0.150.0040.00416.86
8.0.140.0060.00316.89
8.0.130.0000.00513.30
8.0.120.0050.00216.91
8.0.110.0000.00716.77
8.0.100.0050.00216.89
8.0.90.0030.00516.86
8.0.80.0060.00916.90
8.0.70.0070.00016.80
8.0.60.0000.00816.96
8.0.50.0070.00016.87
8.0.30.0120.00716.85
8.0.20.0120.00617.40
8.0.10.0070.00016.98
8.0.00.0080.01016.76
7.4.330.0000.00513.43
7.4.320.0020.00516.65
7.4.300.0060.00016.59
7.4.290.0030.00316.40
7.4.280.0070.00016.58
7.4.270.0000.00616.62
7.4.260.0030.00313.31
7.4.250.0040.00416.58
7.4.240.0000.00716.50
7.4.230.0050.00216.30
7.4.220.0040.01416.67
7.4.210.0120.00516.61
7.4.200.0030.00616.50
7.4.190.0050.00316.32
7.4.160.0070.00716.68
7.4.150.0180.00017.40
7.4.140.0080.00917.23
7.4.130.0070.01016.61
7.4.120.0070.01216.59
7.4.110.0110.00616.61
7.4.100.0090.00816.43
7.4.90.0070.01016.43
7.4.80.0120.00618.80
7.4.70.0130.00316.41
7.4.60.0100.01016.50
7.4.50.0030.00516.36
7.4.40.0120.00322.27
7.4.30.0030.01316.68
7.4.00.0060.00915.09
7.3.330.0060.00013.12
7.3.320.0000.00512.98
7.3.310.0050.00216.27
7.3.300.0000.00716.27
7.3.290.0040.01016.29
7.3.280.0090.00716.23
7.3.270.0040.01217.40
7.3.260.0110.01118.24
7.3.250.0090.00816.32
7.3.240.0060.01016.36
7.3.230.0150.00416.39
7.3.210.0040.01216.19
7.3.200.0030.01719.39
7.3.190.0110.01116.33
7.3.180.0100.00616.27
7.3.170.0120.00616.45
7.3.160.0060.01016.54
7.3.120.0070.00714.86
7.2.330.0170.00016.80
7.2.320.0060.01216.90
7.2.310.0100.01416.43
7.2.300.0040.01216.64
7.2.290.0170.00016.58
7.2.00.0060.00919.24
7.1.100.0030.00618.16
7.1.70.0070.00316.76
7.1.60.0060.01919.40
7.1.50.0000.02116.56
7.1.00.0030.07022.54
7.0.200.0030.00516.85
7.0.140.0000.07322.10
7.0.60.0030.04021.63
7.0.50.0000.05722.09
7.0.40.0000.04719.96
7.0.30.0030.08020.11
7.0.20.0070.04020.15
7.0.10.0070.07020.03
7.0.00.0030.06320.11
5.6.280.0030.07320.77
5.6.210.0000.04320.51
5.6.200.0070.07020.90
5.6.190.0070.05721.15
5.6.180.0070.09021.02
5.6.170.0000.05320.98
5.6.160.0000.08321.00
5.6.150.0070.07320.98
5.6.140.0070.03720.98
5.6.130.0070.07721.02
5.6.120.0130.06320.98
5.6.110.0030.05021.13
5.6.100.0070.08021.13
5.6.90.0030.04720.87
5.6.80.0070.05020.37
5.6.70.0030.09020.27
5.6.60.0000.04020.37
5.6.50.0000.04720.50
5.6.40.0030.05020.48
5.6.30.0100.03020.34
5.6.20.0070.03720.43
5.6.10.0030.05020.40
5.6.00.0030.07720.39
5.5.350.0070.06320.44
5.5.340.0000.07320.96
5.5.330.0100.07320.87
5.5.320.0100.03720.73
5.5.310.0030.07320.88
5.5.300.0030.07720.68
5.5.290.0070.05020.89
5.5.280.0030.08020.72
5.5.270.0030.04020.76
5.5.260.0030.04720.88
5.5.250.0000.04320.79
5.5.240.0000.05320.36
5.5.230.0030.04720.25
5.5.220.0030.04020.24
5.5.210.0000.05020.12
5.5.200.0070.03720.16
5.5.190.0070.04720.21
5.5.180.0030.04020.25
5.5.160.0130.07020.10
5.5.150.0000.08720.21
5.5.140.0100.07720.19
5.5.130.0030.04720.23
5.5.120.0070.07720.32
5.5.110.0000.08320.12
5.5.100.0070.07719.99
5.5.90.0100.06320.12
5.5.80.0070.07319.96
5.5.70.0100.07320.04
5.5.60.0030.06019.99
5.5.50.0030.07320.03
5.5.40.0030.07720.09
5.5.30.0030.08020.19
5.5.20.0000.07019.93
5.5.10.0100.07320.06
5.5.00.0070.07320.04
5.4.450.0070.07319.43
5.4.440.0070.06319.22
5.4.430.0030.04019.27
5.4.420.0030.06019.48
5.4.410.0070.03319.14
5.4.400.0000.04018.99
5.4.390.0000.04018.95
5.4.380.0000.04319.03
5.4.370.0000.03719.10
5.4.360.0030.03719.06
5.4.350.0000.07018.90
5.4.340.0000.06019.03
5.4.320.0000.08019.16
5.4.310.0000.04318.85
5.4.300.0070.08019.10
5.4.290.0030.07318.84
5.4.280.0270.05319.19
5.4.270.0030.07318.94
5.4.260.0170.07019.10
5.4.250.0070.07718.98
5.4.240.0070.07319.00
5.4.230.0100.06718.92
5.4.220.0070.07319.00
5.4.210.0030.07719.04
5.4.200.0100.07019.00
5.4.190.0100.07718.93
5.4.180.0030.07719.01
5.4.170.0000.05019.05
5.4.160.0070.07718.90
5.4.150.0030.08019.14
5.4.140.0070.06716.38
5.4.130.0000.08316.36
5.4.120.0070.06716.21
5.4.110.0070.07016.44
5.4.100.0070.07316.33
5.4.90.0000.06316.21
5.4.80.0030.03316.28
5.4.70.0000.07316.29
5.4.60.0030.05016.39
5.4.50.0000.07316.27
5.4.40.0030.05716.43
5.4.30.0070.06316.29
5.4.20.0000.07016.27
5.4.10.0030.07016.45
5.4.00.0000.06315.85
5.3.290.0030.05714.59
5.3.280.0030.07314.55
5.3.270.0030.07314.59
5.3.260.0000.07714.45
5.3.250.0030.07714.54
5.3.240.0030.07014.56
5.3.230.0000.06014.53
5.3.220.0070.07014.51
5.3.210.0100.06714.38
5.3.200.0030.07014.36
5.3.190.0100.06714.52
5.3.180.0000.04314.55
5.3.170.0000.04014.52
5.3.160.0100.03314.46
5.3.150.0070.03714.54
5.3.140.0030.06714.50
5.3.130.0000.06714.53
5.3.120.0000.08014.56
5.3.110.0100.07314.41
5.3.100.0070.06013.98
5.3.90.0000.04013.98
5.3.80.0070.05713.87
5.3.70.0030.03713.95
5.3.60.0030.07013.92
5.3.50.0000.07313.73
5.3.40.0070.07013.93
5.3.30.0000.07713.76
5.3.20.0030.07313.67
5.3.10.0100.05313.50
5.3.00.0030.07313.49
5.2.170.0000.07011.16
5.2.160.0030.04311.06
5.2.150.0000.06311.12
5.2.140.0100.06011.07
5.2.130.0030.06311.09
5.2.120.0000.05011.10
5.2.110.0030.05711.05
5.2.100.0070.06011.05
5.2.90.0070.06310.88
5.2.80.0030.05311.03
5.2.70.0030.06011.09
5.2.60.0070.04011.06
5.2.50.0000.06310.81
5.2.40.0000.06010.79
5.2.30.0100.05310.90
5.2.20.0000.06310.88
5.2.10.0030.05310.91
5.2.00.0070.04710.62
5.1.60.0070.05310.52
5.1.50.0070.04010.52
5.1.40.0000.05010.52
5.1.30.0000.04310.52
5.1.20.0000.05310.52
5.1.10.0030.03310.52
5.1.00.0000.02710.52
5.0.50.0070.03010.52
5.0.40.0000.03710.52
5.0.30.0070.05310.52
5.0.20.0000.04010.52
5.0.10.0030.03310.52
5.0.00.0000.06310.52
4.4.90.0030.03310.52
4.4.80.0000.03310.52
4.4.70.0030.03010.52
4.4.60.0000.03710.52
4.4.50.0030.03310.52
4.4.40.0030.04310.52
4.4.30.0030.03710.52
4.4.20.0000.03010.52
4.4.10.0000.03710.52
4.4.00.0000.03710.52
4.3.110.0030.01710.52
4.3.100.0000.04010.52
4.3.90.0000.03710.52
4.3.80.0000.05310.52
4.3.70.0030.03010.52
4.3.60.0030.03310.52
4.3.50.0000.03710.52
4.3.40.0030.04710.52
4.3.30.0000.03710.52
4.3.20.0000.04010.52
4.3.10.0000.04010.52
4.3.00.0030.03710.52

preferences:
42.92 ms | 401 KiB | 5 Q