3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { protected $bar = 10; public function foo(A $other) { $other->bar = 10; } public function getBar() { return $this->bar; } } class B extends A { public function frobnicate(A $other) { $other->bar = 10; } } $a = new A(); $b = new B(); $b->frobnicate($a); print $a->getBar();

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.0000.01516.75
8.3.50.0110.00722.06
8.3.40.0110.00418.89
8.3.30.0120.00919.02
8.3.20.0030.00520.38
8.3.10.0000.00721.81
8.3.00.0040.00419.25
8.2.180.0110.00418.54
8.2.170.0070.01322.96
8.2.160.0100.00320.39
8.2.150.0080.00024.18
8.2.140.0050.00324.66
8.2.130.0080.00026.16
8.2.120.0080.00019.36
8.2.110.0050.00519.28
8.2.100.0060.00617.63
8.2.90.0050.00219.05
8.2.80.0000.00817.97
8.2.70.0060.00317.50
8.2.60.0040.00417.80
8.2.50.0040.00418.07
8.2.40.0050.00318.22
8.2.30.0030.00618.04
8.2.20.0000.00817.56
8.2.10.0050.00217.92
8.2.00.0040.00417.50
8.1.280.0000.01425.92
8.1.270.0030.00620.50
8.1.260.0050.00326.35
8.1.250.0040.00428.09
8.1.240.0060.00323.96
8.1.230.0080.00417.42
8.1.220.0000.00817.79
8.1.210.0040.00418.77
8.1.200.0090.00017.23
8.1.190.0030.00617.23
8.1.180.0030.00618.10
8.1.170.0050.00318.56
8.1.160.0040.00421.95
8.1.150.0040.00418.82
8.1.140.0070.00017.42
8.1.130.0000.00917.41
8.1.120.0070.00017.44
8.1.110.0030.00317.44
8.1.100.0050.00317.39
8.1.90.0000.00717.30
8.1.80.0000.00917.36
8.1.70.0030.00317.36
8.1.60.0070.00317.57
8.1.50.0040.00417.43
8.1.40.0040.00717.55
8.1.30.0000.00817.48
8.1.20.0050.00217.63
8.1.10.0030.00617.54
8.1.00.0110.00017.58
8.0.300.0000.00718.77
8.0.290.0070.00016.75
8.0.280.0040.00418.45
8.0.270.0030.00317.34
8.0.260.0030.00316.89
8.0.250.0050.00217.00
8.0.240.0040.00416.89
8.0.230.0000.00816.83
8.0.220.0070.00016.81
8.0.210.0000.00716.81
8.0.200.0030.00316.94
8.0.190.0080.00016.86
8.0.180.0050.00216.81
8.0.170.0000.00816.76
8.0.160.0000.00716.89
8.0.150.0040.00416.84
8.0.140.0030.00516.76
8.0.130.0070.00013.28
8.0.120.0000.00716.86
8.0.110.0070.00016.76
8.0.100.0060.00316.76
8.0.90.0080.00016.83
8.0.80.0090.00716.92
8.0.70.0080.00016.95
8.0.60.0040.00416.89
8.0.50.0000.00716.67
8.0.30.0070.01017.09
8.0.20.0160.00617.41
8.0.10.0040.00416.90
8.0.00.0090.01216.86
7.4.330.0020.00215.04
7.4.320.0030.00316.54
7.4.300.0030.00316.60
7.4.290.0000.00916.54
7.4.280.0030.00616.49
7.4.270.0000.00716.65
7.4.260.0000.00716.54
7.4.250.0070.00016.61
7.4.240.0020.00516.50
7.4.230.0000.00716.49
7.4.220.0140.00316.64
7.4.210.0120.00816.53
7.4.200.0080.00016.51
7.4.160.0090.00616.64
7.4.150.0140.00317.40
7.4.140.0060.01617.86
7.4.130.0110.00716.43
7.4.120.0130.00316.34
7.4.110.0070.01016.66
7.4.100.0100.00616.58
7.4.90.0140.00616.41
7.4.80.0060.01219.39
7.4.70.0000.01716.40
7.4.60.0030.01416.35
7.4.50.0000.00816.51
7.4.40.0110.00916.72
7.4.30.0110.01116.68
7.4.00.0030.01214.74
7.3.330.0060.00013.29
7.3.320.0130.00013.28
7.3.310.0070.00016.41
7.3.300.0030.00316.18
7.3.290.0000.00616.25
7.3.280.0080.00816.30
7.3.270.0110.00717.40
7.3.260.0190.00316.23
7.3.250.0090.01316.41
7.3.240.0090.00716.29
7.3.230.0100.00716.47
7.3.210.0130.00316.45
7.3.200.0020.01919.39
7.3.190.0130.00416.61
7.3.180.0100.00616.64
7.3.170.0120.00616.48
7.3.160.0070.01016.52
7.2.330.0100.01016.84
7.2.320.0070.01016.70
7.2.310.0090.01216.79
7.2.300.0080.00816.73
7.2.290.0070.01616.71
7.2.60.0060.01016.63
7.2.00.0040.01119.54
7.1.200.0090.00415.67
7.1.100.0060.01018.18
7.1.70.0030.00617.26
7.1.60.0100.01419.50
7.1.50.0120.00316.92
7.1.00.0030.07722.27
7.0.200.0250.00416.58
7.0.140.0000.07022.21
7.0.60.0100.04720.01
7.0.50.0030.06317.96
7.0.40.0070.04020.39
7.0.30.0370.07020.16
7.0.20.0270.04020.07
7.0.10.0270.08320.30
7.0.00.0000.09020.07
5.6.280.0030.07320.87
5.6.210.0130.07320.77
5.6.200.0070.04018.23
5.6.190.0030.05320.51
5.6.180.0130.05020.56
5.6.170.0270.06020.51
5.6.160.0030.07320.54
5.6.150.0070.06318.24
5.6.140.0000.04318.12
5.6.130.0070.04018.21
5.6.120.0030.09021.01
5.6.110.0070.09721.12
5.6.100.0100.08020.98
5.6.90.0130.05721.02
5.6.80.0030.03720.38
5.6.70.0200.06320.52
5.5.350.0200.07720.36
5.5.340.0130.07317.95
5.5.330.0070.07020.21
5.5.320.0030.04320.14
5.5.310.0230.04020.29
5.5.300.0130.08018.01
5.5.290.0070.08317.96
5.5.280.0130.07020.91
5.5.270.0070.04020.88
5.5.260.0170.06020.88
5.5.250.0170.06320.62
5.5.240.0070.08320.37
5.4.450.0800.06719.55
5.4.440.0830.06019.47
5.4.430.0870.06019.38
5.4.420.1030.05019.58
5.4.410.0870.05719.25
5.4.400.0300.04018.89
5.4.390.0330.04718.79
5.4.380.0200.05718.61
5.4.370.0170.06018.57
5.4.360.0100.06018.75
5.4.350.0270.07318.74
5.4.340.0230.05318.80
5.4.320.0230.06318.79
5.4.310.0270.05318.75
5.4.300.0200.05318.63
5.4.290.0400.06018.84
5.4.280.0100.06018.79
5.4.270.0230.06018.47
5.4.260.0300.05718.77
5.4.250.0330.06318.60
5.4.240.0330.04718.53
5.4.230.0300.05718.57
5.4.220.0270.05718.55
5.4.210.0200.05718.81
5.4.200.0300.05016.80
5.4.190.0270.06018.77
5.4.180.0300.07018.75
5.4.170.0330.06318.57
5.4.160.0230.05718.54
5.4.150.0270.05018.57
5.4.140.0170.06316.22
5.4.130.0270.05316.22
5.4.120.0270.06716.25
5.4.110.0270.04716.18
5.4.100.0200.05316.23
5.4.90.0030.07316.28
5.4.80.0200.06316.20
5.4.70.0200.06016.22
5.4.60.0170.06316.20
5.4.50.0170.07316.27
5.4.40.0270.04716.39
5.4.30.0370.04016.38
5.4.20.0230.05716.29
5.4.10.0270.06016.18
5.4.00.0230.05715.71
5.3.290.0370.04714.68
5.3.280.0500.05314.62
5.3.270.0400.05714.78
5.3.260.0300.06314.66
5.3.250.0300.06014.71
5.3.240.0300.06014.81
5.3.230.0330.05714.78
5.3.220.0470.05314.55
5.3.210.0300.05714.56
5.3.200.0300.05314.62
5.3.190.0300.08014.77
5.3.180.0430.04714.78
5.3.170.0470.05014.75
5.3.160.0500.04714.71
5.3.150.0230.06714.58
5.3.140.0300.05714.68
5.3.130.0400.05314.58
5.3.120.0270.05714.71
5.3.110.0430.04714.68
5.3.100.0400.05014.04
5.3.90.0230.05014.01
5.3.80.0300.05014.09
5.3.70.0230.06014.01
5.3.60.0270.05314.17
5.3.50.0170.07313.98
5.3.40.0170.07014.01
5.3.30.0230.06714.12
5.3.20.0200.07013.76
5.3.10.0330.05013.68
5.3.00.0270.05013.81
5.2.170.0200.04711.29
5.2.160.0200.04311.20
5.2.150.0200.05011.26
5.2.140.0200.04711.25
5.2.130.0200.04011.18
5.2.120.0200.05711.11
5.2.110.0070.06011.23
5.2.100.0200.05311.09
5.2.90.0170.06311.21
5.2.80.0170.06011.12
5.2.70.0200.06011.13
5.2.60.0170.06011.11
5.2.50.0300.03311.01
5.2.40.0200.04310.94
5.2.30.0170.04711.03
5.2.20.0200.04710.95
5.2.10.0130.04710.91
5.2.00.0200.03710.79
5.1.60.0130.04010.18
5.1.50.0170.04010.10
5.1.40.0170.04010.02
5.1.30.0170.04310.57
5.1.20.0230.04710.49
5.1.10.0130.05010.20
5.1.00.0170.05010.25
5.0.50.0170.0238.54
5.0.40.0070.0308.43
5.0.30.0100.0478.22
5.0.20.0030.0338.28
5.0.10.0170.0238.28
5.0.00.0170.0478.27
4.4.90.0100.0237.25
4.4.80.0100.0207.25
4.4.70.0100.0237.25
4.4.60.0100.0207.25
4.4.50.0100.0277.25
4.4.40.0430.0407.25
4.4.30.0100.0277.25
4.4.20.0070.0277.26
4.4.10.0470.0207.26
4.4.00.0100.0437.26
4.3.110.0100.0277.26
4.3.100.0100.0237.26
4.3.90.0100.0207.26
4.3.80.0130.0337.26
4.3.70.0100.0207.26
4.3.60.0070.0307.26
4.3.50.0070.0307.26
4.3.40.0030.0407.26
4.3.30.0100.0277.26
4.3.20.0030.0277.26
4.3.10.0100.0237.26
4.3.00.0100.0207.00

preferences:
40.6 ms | 401 KiB | 5 Q