3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { static $x = 1; public function method(){ static::$x += 1; return static::$x; } } class B extends A { public function method(){ parent::method(); return static::$x; } } $b = new B; echo $b->method();

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.0090.00618.56
8.3.50.0130.00721.18
8.3.40.0110.00418.80
8.3.30.0070.00719.27
8.3.20.0040.00420.34
8.3.10.0030.00620.44
8.3.00.0050.00319.38
8.2.180.0110.00416.36
8.2.170.0030.01422.96
8.2.160.0110.00320.35
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0070.00026.16
8.2.120.0080.00022.23
8.2.110.0000.01121.12
8.2.100.0070.00418.34
8.2.90.0000.00819.17
8.2.80.0040.00417.97
8.2.70.0090.00017.63
8.2.60.0040.00417.91
8.2.50.0060.00318.07
8.2.40.0040.00418.21
8.2.30.0050.00319.25
8.2.20.0040.00417.78
8.2.10.0040.00418.16
8.2.00.0050.00317.67
8.1.280.0140.00325.92
8.1.270.0030.00522.10
8.1.260.0070.00026.35
8.1.250.0070.00028.09
8.1.240.0090.00621.34
8.1.230.0080.00419.55
8.1.220.0000.00817.74
8.1.210.0040.00418.77
8.1.200.0060.00317.13
8.1.190.0050.00517.22
8.1.180.0040.00418.10
8.1.170.0030.00618.42
8.1.160.0000.00821.95
8.1.150.0070.00018.85
8.1.140.0000.00717.38
8.1.130.0040.00417.82
8.1.120.0070.00017.40
8.1.110.0040.00417.39
8.1.100.0040.00417.29
8.1.90.0030.00317.29
8.1.80.0030.00717.24
8.1.70.0030.00317.40
8.1.60.0000.00817.55
8.1.50.0080.00017.50
8.1.40.0040.00417.50
8.1.30.0040.00417.57
8.1.20.0000.00717.64
8.1.10.0040.00417.55
8.1.00.0040.00417.57
8.0.300.0050.00318.77
8.0.290.0060.00316.75
8.0.280.0070.00018.34
8.0.270.0040.00417.25
8.0.260.0000.00617.23
8.0.250.0000.00717.00
8.0.240.0000.00816.88
8.0.230.0070.00016.87
8.0.220.0040.00416.73
8.0.210.0030.00516.86
8.0.200.0030.00316.75
8.0.190.0000.00716.91
8.0.180.0000.00716.74
8.0.170.0030.00616.85
8.0.160.0000.00916.79
8.0.150.0050.00216.71
8.0.140.0040.00416.75
8.0.130.0000.00513.29
8.0.120.0030.00516.75
8.0.110.0000.00816.67
8.0.100.0000.00716.76
8.0.90.0030.00516.63
8.0.80.0060.00916.77
8.0.70.0070.00016.79
8.0.60.0040.00416.70
8.0.50.0000.00716.94
8.0.30.0130.00617.15
8.0.20.0110.00817.40
8.0.10.0050.00316.94
8.0.00.0050.01316.68
7.4.330.0000.00515.00
7.4.320.0060.00016.46
7.4.300.0000.00616.44
7.4.290.0030.00316.54
7.4.280.0070.00316.50
7.4.270.0030.00416.39
7.4.260.0050.00216.62
7.4.250.0050.00316.52
7.4.240.0020.00516.57
7.4.230.0000.00716.66
7.4.220.0050.01316.45
7.4.210.0060.00916.61
7.4.200.0070.00016.38
7.4.160.0060.00916.39
7.4.150.0120.00617.40
7.4.140.0070.00917.86
7.4.130.0110.00816.40
7.4.120.0090.00916.31
7.4.110.0060.00916.54
7.4.100.0110.00816.34
7.4.90.0060.01916.20
7.4.80.0130.01016.38
7.4.70.0110.00716.64
7.4.60.0080.00916.52
7.4.50.0030.00316.35
7.4.40.0030.01316.65
7.4.30.0060.01116.49
7.4.00.0090.00614.91
7.3.330.0050.00013.22
7.3.320.0000.00513.29
7.3.310.0070.00016.40
7.3.300.0030.00316.19
7.3.290.0070.00716.34
7.3.280.0060.01116.32
7.3.270.0080.01417.40
7.3.260.0110.00616.45
7.3.250.0050.01316.20
7.3.240.0130.00316.39
7.3.230.0140.00316.39
7.3.210.0040.01516.51
7.3.200.0120.00619.39
7.3.190.0060.01216.36
7.3.180.0100.01016.17
7.3.170.0100.00716.27
7.3.160.0100.00616.32
7.3.120.0120.00514.61
7.3.110.0090.00914.70
7.3.100.0090.00614.82
7.3.90.0060.00714.63
7.3.80.0050.00814.75
7.3.70.0050.00714.81
7.3.60.0040.01114.64
7.3.50.0050.00714.81
7.3.40.0060.00414.74
7.3.30.0080.00614.77
7.3.20.0070.00616.57
7.3.10.0080.00916.59
7.3.00.0060.00716.39
7.2.330.0080.00916.86
7.2.320.0040.01316.43
7.2.310.0090.01016.79
7.2.300.0100.01016.46
7.2.290.0000.01916.42
7.2.250.0080.01214.75
7.2.240.0030.01515.08
7.2.230.0080.00814.82
7.2.220.0020.01314.87
7.2.210.0040.01114.89
7.2.200.0070.00514.88
7.2.190.0050.00814.96
7.2.180.0090.00615.12
7.2.170.0030.00914.97
7.2.00.0070.00719.29
7.1.330.0080.00615.58
7.1.320.0100.00615.56
7.1.310.0020.00915.67
7.1.300.0030.00915.48
7.1.290.0060.00515.61
7.1.280.0070.00515.51
7.1.270.0020.01115.67
7.1.260.0030.01015.55
7.1.100.0100.01018.06
7.1.70.0090.00616.81
7.1.60.0030.02119.32
7.1.50.0100.01316.85
7.1.00.0000.08022.44
7.0.200.0040.00416.50
7.0.140.0100.06322.00
7.0.60.0100.06019.93
7.0.50.0070.07717.75
7.0.40.0100.03720.09
7.0.30.0330.08320.23
7.0.20.0330.06320.33
7.0.10.0130.08020.09
7.0.00.0170.08320.15
5.6.280.0070.07021.00
5.6.210.0000.04320.71
5.6.200.0070.04718.25
5.6.190.0000.05720.52
5.6.180.0400.04320.43
5.6.170.0400.06320.48
5.6.160.0070.08320.46
5.6.150.0000.04318.15
5.6.140.0030.05018.16
5.6.130.0070.04018.14
5.6.120.0130.07320.95
5.6.110.0100.08321.02
5.6.100.0170.06021.05
5.6.90.0100.07721.04
5.6.80.0170.07720.38
5.5.350.0170.06720.39
5.5.340.0130.06717.98
5.5.330.0000.09320.27
5.5.320.0430.05320.31
5.5.310.0130.04320.39
5.5.300.0230.06017.96
5.5.290.0070.07718.06
5.5.280.0100.07720.69
5.5.270.0170.07320.64
5.5.260.0030.05020.77
5.5.250.0100.07720.59
5.5.240.2200.03320.33
5.4.450.0270.05019.32
5.4.440.0970.06019.58
5.4.430.0500.05719.60
5.4.420.0170.05719.63
5.4.410.1000.06319.48
5.4.400.1070.06019.02
5.4.390.0930.04319.30
5.4.380.0500.05718.63
5.4.370.0230.05718.80
5.4.360.0370.05018.79
5.4.350.0470.05018.79
5.4.340.0270.07018.61
5.4.320.0080.04412.51
5.4.310.0040.04412.50
5.4.300.0070.04512.50
5.4.290.0100.03912.50
5.4.280.0120.04612.40
5.4.270.0070.04212.39
5.4.260.0060.03812.39
5.4.250.0080.04612.40
5.4.240.0100.03312.40
5.4.230.0090.04912.39
5.4.220.0070.05312.39
5.4.210.0080.05112.39
5.4.200.0080.05212.39
5.4.190.0120.04712.39
5.4.180.0060.05412.39
5.4.170.0090.05012.40
5.4.160.0080.04912.39
5.4.150.0090.04812.39
5.4.140.0110.04712.07
5.4.130.0060.04212.06
5.4.120.0170.04012.02
5.4.110.0060.03712.01
5.4.100.0050.03612.02
5.4.90.0110.03112.02
5.4.80.0070.03612.01
5.4.70.0090.03112.02
5.4.60.0070.03612.01
5.4.50.0060.03812.01
5.4.40.0080.03312.00
5.4.30.0070.03412.00
5.4.20.0060.03612.00
5.4.10.0070.03512.00
5.4.00.0100.04011.48
5.3.290.0090.03812.80
5.3.280.0040.03912.70
5.3.270.0080.04412.73
5.3.260.0040.04312.72
5.3.250.0070.04012.72
5.3.240.0090.04512.72
5.3.230.0100.04212.71
5.3.220.0070.03812.68
5.3.210.0090.03712.68
5.3.200.0070.03612.68
5.3.190.0040.04012.68
5.3.180.0060.03812.67
5.3.170.0060.03712.67
5.3.160.0070.03912.67
5.3.150.0120.04412.67
5.3.140.0050.05412.66
5.3.130.0080.04612.66
5.3.120.0030.04212.66
5.3.110.0040.04012.66
5.3.100.0080.03512.12
5.3.90.0070.03512.10
5.3.80.0080.03412.09
5.3.70.0070.03612.09
5.3.60.0070.03612.08
5.3.50.0050.03912.03
5.3.40.0080.03612.03
5.3.30.0070.03711.99
5.3.20.0070.03611.76
5.3.10.0110.04211.73
5.3.00.0110.04411.72
5.2.170.0080.0409.22
5.2.160.0090.0379.23
5.2.150.0050.0349.22
5.2.140.0050.0329.22
5.2.130.0080.0289.18
5.2.120.0070.0279.18
5.2.110.0050.0309.18
5.2.100.0040.0339.18
5.2.90.0080.0299.18
5.2.80.0070.0319.18
5.2.70.0100.0269.18
5.2.60.0070.0319.13
5.2.50.0060.0349.10
5.2.40.0100.0329.07
5.2.30.0070.0309.04
5.2.20.0080.0279.04
5.2.10.0050.0348.95
5.2.00.0050.0308.80
5.1.60.0020.0258.09
5.1.50.0050.0238.08
5.1.40.0040.0298.06
5.1.30.0040.0268.42
5.1.20.0030.0278.44
5.1.10.0040.0268.16
5.1.00.0050.0258.16
5.0.50.0020.0226.64
5.0.40.0010.0216.50
5.0.30.0050.0306.32
5.0.20.0050.0246.28
5.0.10.0050.0226.25
5.0.00.0030.0356.25
4.4.90.0040.0214.78
4.4.80.0070.0194.75
4.4.70.0020.0164.76
4.4.60.0030.0164.75
4.4.50.0050.0144.77
4.4.40.0030.0264.71
4.4.30.0040.0164.76
4.4.20.0040.0184.84
4.4.10.0040.0154.85
4.4.00.0040.0244.76
4.3.110.0030.0164.67
4.3.100.0030.0214.66
4.3.90.0030.0154.63
4.3.80.0040.0254.58
4.3.70.0050.0154.63
4.3.60.0010.0194.63
4.3.50.0050.0164.62
4.3.40.0030.0244.53
4.3.30.0020.0163.30
4.3.20.0000.0193.28
4.3.10.0000.0183.24
4.3.00.0000.0276.86

preferences:
43.13 ms | 401 KiB | 5 Q