3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A{ protected $stuff = 10; function test(){ return new class($this){ function __construct(A $s){ $this->s = $s; } function asd(){ return $this->s->stuff; } }; } } $x = new A; $x->test()->asd();

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.68
8.3.50.0170.00821.97
8.3.40.0120.00318.97
8.3.30.0070.00718.71
8.3.20.0070.00020.34
8.3.10.0050.00320.69
8.3.00.0060.00320.77
8.2.180.0100.01016.88
8.2.170.0120.00322.96
8.2.160.0070.01018.88
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0020.00521.17
8.2.120.0050.00226.35
8.2.110.0060.00321.11
8.2.100.0080.00417.90
8.2.90.0000.00919.05
8.2.80.0030.00617.97
8.2.70.0060.00317.63
8.2.60.0040.00417.93
8.2.50.0080.00018.09
8.2.40.0040.00420.62
8.2.30.0020.00519.44
8.2.20.0040.00417.81
8.2.10.0000.00718.09
8.2.00.0070.00018.01
8.1.280.0110.00725.92
8.1.270.0090.00923.96
8.1.260.0040.00428.09
8.1.250.0080.00028.09
8.1.240.0060.00322.49
8.1.230.0070.00417.64
8.1.220.0050.00317.74
8.1.210.0040.00418.77
8.1.200.0030.00617.35
8.1.190.0040.00417.23
8.1.180.0050.00218.10
8.1.170.0060.00318.57
8.1.160.0000.00720.82
8.1.150.0040.00418.89
8.1.140.0040.00419.58
8.1.130.0030.00317.58
8.1.120.0040.00417.43
8.1.110.0070.00017.39
8.1.100.0000.00717.52
8.1.90.0050.00217.46
8.1.80.0000.00817.48
8.1.70.0090.00317.51
8.1.60.0000.00817.60
8.1.50.0030.00617.53
8.1.40.0030.00717.41
8.1.30.0000.00817.60
8.1.20.0050.00217.54
8.1.10.0000.00817.51
8.1.00.0040.00417.40
8.0.300.0040.00418.77
8.0.290.0000.00816.75
8.0.280.0030.00318.39
8.0.270.0030.00317.31
8.0.260.0000.00817.17
8.0.250.0000.00917.02
8.0.240.0000.00717.06
8.0.230.0000.00717.06
8.0.220.0060.00317.00
8.0.210.0000.00716.85
8.0.200.0030.00316.93
8.0.190.0060.00316.98
8.0.180.0070.00016.88
8.0.170.0030.00616.99
8.0.160.0040.00417.00
8.0.150.0050.00216.91
8.0.140.0040.00416.95
8.0.130.0060.00013.35
8.0.120.0040.00416.87
8.0.110.0040.00416.92
8.0.100.0040.00416.99
8.0.90.0080.00016.83
8.0.80.0090.01217.00
8.0.70.0080.00016.74
8.0.60.0040.00416.96
8.0.50.0040.00416.90
8.0.30.0130.00716.98
8.0.20.0080.01117.40
8.0.10.0040.00417.18
8.0.00.0110.01016.87
7.4.330.0020.00216.67
7.4.320.0030.00316.66
7.4.300.0000.00616.52
7.4.290.0000.00716.66
7.4.280.0000.00716.43
7.4.270.0040.00416.61
7.4.260.0060.00316.59
7.4.250.0000.00816.62
7.4.240.0040.00416.62
7.4.230.0030.00316.63
7.4.220.0070.00016.72
7.4.210.0100.00916.47
7.4.200.0030.00316.63
7.4.160.0000.01516.61
7.4.150.0090.00917.40
7.4.140.0070.01017.86
7.4.130.0130.00716.61
7.4.120.0080.00916.61
7.4.110.0080.00816.73
7.4.100.0110.01116.74
7.4.90.0140.00416.61
7.4.80.0100.00919.39
7.4.70.0140.01216.62
7.4.60.0170.00016.55
7.4.50.0000.01816.43
7.4.40.0070.01016.71
7.4.30.0100.00616.52
7.4.00.0000.01214.93
7.3.330.0050.00013.20
7.3.320.0030.00313.32
7.3.310.0050.00316.23
7.3.300.0030.00316.35
7.3.290.0030.00316.38
7.3.280.0110.00816.31
7.3.270.0060.01217.40
7.3.260.0130.00316.49
7.3.240.0120.00616.46
7.3.230.0040.01416.39
7.3.210.0100.00716.42
7.3.200.0100.00716.49
7.3.190.0110.00416.50
7.3.180.0030.01316.70
7.3.170.0030.01916.49
7.3.160.0060.01016.57
7.3.120.0030.01214.79
7.3.110.0000.01314.64
7.3.100.0090.00015.02
7.3.90.0060.00615.00
7.3.80.0100.00714.98
7.3.70.0060.00914.83
7.3.60.0120.00314.65
7.3.50.0000.01414.73
7.3.40.0040.01414.88
7.3.30.0090.00614.77
7.3.20.0030.01416.47
7.3.10.0120.00316.54
7.3.00.0080.00316.68
7.2.330.0150.00316.47
7.2.320.0100.00716.75
7.2.310.0100.00716.44
7.2.300.0100.00716.45
7.2.290.0100.01016.60
7.2.240.0000.01514.83
7.2.230.0070.01015.30
7.2.220.0030.01015.12
7.2.210.0100.00714.93
7.2.200.0000.01415.00
7.2.190.0040.00715.05
7.2.180.0000.01415.16
7.2.170.0030.00914.95
7.2.160.0030.01314.99
7.2.150.0000.01316.77
7.2.140.0000.01516.77
7.2.130.0000.01316.82
7.2.120.0090.00316.84
7.2.110.0070.00716.85
7.2.100.0040.01116.91
7.2.90.0100.00716.89
7.2.80.0030.01216.66
7.2.70.0090.00616.95
7.2.60.0050.00816.76
7.2.50.0070.01017.15
7.2.40.0000.01716.72
7.2.30.0030.00616.96
7.2.20.0120.00316.89
7.2.10.0060.00917.02
7.2.00.0030.00818.29
7.1.330.0080.00816.02
7.1.320.0120.00315.73
7.1.310.0040.00815.72
7.1.300.0130.00315.70
7.1.290.0120.00415.48
7.1.280.0030.01315.71
7.1.270.0040.00715.63
7.1.260.0130.00315.85
7.1.250.0100.00315.73
7.1.200.0150.00315.63
7.1.70.0000.00717.22
7.1.60.0030.00916.91
7.1.50.0040.01417.02
7.1.00.0100.07022.27
7.0.200.0040.01216.80
7.0.60.0030.07321.70
7.0.50.0170.05017.74
7.0.40.0100.07320.41
7.0.30.0230.03320.06
7.0.20.0230.03320.12
7.0.10.0030.08020.10
7.0.00.0070.06020.30
5.6.210.0070.04020.55
5.6.200.0070.04318.15
5.6.190.0100.07720.42
5.6.180.0270.06720.34
5.6.170.0170.04320.40
5.6.160.0100.03720.50
5.6.150.0000.05018.19
5.6.140.0000.09018.29
5.6.130.0070.04018.15
5.6.120.0030.05720.99
5.6.110.0070.08020.98
5.6.100.0000.05721.01
5.6.90.0070.04720.97
5.6.80.0130.07320.44
5.5.350.0270.06320.42
5.5.340.0130.07017.98
5.5.330.0000.04720.35
5.5.320.0230.05320.38
5.5.310.0300.07320.35
5.5.300.0130.07717.99
5.5.290.0100.06718.02
5.5.280.0130.07720.89
5.5.270.0070.08320.68
5.5.260.0130.07020.87
5.5.250.0030.04020.61
5.5.240.0070.07020.29

preferences:
32.79 ms | 401 KiB | 5 Q