3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Hello{ private $say; public function say(Hello $obj = null, $val = null) { if (null === $obj) { return $this->say; } $hello->say = $val; } } $test1 = new Hello; $test2 = new Hello; $test1->say($test2, 'Hello'); $test2->say();

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.01417.00
8.3.50.0160.00521.95
8.3.40.0070.00718.84
8.3.30.0030.01018.96
8.3.20.0040.00420.33
8.3.10.0040.00423.61
8.3.00.0040.00422.58
8.2.180.0110.01118.29
8.2.170.0120.00922.96
8.2.160.0100.00320.33
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0140.00326.16
8.2.120.0040.00422.16
8.2.110.0030.00621.03
8.2.100.0060.00617.84
8.2.90.0040.00418.96
8.2.80.0000.00817.97
8.2.70.0030.00817.63
8.2.60.0000.00817.91
8.2.50.0000.00918.07
8.2.40.0030.00518.16
8.2.30.0000.00718.06
8.2.20.0030.00617.52
8.2.10.0030.00619.47
8.2.00.0040.00417.71
8.1.280.0100.01025.92
8.1.270.0080.00023.93
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0000.01822.48
8.1.230.0000.01320.85
8.1.220.0080.00017.74
8.1.210.0000.00818.77
8.1.200.0090.00017.35
8.1.190.0030.00617.40
8.1.180.0090.00018.10
8.1.170.0040.00418.72
8.1.160.0000.00721.88
8.1.150.0050.00218.53
8.1.140.0040.00417.37
8.1.130.0030.00317.74
8.1.120.0080.00017.36
8.1.110.0060.00317.41
8.1.100.0040.00417.29
8.1.90.0000.00717.23
8.1.80.0000.00717.28
8.1.70.0000.00717.37
8.1.60.0000.00817.55
8.1.50.0040.00417.53
8.1.40.0040.00417.47
8.1.30.0000.00817.50
8.1.20.0060.00317.60
8.1.10.0040.00417.64
8.1.00.0060.00317.49
8.0.300.0040.00418.77
8.0.290.0070.00017.05
8.0.280.0000.00718.35
8.0.270.0000.00717.13
8.0.260.0000.00716.74
8.0.250.0000.00616.86
8.0.240.0040.00416.86
8.0.230.0000.00816.96
8.0.220.0030.00316.90
8.0.210.0000.00816.89
8.0.200.0000.00617.03
8.0.190.0040.00417.00
8.0.180.0050.00316.92
8.0.170.0030.00316.94
8.0.160.0040.00416.84
8.0.150.0070.00016.77
8.0.140.0070.00016.88
8.0.130.0000.00713.34
8.0.120.0000.00816.91
8.0.110.0040.00416.96
8.0.100.0040.00416.94
8.0.90.0020.00516.74
8.0.80.0030.01316.88
8.0.70.0000.00716.83
8.0.60.0050.00216.86
8.0.50.0040.00416.72
8.0.30.0140.00516.84
8.0.20.0110.00917.40
8.0.10.0000.00716.89
8.0.00.0120.00816.95
7.4.330.0000.00515.14
7.4.320.0000.00616.50
7.4.300.0040.00416.50
7.4.290.0030.00316.50
7.4.280.0000.00816.60
7.4.270.0030.00316.59
7.4.260.0050.00216.58
7.4.250.0030.00716.48
7.4.240.0040.00416.56
7.4.230.0050.00216.34
7.4.220.0030.01416.54
7.4.210.0090.00616.65
7.4.200.0030.00316.54
7.4.190.0070.00016.77
7.4.160.0100.00616.79
7.4.150.0100.00717.40
7.4.140.0050.01317.86
7.4.130.0060.01316.53
7.4.120.0020.01616.64
7.4.110.0070.01216.54
7.4.100.0160.00616.54
7.4.90.0100.00716.45
7.4.80.0150.00719.39
7.4.70.0160.00016.43
7.4.60.0070.01016.39
7.4.50.0030.00616.55
7.4.40.0060.00922.77
7.4.30.0070.01016.46
7.4.00.0070.00714.61
7.3.330.0050.00013.18
7.3.320.0000.00613.21
7.3.310.0000.00716.18
7.3.300.0000.00716.31
7.3.290.0080.00816.34
7.3.280.0100.01116.34
7.3.270.0180.00017.40
7.3.260.0070.01016.44
7.3.250.0090.01116.50
7.3.240.0120.00616.55
7.3.230.0150.00916.39
7.3.210.0090.00916.43
7.3.200.0130.00319.39
7.3.190.0150.00916.62
7.3.180.0060.01016.41
7.3.170.0080.00816.41
7.3.160.0100.00616.54
7.3.120.0100.00614.64
7.2.330.0190.00316.39
7.2.320.0130.00616.79
7.2.310.0100.00716.59
7.2.300.0130.00316.43
7.2.290.0140.00416.45
7.2.00.0070.00719.38
7.1.200.0000.01315.71
7.1.100.0030.01018.05
7.1.70.0000.00716.93
7.1.60.0120.01219.29
7.1.50.0220.01634.79
7.1.00.0130.06722.45
7.0.200.0030.00716.60
7.0.140.0000.07321.99
7.0.60.0100.07019.96
7.0.50.0070.04017.95
7.0.40.0100.04320.02
7.0.30.0200.04320.28
7.0.20.0300.07020.09
7.0.10.0070.08720.12
7.0.00.0030.09320.32
5.6.280.0030.07320.78
5.6.210.0100.08020.48
5.6.200.0070.03718.16
5.6.190.0100.08020.47
5.6.180.0270.07020.62
5.6.170.0200.04020.58
5.6.160.0070.06020.45
5.6.150.0130.07718.18
5.6.140.0100.07018.26
5.6.130.0100.04018.26
5.6.120.0070.08321.02
5.6.110.0130.03721.01
5.6.100.0130.08021.04
5.6.90.0130.07721.02
5.6.80.0300.04020.36
5.6.70.4430.03720.51
5.5.350.0070.08320.45
5.5.340.0000.05017.96
5.5.330.0000.04320.19
5.5.320.0000.05020.51
5.5.310.0130.04020.30
5.5.300.0170.07017.98
5.5.290.0070.06718.04
5.5.280.0030.06720.93
5.5.270.0070.03720.76
5.5.260.0070.06720.76
5.5.250.0030.07720.61
5.5.240.0300.07320.27
5.4.450.0770.05319.34
5.4.440.0730.06019.49
5.4.430.0770.04019.33
5.4.420.0600.05319.69
5.4.410.0770.08319.34
5.4.400.0630.05319.26
5.4.390.1200.05719.28
5.4.380.0230.05318.61
5.4.370.0230.04318.78
5.4.360.0200.04718.56
5.4.350.0130.05718.50
5.4.340.0170.05718.56
5.4.320.0080.03612.50
5.4.310.0040.04612.50
5.4.300.0050.03812.50
5.4.290.0040.04012.50
5.4.280.0020.03912.39
5.4.270.0090.03912.39
5.4.260.0080.04612.39
5.4.250.0050.03812.39
5.4.240.0090.03212.39
5.4.230.0070.04512.39
5.4.220.0060.03712.38
5.4.210.0230.04412.37
5.4.200.0130.05212.38
5.4.190.0180.04612.36
5.4.180.0180.04812.37
5.4.170.0440.08012.38
5.4.160.0210.04212.38
5.4.150.0150.04412.36
5.4.140.0190.04312.05
5.4.130.0260.06612.04
5.4.120.0140.04711.99
5.4.110.0170.04111.99
5.4.100.0120.04912.00
5.4.90.0160.04612.00
5.4.80.0210.03712.00
5.4.70.0200.03711.99
5.4.60.0160.04511.99
5.4.50.0360.08911.98
5.4.40.0190.04011.97
5.4.30.0140.04611.98
5.4.20.0140.04211.98
5.4.10.0190.03811.97
5.4.00.0300.08811.46
5.3.290.0060.03912.80
5.3.280.0040.03912.71
5.3.270.0140.05212.72
5.3.260.0150.04612.71
5.3.250.0160.04312.72
5.3.240.0140.04512.71
5.3.230.0270.09512.71
5.3.220.0170.04812.68
5.3.210.0150.04912.68
5.3.200.0200.03912.68
5.3.190.0200.04312.68
5.3.180.0130.04912.68
5.3.170.0190.04412.67
5.3.160.0170.04512.67
5.3.150.0290.06512.67
5.3.140.0190.04612.66
5.3.130.0120.04912.66
5.3.120.0130.05112.66
5.3.110.0360.09012.66
5.3.100.0150.05112.12
5.3.90.0330.06312.09
5.3.80.0140.04712.07
5.3.70.0370.08412.08
5.3.60.0180.04312.07
5.3.50.0110.05012.00
5.3.40.0120.04912.00
5.3.30.0180.04211.97
5.3.20.0220.04011.75
5.3.10.0300.06011.72
5.3.00.0120.04611.70
5.2.170.0150.0419.20
5.2.160.0240.0859.20
5.2.150.0150.0349.20
5.2.140.0150.0349.20
5.2.130.0110.0419.16
5.2.120.0120.0379.16
5.2.110.0140.0389.17
5.2.100.0170.0329.16
5.2.90.0360.0729.16
5.2.80.0170.0329.14
5.2.70.0140.0339.15
5.2.60.0110.0349.11
5.2.50.0100.0369.08
5.2.40.0380.0699.06
5.2.30.0140.0319.02
5.2.20.0120.0359.03
5.2.10.0200.0288.93
5.2.00.0120.0328.77
5.1.60.0110.0288.07
5.1.50.0100.0308.07
5.1.40.0110.0308.04
5.1.30.0130.0298.40
5.1.20.0140.0298.42
5.1.10.0080.0348.15
5.1.00.0120.0318.14
5.0.50.0100.0256.62
5.0.40.0090.0246.48
5.0.30.0090.0376.29
5.0.20.0120.0216.27
5.0.10.0070.0246.25
5.0.00.0110.0336.24
4.4.90.0060.0184.78
4.4.80.0070.0174.76
4.4.70.0080.0174.75
4.4.60.0070.0184.75
4.4.50.0070.0184.77
4.4.40.0020.0334.71
4.4.30.0060.0204.76
4.4.20.0080.0184.84
4.4.10.0060.0194.85
4.4.00.0100.0254.76
4.3.110.0070.0184.67
4.3.100.0070.0184.66
4.3.90.0070.0194.63
4.3.80.0080.0264.59
4.3.70.0050.0194.63
4.3.60.0060.0194.63
4.3.50.0070.0184.63
4.3.40.0060.0274.54
4.3.30.0040.0203.30
4.3.20.0030.0223.28
4.3.10.0050.0183.24
4.3.00.0000.0236.76

preferences:
42.78 ms | 401 KiB | 5 Q