3v4l.org

run code in 300+ PHP versions simultaneously
<?php interface Test { public function selfRef(Test $other); } class TestImpl implements Test { public function selfRef(Test $other) { echo var_export($other, true) . PHP_EOL; } public function nonContractSelfRef(self $other) { echo var_export($other, true) . PHP_EOL; } } $a = new TestImpl(); $b = new TestImpl(); $a->nonContractSelfRef($b);

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.0160.00316.63
8.3.50.0120.00721.28
8.3.40.0070.00718.70
8.3.30.0070.00719.04
8.3.20.0030.00620.29
8.3.10.0000.00723.67
8.3.00.0090.00019.13
8.2.180.0110.00416.63
8.2.170.0090.00622.96
8.2.160.0110.00720.43
8.2.150.0030.00624.18
8.2.140.0050.00324.66
8.2.130.0060.00326.16
8.2.120.0070.00022.14
8.2.110.0040.00422.20
8.2.100.0040.00818.89
8.2.90.0030.00517.62
8.2.80.0090.00017.97
8.2.70.0050.00317.93
8.2.60.0000.00918.04
8.2.50.0060.00318.10
8.2.40.0000.00720.45
8.2.30.0040.00717.94
8.2.20.0050.00217.59
8.2.10.0040.00418.02
8.2.00.0000.00917.61
8.1.280.0070.00725.92
8.1.270.0050.00323.97
8.1.260.0070.00326.35
8.1.250.0020.00528.09
8.1.240.0030.00623.97
8.1.230.0080.00319.05
8.1.220.0000.00817.74
8.1.210.0050.00318.77
8.1.200.0050.00517.35
8.1.190.0030.00617.43
8.1.180.0030.00618.10
8.1.170.0040.00418.59
8.1.160.0040.00422.02
8.1.150.0070.00018.97
8.1.140.0000.00717.32
8.1.130.0000.00717.88
8.1.120.0000.00817.45
8.1.110.0100.00017.37
8.1.100.0000.00717.48
8.1.90.0000.00717.46
8.1.80.0070.00017.46
8.1.70.0030.00517.34
8.1.60.0030.00517.62
8.1.50.0040.00417.46
8.1.40.0040.00417.55
8.1.30.0040.00417.59
8.1.20.0040.00417.56
8.1.10.0050.00317.50
8.1.00.0000.00817.40
8.0.300.0040.00419.79
8.0.290.0040.00416.74
8.0.280.0000.00818.32
8.0.270.0030.00317.30
8.0.260.0030.00317.20
8.0.250.0030.00317.04
8.0.240.0030.00317.02
8.0.230.0040.00417.00
8.0.220.0000.00617.00
8.0.210.0060.00017.00
8.0.200.0070.00016.96
8.0.190.0040.00417.04
8.0.180.0000.00816.93
8.0.170.0080.00016.86
8.0.160.0040.00416.92
8.0.150.0000.00816.95
8.0.140.0070.00016.96
8.0.130.0030.00313.39
8.0.120.0040.00416.82
8.0.110.0000.00716.90
8.0.100.0070.00016.99
8.0.90.0000.01016.97
8.0.80.0090.00616.91
8.0.70.0000.00717.00
8.0.60.0020.00516.76
8.0.50.0040.00417.07
8.0.30.0090.01217.27
8.0.20.0080.01117.40
8.0.10.0030.00617.03
8.0.00.0120.00916.93
7.4.330.0040.00015.00
7.4.320.0000.00616.43
7.4.300.0030.00316.57
7.4.290.0070.00016.64
7.4.280.0040.00416.61
7.4.270.0050.00216.64
7.4.260.0040.00716.54
7.4.250.0040.00716.61
7.4.240.0030.00316.49
7.4.230.0000.00716.60
7.4.220.0130.01316.60
7.4.210.0100.00516.55
7.4.200.0040.00416.50
7.4.160.0120.00316.53
7.4.150.0130.00617.40
7.4.140.0070.01017.86
7.4.130.0080.01116.48
7.4.120.0060.01116.45
7.4.110.0120.00616.55
7.4.100.0060.01216.56
7.4.90.0040.01616.50
7.4.80.0120.00619.39
7.4.70.0100.00616.37
7.4.60.0080.00816.58
7.4.50.0060.00316.39
7.4.40.0120.00916.32
7.4.30.0090.00616.53
7.4.00.0030.01415.05
7.3.330.0030.00313.31
7.3.320.0050.00013.29
7.3.310.0070.00016.18
7.3.300.0070.00016.28
7.3.290.0130.00616.28
7.3.280.0060.01216.31
7.3.270.0060.01317.40
7.3.260.0060.01016.55
7.3.240.0120.00916.33
7.3.230.0130.01016.39
7.3.210.0100.00716.20
7.3.200.0110.00719.39
7.3.190.0140.00716.46
7.3.180.0000.01516.41
7.3.170.0110.01116.37
7.3.160.0170.00016.46
7.3.10.0060.00616.78
7.3.00.0090.00616.45
7.2.330.0110.00616.76
7.2.320.0080.00916.24
7.2.310.0080.00816.43
7.2.300.0070.01016.43
7.2.290.0160.00016.78
7.2.130.0120.00616.64
7.2.120.0030.01216.93
7.2.110.0070.00716.87
7.2.100.0070.00316.68
7.2.90.0070.00716.96
7.2.80.0100.00316.75
7.2.70.0090.00616.49
7.2.60.0090.00617.01
7.2.50.0080.00416.90
7.2.40.0030.00916.79
7.2.30.0080.00316.67
7.2.20.0070.00717.09
7.2.10.0070.00416.69
7.2.00.0080.00418.17
7.1.250.0070.00415.93
7.1.200.0070.00715.88
7.1.100.0200.00316.30
7.1.70.0040.00817.07
7.1.60.0090.01319.32
7.1.50.0180.00916.78
7.1.00.0000.08022.37
7.0.200.0000.00816.72
7.0.140.0000.07721.99
7.0.60.0070.04020.06
7.0.50.0100.06717.87
7.0.40.0100.07720.04
7.0.30.0400.07020.30
7.0.20.0170.04020.24
7.0.10.0070.04720.08
7.0.00.0030.04720.07
5.6.280.0070.07021.05
5.6.210.0200.07320.63
5.6.200.0030.07318.19
5.6.190.0030.04720.57
5.6.180.0300.04320.49
5.6.170.0070.05020.56
5.6.160.0070.04020.50
5.6.150.0100.06318.19
5.6.140.0000.04318.18
5.6.130.0200.06718.15
5.6.120.0070.08021.02
5.6.110.0000.08721.05
5.6.100.0030.08321.12
5.6.90.0170.07720.99
5.6.80.0030.08320.36
5.5.350.0130.07720.34
5.5.340.0030.08717.92
5.5.330.0100.08020.40
5.5.320.0430.07020.27
5.5.310.0100.04720.28
5.5.300.0070.04317.98
5.5.290.0100.07717.94
5.5.280.0100.07020.89
5.5.270.0030.06020.78
5.5.260.0030.05320.65
5.5.250.0100.07720.50
5.5.240.0170.04720.19
5.4.450.0770.06019.17
5.4.440.0630.06319.63
5.4.430.0700.05319.19
5.4.420.0630.00019.51
5.4.410.0630.00019.37
5.4.400.0630.00019.22
5.4.390.0600.00019.03
5.4.380.0670.00019.05
5.4.370.0630.00019.09
5.4.360.0600.00019.08
5.4.350.0630.00019.16
5.4.340.0070.03812.02
5.4.320.0070.03612.50
5.4.310.0050.04012.50
5.4.300.0050.04012.50
5.4.290.0060.03812.50
5.4.280.0100.03412.39
5.4.270.0090.03312.40
5.4.260.0060.03912.39
5.4.250.0080.03512.40
5.4.240.0070.04312.40
5.4.230.0060.04212.39
5.4.220.0090.04812.39
5.4.210.0070.03512.39
5.4.200.0090.04312.39
5.4.190.0070.03512.39
5.4.180.0060.03612.38
5.4.170.0080.03612.40
5.4.160.0070.03712.39
5.4.150.0070.03612.39
5.4.140.0050.03912.07
5.4.130.0090.03312.06
5.4.120.0050.03812.02
5.4.110.0090.03212.02
5.4.100.0060.03812.02
5.4.90.0080.04312.02
5.4.80.0070.05112.02
5.4.70.0090.04712.02
5.4.60.0130.04412.01
5.4.50.0090.03512.01
5.4.40.0040.03612.00
5.4.30.0060.03512.00
5.4.20.0060.03512.00
5.4.10.0050.03612.00
5.4.00.0050.03711.48
5.3.290.0100.03512.80
5.3.280.0080.04812.71
5.3.270.0080.03812.72
5.3.260.0050.03912.72
5.3.250.0070.03512.71
5.3.240.0060.03812.72
5.3.230.0050.03912.71
5.3.220.0090.03912.68
5.3.210.0090.05212.68
5.3.200.0060.04312.68
5.3.190.0080.04112.68
5.3.180.0030.04012.68
5.3.170.0100.03212.67
5.3.160.0080.03612.68
5.3.150.0040.03812.67
5.3.140.0080.03412.66
5.3.130.0070.03712.66
5.3.120.0060.04012.66
5.3.110.0080.03912.66
5.3.100.0060.04312.12
5.3.90.0070.03512.10
5.3.80.0060.03912.10
5.3.70.0080.03612.09
5.3.60.0090.03612.08
5.3.50.0050.04012.04
5.3.40.0070.04212.04
5.3.30.0080.03411.98
5.3.20.0060.04011.77
5.3.10.0120.04611.73
5.3.00.0060.04311.72
5.2.170.0030.0329.23
5.2.160.0040.0309.22
5.2.150.0060.0329.23
5.2.140.0040.0309.23
5.2.130.0040.0299.19
5.2.120.0030.0299.19
5.2.110.0070.0269.20
5.2.100.0070.0259.19
5.2.90.0060.0279.19
5.2.80.0040.0319.18
5.2.70.0030.0349.18
5.2.60.0060.0369.14
5.2.50.0090.0319.11
5.2.40.0060.0309.08
5.2.30.0050.0299.05
5.2.20.0040.0309.05
5.2.10.0030.0308.95
5.2.00.0060.0318.81
5.1.60.0050.0258.09
5.1.50.0050.0248.09
5.1.40.0060.0248.08
5.1.30.0050.0258.42
5.1.20.0030.0288.45
5.1.10.0100.0198.17
5.1.00.0050.0248.17
5.0.50.0070.0186.65
5.0.40.0020.0216.51
5.0.30.0020.0326.33
5.0.20.0040.0186.29
5.0.10.0020.0216.27
5.0.00.0050.0286.26
4.4.90.0020.0164.77
4.4.80.0040.0154.76
4.4.70.0030.0154.76
4.4.60.0010.0174.75
4.4.50.0020.0164.77
4.4.40.0020.0264.71
4.4.30.0020.0164.75
4.4.20.0020.0164.85
4.4.10.0040.0144.85
4.4.00.0020.0284.76
4.3.110.0030.0154.67
4.3.100.0030.0144.67
4.3.90.0030.0144.64
4.3.80.0060.0244.58
4.3.70.0040.0214.63
4.3.60.0030.0194.63
4.3.50.0050.0144.63
4.3.40.0020.0274.54
4.3.30.0030.0163.28
4.3.20.0000.0183.26
4.3.10.0020.0163.22
4.3.00.0030.0207.33

preferences:
51.4 ms | 401 KiB | 5 Q