3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { public function __construct (public readonly array $ary = [0,1,2,3]) {} } $obj = new A; var_dump(current($obj->ary)); next($obj->ary); var_dump(current($obj->ary));

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.4.140.0100.01217.69
8.4.130.0140.00717.83
8.4.120.0120.00822.64
8.4.110.0160.00520.93
8.4.100.0120.00917.94
8.4.90.0040.00518.71
8.4.80.0080.00417.98
8.4.70.0110.00518.08
8.4.60.0060.00318.91
8.4.50.0100.00518.04
8.4.40.0180.00019.42
8.4.30.0110.00018.78
8.4.20.0100.00019.00
8.4.10.0160.00318.72
8.3.260.0100.01016.59
8.3.250.0100.00818.93
8.3.240.0080.01016.68
8.3.230.0050.00316.75
8.3.220.0110.00718.89
8.3.210.0130.00616.84
8.3.200.0050.00416.68
8.3.190.0110.00717.17
8.3.180.0090.00716.82
8.3.170.0090.00919.05
8.3.160.0140.00416.69
8.3.150.0090.00620.64
8.3.140.0060.00316.61
8.3.130.0060.00318.77
8.3.120.0060.00318.61
8.3.110.0100.00018.77
8.3.100.0090.00618.47
8.3.50.0080.00018.56
8.2.290.0050.00420.30
8.2.280.0090.01018.43
8.2.270.0040.00417.07
8.2.260.0100.01018.95
8.2.250.0030.00618.82
8.2.240.0030.00616.94
8.2.230.0000.00818.33
8.2.220.0080.00018.77
8.1.330.0110.00720.34
8.1.320.0120.00917.90
8.1.310.0070.00416.89
8.1.300.0100.00616.69
8.0.90.0020.00516.68
8.0.80.0040.00416.81
8.0.70.0030.00316.75
8.0.60.0050.00316.89
8.0.50.0070.00216.88
8.0.30.0060.00316.75
8.0.20.0000.01017.02
8.0.10.0060.00216.73
8.0.00.0040.00416.75
7.4.220.0040.00416.42
7.4.210.0040.00416.52
7.4.200.0000.00716.25
7.4.190.0070.00016.54
7.4.180.0000.00816.39
7.4.160.0040.00416.31
7.4.150.0000.00716.25
7.4.140.0040.00416.20
7.4.130.0070.00016.20
7.4.120.0030.00516.15
7.4.110.0060.00316.20
7.4.100.0080.00016.16
7.4.90.0040.00416.02
7.4.80.0030.00316.40
7.4.70.0000.00716.30
7.4.60.0040.00416.10
7.4.50.0050.00216.02
7.4.40.0000.00716.25
7.4.30.0090.00016.35
7.4.20.0000.00716.22
7.4.10.0050.00315.99
7.4.00.0000.00716.43
7.3.290.0020.00516.06
7.3.280.0070.00016.12
7.3.270.0040.00416.16
7.3.260.0000.00716.18
7.3.250.0050.00316.09
7.3.240.0030.00516.07
7.3.230.0030.00516.12
7.3.220.0040.00416.02
7.3.210.0000.00716.06
7.3.200.0030.00616.13
7.3.190.0030.00516.16
7.3.180.0070.00016.10
7.3.170.0030.00515.96
7.3.160.0050.00316.14
7.3.150.0060.00316.14
7.3.140.0000.00816.11
7.3.130.0020.00516.13
7.3.120.0000.00816.12
7.3.110.0040.00416.00
7.3.100.0070.00016.08
7.3.90.0000.00916.42
7.3.80.0090.00015.97
7.3.70.0030.00516.22
7.3.60.0070.00016.13
7.3.50.0040.00416.08
7.3.40.0040.00416.22
7.3.30.0070.00016.18
7.3.20.0100.00016.31
7.3.10.0080.00016.05
7.3.00.0040.00416.23

preferences:
69.62 ms | 403 KiB | 5 Q