3v4l.org

run code in 300+ PHP versions simultaneously
<?php Class X { public $names = array('bob', 'fred'); } Class Y extends X { public $names = array('alice');//array_merge(parent::names, array('alice')); function __construct() { var_dump(parent::$names); } } $x = new X(); var_dump($x->names); $y = new Y(); var_dump($y->names);

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.70.0120.00316.58
8.3.60.0100.00718.68
8.3.50.0140.00321.99
8.3.40.0170.00318.88
8.3.30.0090.00618.88
8.3.20.0040.00420.38
8.3.10.0080.00023.61
8.3.00.0100.00017.91
8.2.180.0070.01116.88
8.2.170.0150.00622.96
8.2.160.0030.01320.22
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0040.00420.84
8.2.110.0030.00622.22
8.2.100.0090.00319.57
8.2.90.0000.01019.22
8.2.80.0040.00417.97
8.2.70.0090.00017.63
8.2.60.0080.00017.93
8.2.50.0040.00418.07
8.2.40.0080.00018.16
8.2.30.0000.00718.10
8.2.20.0040.00417.50
8.2.10.0040.00417.89
8.2.00.0040.00417.68
8.1.280.0150.00425.92
8.1.270.0000.00923.88
8.1.260.0040.00426.35
8.1.250.0070.00028.09
8.1.240.0030.00623.88
8.1.230.0070.00419.16
8.1.220.0070.00017.74
8.1.210.0040.00418.77
8.1.200.0060.00317.22
8.1.190.0040.00417.23
8.1.180.0040.00418.10
8.1.170.0000.00818.50
8.1.160.0000.00821.83
8.1.150.0050.00218.86
8.1.140.0000.00717.44
8.1.130.0000.00717.79
8.1.120.0080.00017.42
8.1.110.0000.00717.38
8.1.100.0070.00017.36
8.1.90.0000.00717.36
8.1.80.0000.00717.38
8.1.70.0070.00017.32
8.1.60.0040.00417.47
8.1.50.0000.00817.43
8.1.40.0000.00817.59
8.1.30.0040.00417.68
8.1.20.0050.00317.70
8.1.10.0000.00717.54
8.1.00.0040.00417.40
8.0.300.0040.00418.77
8.0.290.0040.00416.63
8.0.280.0000.00718.41
8.0.270.0000.00717.26
8.0.260.0060.00017.19
8.0.250.0040.00416.96
8.0.240.0000.00917.01
8.0.230.0080.00016.90
8.0.220.0000.00716.79
8.0.210.0000.00616.96
8.0.200.0040.00416.85
8.0.190.0050.00316.97
8.0.180.0070.00016.98
8.0.170.0040.00416.83
8.0.160.0040.00416.85
8.0.150.0000.00816.89
8.0.140.0040.00416.83
8.0.130.0000.00513.42
8.0.120.0000.00816.71
8.0.110.0040.00416.97
8.0.100.0040.00416.72
8.0.90.0040.00416.89
8.0.80.0060.01316.83
8.0.70.0040.00417.02
8.0.60.0070.00016.70
8.0.50.0080.00016.81
8.0.30.0100.01117.08
8.0.20.0120.00617.44
8.0.10.0000.00716.86
8.0.00.0100.00816.89
7.4.330.0050.00015.09
7.4.320.0030.00316.45
7.4.300.0030.00316.52
7.4.290.0000.00816.60
7.4.280.0050.00316.65
7.4.270.0030.00316.66
7.4.260.0000.00916.45
7.4.250.0000.00716.41
7.4.240.0020.00516.55
7.4.230.0030.00316.31
7.4.220.0120.00416.57
7.4.210.0090.00616.46
7.4.200.0000.00816.39
7.4.160.0080.00816.51
7.4.150.0060.01217.40
7.4.140.0130.00417.86
7.4.130.0060.01216.65
7.4.120.0130.00516.48
7.4.110.0080.01216.65
7.4.100.0030.01316.57
7.4.90.0060.01016.66
7.4.80.0090.00919.39
7.4.70.0150.00516.64
7.4.60.0090.01316.40
7.4.50.0000.00416.36
7.4.40.0100.00716.71
7.4.30.0110.00816.54
7.4.00.0070.00714.84
7.3.330.0000.00713.36
7.3.320.0000.00513.13
7.3.310.0020.00516.21
7.3.300.0000.00816.43
7.3.290.0080.00616.34
7.3.280.0050.01216.35
7.3.270.0040.01717.40
7.3.260.0120.01216.36
7.3.250.0130.00716.42
7.3.240.0160.00016.66
7.3.230.0120.00616.42
7.3.210.0110.00816.37
7.3.200.0110.00719.39
7.3.190.0120.00916.36
7.3.180.0080.00816.41
7.3.170.0040.01216.38
7.3.160.0210.00016.42
7.3.120.0050.01114.76
7.3.110.0080.00614.69
7.3.100.0040.01114.70
7.3.90.0030.00714.83
7.3.80.0000.01314.86
7.3.70.0070.00414.91
7.3.60.0040.01114.77
7.3.50.0080.00314.62
7.3.40.0120.00314.79
7.3.30.0070.01014.76
7.3.20.0110.00416.50
7.3.10.0090.00616.44
7.3.00.0070.00716.71
7.2.330.0140.00316.71
7.2.320.0170.00016.58
7.2.310.0110.00716.66
7.2.300.0030.01616.78
7.2.290.0090.01316.55
7.2.250.0080.01114.61
7.2.240.0100.00715.13
7.2.230.0040.01114.88
7.2.220.0040.00715.04
7.2.210.0000.01315.29
7.2.200.0030.01015.07
7.2.190.0060.00614.92
7.2.180.0090.00614.91
7.2.170.0080.00815.06
7.2.60.0090.00616.66
7.2.00.0040.01619.21
7.1.330.0110.00315.57
7.1.320.0030.00715.84
7.1.310.0060.00315.91
7.1.300.0030.00715.71
7.1.290.0050.00315.77
7.1.280.0070.00315.67
7.1.270.0030.01015.75
7.1.260.0060.00315.63
7.1.200.0030.01215.84
7.1.100.0080.00618.23
7.1.70.0040.00417.11
7.1.60.0070.01619.70
7.1.50.0130.01016.93
7.1.00.0030.07322.51
7.0.200.0100.01015.05
7.0.140.0070.07021.99
7.0.60.0100.08319.93
7.0.50.0100.06717.95
7.0.40.0100.03720.30
7.0.30.0230.05020.33
7.0.20.0230.08020.24
7.0.10.0070.08320.10
7.0.00.0000.05320.25
5.6.280.0030.07320.79
5.6.210.0100.05020.50
5.6.200.0000.06718.12
5.6.190.0030.04720.33
5.6.180.0200.05020.58
5.6.170.0200.04020.56
5.6.160.0130.07720.50
5.6.150.0030.04718.27
5.6.140.0030.07718.12
5.6.130.0000.05318.19
5.6.120.0070.07721.00
5.6.110.0130.07321.07
5.6.100.0030.05020.96
5.6.90.0100.06320.98
5.6.80.0170.07020.44
5.5.350.0300.07020.40
5.5.340.0100.04018.08
5.5.330.0070.08720.45
5.5.320.0130.04320.35
5.5.310.0400.07320.19
5.5.300.0070.04318.03
5.5.290.0030.06718.08
5.5.280.0100.08720.87
5.5.270.0130.08320.78
5.5.260.0070.08720.80
5.5.250.0000.08720.61
5.5.240.0000.04720.29
5.4.450.0230.05319.48
5.4.440.0730.05719.20
5.4.430.0830.05019.30
5.4.420.0730.05719.34
5.4.410.0070.05718.97
5.4.400.0330.05018.67
5.4.390.0370.05018.75
5.4.380.0100.05718.63
5.4.370.0030.05718.63
5.4.360.0070.05318.73
5.4.350.0100.03512.02
5.4.340.0040.04012.02
5.4.320.0080.03412.50
5.4.310.0050.03912.50
5.4.300.0050.03912.50
5.4.290.0050.03912.50
5.4.280.0050.03712.40
5.4.270.0050.03812.39
5.4.260.0090.03812.39
5.4.250.0050.04112.39
5.4.240.0050.03812.39
5.4.230.0060.03712.38
5.4.220.0050.03812.39
5.4.210.0080.03412.38
5.4.200.0050.03912.38
5.4.190.0070.03412.38
5.4.180.0060.03512.38
5.4.170.0050.03612.39
5.4.160.0060.04112.39
5.4.150.0070.03812.39
5.4.140.0060.04112.07
5.4.130.0050.03812.06
5.4.120.0040.03612.02
5.4.110.0080.03312.01
5.4.100.0090.03112.01
5.4.90.0060.03612.01
5.4.80.0070.03612.02
5.4.70.0120.02912.01
5.4.60.0050.03512.01
5.4.50.0050.03612.01
5.4.40.0090.03112.00
5.4.30.0070.03511.99
5.4.20.0060.03511.99
5.4.10.0060.03412.00
5.4.00.0060.03511.48
5.3.290.0100.04312.80
5.3.280.0090.03512.71
5.3.270.0050.03912.72
5.3.260.0110.03312.72
5.3.250.0080.03512.71
5.3.240.0090.03512.72
5.3.230.0080.03812.71
5.3.220.0100.03412.68
5.3.210.0030.04412.68
5.3.200.0060.05312.68
5.3.190.0030.03912.68
5.3.180.0070.03412.68
5.3.170.0070.03512.67
5.3.160.0080.03612.67
5.3.150.0050.03812.68
5.3.140.0030.04012.66
5.3.130.0050.03912.66
5.3.120.0060.03812.66
5.3.110.0090.04312.66
5.3.100.0080.03512.13
5.3.90.0060.03712.11
5.3.80.0050.03812.09
5.3.70.0140.04112.09
5.3.60.0050.04812.09
5.3.50.0060.03612.02
5.3.40.0100.03212.04
5.3.30.0020.03811.99
5.3.20.0050.03611.77
5.3.10.0030.03711.74
5.3.00.0040.03911.72
5.2.170.0030.0329.23
5.2.160.0050.0289.23
5.2.150.0040.0309.23
5.2.140.0060.0299.22
5.2.130.0040.0309.18
5.2.120.0080.0289.18
5.2.110.0080.0329.18
5.2.100.0040.0379.18
5.2.90.0080.0259.18
5.2.80.0080.0289.18
5.2.70.0030.0339.18
5.2.60.0070.0279.13
5.2.50.0080.0269.10
5.2.40.0060.0279.07
5.2.30.0040.0309.05
5.2.20.0050.0289.04
5.2.10.0040.0288.95
5.2.00.0050.0288.81
5.1.60.0040.0238.10
5.1.50.0060.0238.09
5.1.40.0050.0248.07
5.1.30.0060.0248.42
5.1.20.0040.0278.44
5.1.10.0100.0278.17
5.1.00.0040.0338.17
5.0.50.0030.0276.64
5.0.40.0050.0176.50
5.0.30.0040.0306.32
5.0.20.0060.0166.28
5.0.10.0060.0166.27
5.0.00.0030.0316.25
4.4.90.0030.0154.78
4.4.80.0000.0184.76
4.4.70.0030.0154.75
4.4.60.0040.0144.75
4.4.50.0020.0164.77
4.4.40.0030.0274.71
4.4.30.0040.0144.76
4.4.20.0060.0124.84
4.4.10.0020.0164.85
4.4.00.0030.0244.76
4.3.110.0060.0124.66
4.3.100.0010.0184.66
4.3.90.0040.0134.63
4.3.80.0020.0244.59
4.3.70.0000.0174.63
4.3.60.0030.0174.63
4.3.50.0040.0214.63
4.3.40.0040.0244.53
4.3.30.0010.0173.30
4.3.20.0040.0143.28
4.3.10.0020.0163.23
4.3.00.0000.0237.18

preferences:
46.06 ms | 401 KiB | 5 Q