3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A{ private $stuff = 10; function test(){ return new class($this){ function __construct(A $s){ $this->s = $s; } function test(){ return $this->s->stuff; } }; } } $x = new A; $x->test()->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.0070.01118.55
8.3.50.0110.00418.18
8.3.40.0100.00618.93
8.3.30.0040.01118.82
8.3.20.0040.00420.04
8.3.10.0040.00420.48
8.3.00.0060.00320.59
8.2.180.0090.01216.63
8.2.170.0070.01422.96
8.2.160.0100.00319.46
8.2.150.0050.00324.18
8.2.140.0090.00024.66
8.2.130.0040.00421.01
8.2.120.0040.00426.35
8.2.110.0090.00020.89
8.2.100.0030.00717.93
8.2.90.0040.00419.23
8.2.80.0000.00817.97
8.2.70.0000.00817.63
8.2.60.0000.00818.04
8.2.50.0040.00418.09
8.2.40.0040.00420.59
8.2.30.0040.00419.50
8.2.20.0000.00717.81
8.2.10.0050.00218.02
8.2.00.0050.00218.20
8.1.280.0130.00425.92
8.1.270.0040.00423.92
8.1.260.0040.00428.09
8.1.250.0000.00928.09
8.1.240.0040.00421.16
8.1.230.0070.00417.76
8.1.220.0000.00817.74
8.1.210.0100.00018.77
8.1.200.0000.00917.23
8.1.190.0050.00317.25
8.1.180.0040.00418.10
8.1.170.0030.00618.50
8.1.160.0040.00420.62
8.1.150.0040.00418.77
8.1.140.0050.00319.46
8.1.130.0030.00317.63
8.1.120.0030.00317.57
8.1.110.0070.00017.32
8.1.100.0000.00717.44
8.1.90.0000.00817.40
8.1.80.0000.00817.45
8.1.70.0070.00317.52
8.1.60.0080.00017.54
8.1.50.0030.00617.46
8.1.40.0080.00417.41
8.1.30.0000.00817.66
8.1.20.0000.00717.52
8.1.10.0070.00017.63
8.1.00.0000.00817.58
8.0.300.0070.00018.77
8.0.290.0040.00416.75
8.0.280.0030.00318.43
8.0.270.0070.00017.27
8.0.260.0000.00618.45
8.0.250.0060.00316.93
8.0.240.0040.00417.02
8.0.230.0080.00016.98
8.0.220.0060.00316.84
8.0.210.0040.00416.96
8.0.200.0030.00317.02
8.0.190.0070.00017.03
8.0.180.0040.00416.99
8.0.170.0040.00416.89
8.0.160.0040.00417.03
8.0.150.0050.00316.92
8.0.140.0090.00016.95
8.0.130.0000.00613.43
8.0.120.0030.00516.91
8.0.110.0070.00016.95
8.0.100.0070.00016.95
8.0.90.0040.00416.91
8.0.80.0090.00616.84
8.0.70.0030.00617.02
8.0.60.0000.00816.74
8.0.50.0000.00716.96
8.0.30.0120.00417.37
8.0.20.0100.00817.40
8.0.10.0070.00016.88
8.0.00.0090.00816.86
7.4.330.0030.00316.84
7.4.320.0040.00416.66
7.4.300.0000.00616.56
7.4.290.0080.00016.56
7.4.280.0040.00416.50
7.4.270.0070.00016.54
7.4.260.0000.00716.50
7.4.250.0000.00816.39
7.4.240.0040.00416.48
7.4.230.0030.00316.40
7.4.220.0100.00916.61
7.4.210.0070.00916.64
7.4.200.0070.00016.63
7.4.160.0080.00816.42
7.4.150.0130.00517.40
7.4.140.0070.01217.86
7.4.130.0070.01116.61
7.4.120.0050.01216.46
7.4.110.0060.01016.45
7.4.100.0110.01416.61
7.4.90.0130.00316.53
7.4.80.0090.01519.39
7.4.70.0110.00516.73
7.4.60.0070.01116.65
7.4.50.0090.00616.53
7.4.40.0100.01016.75
7.4.30.0100.00616.50
7.4.00.0120.00314.92
7.3.330.0030.00313.43
7.3.320.0060.00013.22
7.3.310.0030.00316.46
7.3.300.0040.00416.21
7.3.290.0040.00416.33
7.3.280.0090.00616.36
7.3.270.0140.00817.40
7.3.260.0100.00716.69
7.3.240.0100.00716.49
7.3.230.0110.00716.53
7.3.210.0060.01016.45
7.3.200.0090.01216.38
7.3.190.0080.00616.34
7.3.180.0090.00916.27
7.3.170.0100.00616.43
7.3.160.0080.00816.47
7.2.330.0150.00316.78
7.2.320.0030.01416.86
7.2.310.0100.01316.70
7.2.300.0090.00916.30
7.2.290.0060.01116.62
7.2.110.0120.00816.52
7.2.60.0130.00016.73
7.2.00.0030.00619.57
7.1.200.0060.00315.62
7.1.100.0000.01718.15
7.1.70.0070.00317.07
7.1.60.0070.01719.27
7.1.50.0100.01316.82
7.1.00.0070.07322.48
7.0.200.0220.00615.07
7.0.60.0130.04021.71
7.0.50.0100.06317.88
7.0.40.0170.08020.02
7.0.30.0130.04720.06
7.0.20.0130.04320.22
7.0.10.0100.08320.12
7.0.00.0070.05020.15
5.6.280.0070.05721.11
5.6.210.0100.08320.48
5.6.200.0100.07718.29
5.6.190.0100.05720.61
5.6.180.0300.05320.54
5.6.170.0130.04720.50
5.6.160.0100.06320.71
5.6.150.0100.04718.27
5.6.140.0070.07018.28
5.6.130.0070.07018.28
5.6.120.0070.06721.04
5.6.110.0200.06321.03
5.6.100.0230.06721.09
5.6.90.0100.05320.95
5.6.80.0000.07720.54
5.5.350.0300.03720.39
5.5.340.0100.06318.02
5.5.330.0100.05320.42
5.5.320.0200.04320.25
5.5.310.0270.06020.26
5.5.300.0030.04717.95
5.5.290.0200.07018.05
5.5.280.0000.04320.73
5.5.270.0000.05320.89
5.5.260.0070.04720.77
5.5.250.0100.08320.66
5.5.240.0100.04720.15

preferences:
49.82 ms | 401 KiB | 5 Q