3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { public int $bar; public function __construct() { unset($this->bar); } public function __get($name) { //return 'string'; // Can no longer do this return 999; // Type has to match } } $foo = new Foo(); var_dump($foo->bar);

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.5.30.0100.00817.39
8.5.20.0090.00920.08
8.5.10.0080.00819.99
8.5.00.0130.00819.94
8.4.180.0040.00623.93
8.4.170.0130.00923.72
8.4.160.0130.00823.81
8.4.150.0080.00517.73
8.4.140.0120.00917.25
8.4.130.0060.00617.57
8.4.120.0100.00922.36
8.4.110.0080.01122.32
8.4.100.0110.01017.55
8.4.90.0090.00720.71
8.4.80.0030.00618.95
8.4.70.0090.01218.72
8.4.60.0110.00819.05
8.4.50.0050.00518.76
8.4.40.0160.00320.45
8.4.30.0070.01317.30
8.4.20.0040.01517.61
8.4.10.0100.01017.48
8.3.300.0130.00622.71
8.3.290.0140.00618.16
8.3.280.0150.00518.23
8.3.270.0130.00816.45
8.3.260.0130.00716.34
8.3.250.0110.00818.89
8.3.240.0120.00716.41
8.3.230.0040.00716.44
8.3.220.0100.00718.95
8.3.210.0120.00716.54
8.3.200.0070.00216.60
8.3.190.0030.00416.89
8.3.180.0030.00616.48
8.3.170.0090.00920.84
8.3.160.0060.01017.16
8.3.150.0090.00916.85
8.3.140.0120.00616.69
8.3.130.0040.00416.59
8.3.120.0080.01220.64
8.3.110.0040.01516.60
8.3.100.0060.00318.30
8.3.90.0070.00316.56
8.3.80.0030.00617.97
8.3.70.0150.00318.30
8.3.60.0140.00318.18
8.3.50.0170.00521.08
8.3.40.0110.00318.65
8.3.30.0110.00318.54
8.3.20.0060.00320.35
8.3.10.0000.00721.74
8.3.00.0000.00720.71
8.2.300.0120.00817.92
8.2.290.0120.00716.56
8.2.280.0090.00218.41
8.2.270.0090.00918.91
8.2.260.0000.00716.43
8.2.250.0040.01518.64
8.2.240.0030.00617.12
8.2.230.0070.00720.94
8.2.220.0090.00624.06
8.2.210.0070.00726.77
8.2.200.0040.00716.75
8.2.190.0140.00716.63
8.2.180.0080.00818.04
8.2.170.0090.00622.96
8.2.160.0030.01020.39
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0100.00019.41
8.2.110.0060.00619.39
8.2.100.0120.00017.91
8.2.90.0040.00419.27
8.2.80.0050.00317.97
8.2.70.0030.00517.49
8.2.60.0040.00417.91
8.2.50.0060.00318.10
8.2.40.0040.00420.56
8.2.30.0040.00420.69
8.2.20.0000.00817.69
8.2.10.0030.00518.00
8.2.00.0030.00617.97
8.1.340.0110.01017.71
8.1.330.0080.01116.19
8.1.320.0130.00715.96
8.1.310.0040.00416.81
8.1.300.0090.00018.45
8.1.290.0050.00518.88
8.1.280.0070.00725.92
8.1.270.0040.00423.72
8.1.260.0030.00626.35
8.1.250.0050.00328.09
8.1.240.0050.00322.81
8.1.230.0000.01217.52
8.1.220.0050.00317.74
8.1.210.0050.00318.77
8.1.200.0060.00317.35
8.1.190.0000.00817.35
8.1.180.0060.00318.10
8.1.170.0080.00018.47
8.1.160.0040.00420.82
8.1.150.0070.00018.77
8.1.140.0050.00219.52
8.1.130.0070.00017.52
8.1.120.0040.00417.36
8.1.110.0000.00717.36
8.1.100.0000.00817.37
8.1.90.0090.00017.38
8.1.80.0080.00017.33
8.1.70.0030.00317.34
8.1.60.0040.00417.47
8.1.50.0040.00417.44
8.1.40.0040.00817.54
8.1.30.0000.00917.57
8.1.20.0000.00717.50
8.1.10.0000.00717.35
8.1.00.0000.00817.42
8.0.300.0050.00218.77
8.0.290.0070.00016.63
8.0.280.0000.00718.27
8.0.270.0000.00717.24
8.0.260.0060.00017.13
8.0.250.0000.00716.79
8.0.240.0040.00416.77
8.0.230.0020.00516.90
8.0.220.0030.00316.87
8.0.210.0030.00316.73
8.0.200.0000.00616.87
8.0.190.0000.00716.88
8.0.180.0070.00016.91
8.0.170.0040.00416.90
8.0.160.0030.00516.86
8.0.150.0040.00416.78
8.0.140.0040.00416.68
8.0.130.0050.00013.26
8.0.120.0000.00716.81
8.0.110.0000.00716.77
8.0.100.0040.00416.86
8.0.90.0040.00416.85
8.0.80.0030.01316.71
8.0.70.0000.00816.78
8.0.60.0080.00016.88
8.0.50.0040.00416.89
8.0.30.0110.00717.05
8.0.20.0140.01017.40
8.0.10.0040.00416.90
8.0.00.0100.00916.73
7.4.330.0020.00215.08
7.4.320.0000.00716.41
7.4.300.0000.00816.48
7.4.290.0000.00716.53
7.4.280.0000.00816.42
7.4.270.0000.00716.52
7.4.260.0040.00416.40
7.4.250.0080.00016.46
7.4.240.0050.00316.52
7.4.230.0040.00416.35
7.4.220.0000.01516.59
7.4.210.0090.00616.61
7.4.200.0030.00316.42
7.4.160.0150.00016.40
7.4.150.0120.00617.40
7.4.140.0120.00517.86
7.4.130.0150.00516.38
7.4.120.0120.00716.41
7.4.110.0060.01316.40
7.4.100.0140.00716.38
7.4.90.0100.00716.39
7.4.80.0090.00619.39
7.4.70.0030.01316.43
7.4.60.0110.00616.50
7.4.50.0070.00716.59
7.4.40.0130.00716.59
7.4.30.0110.00816.57
7.3.330.0020.00213.00
7.3.320.0050.00013.21
7.3.310.0070.00016.10
7.3.300.0000.00616.16
7.3.290.0090.00716.15
7.3.280.0080.01016.16
7.3.270.0040.01417.40
7.3.260.0090.01216.21
7.3.250.0090.00816.35
7.3.240.0140.00616.27
7.3.230.0140.00316.39
7.3.210.0090.00616.06
7.3.200.0100.00716.49
7.3.190.0100.01016.42
7.3.180.0030.01216.11
7.3.170.0100.00716.25
7.3.160.0060.01016.13
7.2.330.0070.01016.24
7.2.320.0150.00416.48
7.2.310.0070.01416.26
7.2.300.0040.01216.22
7.2.290.0080.00816.45
7.0.40.0270.06120.12
7.0.30.0210.06320.27
7.0.20.0320.06720.17
7.0.10.0300.06620.19
7.0.00.0210.06120.15
5.6.190.0230.06220.52
5.6.180.0140.06920.58
5.6.170.0310.05620.55
5.6.160.0130.06320.54
5.6.150.0220.06020.39
5.6.140.0200.06120.29
5.6.130.0170.05920.32
5.6.120.0170.05820.40
5.6.110.0170.05420.38
5.6.100.0140.05820.38
5.6.90.0120.06420.34
5.6.80.0210.05819.74
5.6.70.0260.06219.82
5.6.60.0180.05919.79
5.6.50.0260.05419.75
5.6.40.0290.05819.71
5.6.30.0290.06219.63
5.6.20.0210.06019.72
5.6.10.0210.06119.81
5.6.00.0290.05119.70
5.5.330.0170.06320.34
5.5.320.0190.06220.39
5.5.310.0270.05820.30
5.5.300.0160.06120.27
5.5.290.0160.06120.15
5.5.280.0060.07220.13
5.5.270.0140.05920.18
5.5.260.0170.06820.18
5.5.250.0200.06119.96
5.5.240.0210.05919.59
5.5.230.0240.05719.64
5.5.220.0290.06719.49
5.5.210.0240.05119.58
5.5.200.0320.06019.42
5.5.190.0310.05719.51
5.5.180.0240.05219.52
5.5.160.0330.05919.50
5.5.150.0210.05819.54
5.5.140.0280.05419.53
5.5.130.0410.05319.55
5.5.120.0330.04819.43
5.5.110.0200.05419.57
5.5.100.0240.06419.48
5.5.90.0160.06019.37
5.5.80.0230.05819.40
5.5.70.0220.06119.46
5.5.60.0180.06019.42
5.5.50.0240.05419.40
5.5.40.0240.05219.41
5.5.30.0310.05419.41
5.5.20.0220.05719.42
5.5.10.0400.06119.48
5.5.00.0390.05219.41

preferences:
49.6 ms | 1554 KiB | 5 Q