3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = array_fill(0, 200, 0); $time = microtime(true); for ($i = 0; $i <= 10000; $i++) { array_merge($array); } var_dump(microtime(true) - $time); $time = microtime(true); for ($i = 0; $i <= 10000; $i++) { array_values($array); } var_dump(microtime(true) - $time);

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)
7.4.10.0120.01514.75
7.4.00.0080.02014.83
7.3.130.0070.01714.91
7.3.120.0060.01814.87
7.3.110.0050.01814.91
7.3.100.0040.01814.86
7.3.90.0070.01314.71
7.3.80.0000.01714.95
7.3.70.0050.01214.66
7.3.60.0020.01714.81
7.3.50.0040.01814.87
7.3.40.0070.01314.64
7.3.30.0070.01514.80
7.3.20.0070.01516.64
7.3.10.0050.01416.43
7.3.00.0000.01716.47
7.2.260.0090.01915.01
7.2.250.0020.02414.83
7.2.240.0090.01515.11
7.2.230.0050.01715.20
7.2.220.0030.01515.08
7.2.210.0020.01515.02
7.2.200.0050.01514.90
7.2.190.0120.00914.88
7.2.180.0050.01115.00
7.2.170.0050.01614.96
7.2.160.0000.01514.92
7.2.150.0070.01616.97
7.2.140.0060.01216.66
7.2.130.0070.01416.87
7.2.120.0030.01716.90
7.2.110.0030.01016.73
7.2.100.0100.01016.98
7.2.90.0070.01416.95
7.2.80.0030.01217.04
7.2.70.0080.01116.76
7.2.60.0030.01816.98
7.2.50.0030.01316.83
7.2.40.0070.01017.00
7.2.30.0030.02016.93
7.2.20.0060.01216.99
7.2.10.0040.01116.67
7.2.00.0030.01818.00
7.1.330.0050.02015.95
7.1.320.0080.01815.73
7.1.310.0050.02015.88
7.1.300.0050.02115.70
7.1.290.0080.01615.71
7.1.280.0050.02015.87
7.1.270.0040.02315.43
7.1.260.0030.01915.71
7.1.250.0040.01816.05
7.1.240.0030.02015.61
7.1.230.0000.02215.87
7.1.220.0030.01915.87
7.1.210.0000.02415.96
7.1.200.0060.01215.79
7.1.190.0030.02315.55
7.1.180.0040.01815.80
7.1.170.0030.01715.64
7.1.160.0060.01915.78
7.1.150.0030.02015.74
7.1.140.0030.02015.73
7.1.130.0070.01615.94
7.1.120.0070.01715.91
7.1.110.0030.02115.82
7.1.100.0000.02315.58
7.1.90.0060.01216.04
7.1.80.0100.01715.81
7.1.70.0020.02216.57
7.1.60.0070.02917.59
7.1.50.0030.03316.48
7.1.40.0070.01715.79
7.1.30.0070.01015.86
7.1.20.0030.02015.54
7.1.10.0100.01715.88
7.1.00.0050.05519.01
7.0.330.0000.04115.45
7.0.320.0030.02415.59
7.0.310.0000.02715.22
7.0.300.0070.02115.47
7.0.290.0070.03115.24
7.0.280.0070.02215.40
7.0.270.0070.02515.44
7.0.260.0030.02915.41
7.0.250.0070.02415.29
7.0.240.0090.02215.63
7.0.230.0070.03515.32
7.0.220.0070.02715.57
7.0.210.0040.02815.11
7.0.200.0050.02416.06
7.0.190.0100.02315.55
7.0.180.0100.02415.30
7.0.170.0030.02715.44
7.0.160.0030.02415.61
7.0.150.0000.03715.57
7.0.140.0050.06418.81
7.0.130.0060.02815.24
7.0.120.0060.02115.27
7.0.110.0030.02815.58
7.0.100.0000.03915.43
7.0.90.0070.02515.44
7.0.80.0000.04915.44
7.0.70.0070.04015.40
7.0.60.0070.04317.72
7.0.50.0120.06016.65
7.0.40.0050.04816.78
7.0.30.0170.05916.90
7.0.20.0170.05416.74
7.0.10.0050.05716.86
7.0.00.0030.04216.80
5.6.400.0000.15914.42
5.6.390.0100.15614.65
5.6.380.0030.15514.42
5.6.370.0070.16914.46
5.6.360.0030.15814.46
5.6.350.0000.15914.17
5.6.340.0070.15314.55
5.6.330.0070.15514.39
5.6.320.0000.16514.25
5.6.310.0070.15614.70
5.6.300.0030.15414.11
5.6.290.0030.16414.66
5.6.280.0030.15414.21
5.6.270.0070.15514.21
5.6.260.0070.15814.40
5.6.250.0100.15414.32
5.6.240.0000.16414.21
5.6.230.0000.17114.45
5.6.220.0070.16514.30
5.6.210.0100.17217.57
5.6.200.0050.15616.19
5.6.190.0070.14917.37
5.6.180.0150.15917.24
5.6.170.0170.17117.34
5.6.160.0030.18017.37
5.6.150.0080.16316.18
5.6.140.0080.17816.24
5.6.130.0120.16416.28
5.6.120.0050.19017.77
5.6.110.0080.16317.53
5.6.100.0070.15717.52
5.6.90.0030.16517.53
5.6.80.0080.18617.26
5.6.70.0070.15514.23
5.6.60.0070.15814.16
5.6.50.0000.15914.07
5.6.40.0070.15114.43
5.6.30.0030.18514.14
5.6.20.0070.17914.09
5.6.10.0030.17414.09
5.6.00.0030.15314.17
5.5.380.0030.16614.07
5.5.370.0030.16614.16
5.5.360.0070.15714.29
5.5.350.0100.18617.39
5.5.340.0000.15815.98
5.5.330.0070.17117.30
5.5.320.0150.17617.21
5.5.310.0130.15317.45
5.5.300.0080.19716.06
5.5.290.0020.20416.15
5.5.280.0050.18117.50
5.5.270.0080.18717.53
5.5.260.0100.19017.58
5.5.250.0050.17017.50
5.5.240.0050.18117.11
5.5.230.0030.19514.15
5.5.220.0030.16414.08
5.5.210.0130.14614.08
5.5.200.0070.18714.38
5.5.190.0100.16314.51
5.5.180.0000.16714.07
5.5.170.0030.15114.39
5.5.160.0070.16814.16
5.5.150.0030.15414.48
5.5.140.0030.16114.32
5.5.130.0070.15714.19
5.5.120.0070.15414.33
5.5.110.0130.15314.16
5.5.100.0030.17414.01
5.5.90.0030.16514.06
5.5.80.0070.15814.30
5.5.70.0030.15514.24
5.5.60.0030.18514.20
5.5.50.0000.22614.50
5.5.40.0070.20114.05
5.5.30.0030.24914.20
5.5.20.0030.20314.18
5.5.10.0100.23714.00
5.5.00.0060.20214.18
5.4.450.0570.22115.34
5.4.440.0380.20815.42
5.4.430.0270.20615.23
5.4.420.0100.21915.36
5.4.410.0080.23615.35
5.4.400.0380.25515.19
5.4.390.0300.22715.21
5.4.380.0270.24014.92
5.4.370.0630.23514.90
5.4.360.0480.25314.97
5.4.350.0530.26614.97
5.4.340.0520.25415.00
5.4.330.0130.19911.27
5.4.320.0030.20211.89
5.4.310.0040.20311.89
5.4.300.0040.21811.89
5.4.290.0040.20111.89
5.4.280.0040.19811.84
5.4.270.0020.21511.84
5.4.260.0040.20911.84
5.4.250.0020.23011.84
5.4.240.0070.23911.84
5.4.230.0070.23211.83
5.4.220.0040.21711.83
5.4.210.0050.20711.83
5.4.200.0040.22311.83
5.4.190.0050.22111.83
5.4.180.0060.21911.83
5.4.170.0060.21011.84
5.4.160.0050.19811.84
5.4.150.0070.22511.83
5.4.140.0040.20311.67
5.4.130.0060.21111.67
5.4.120.0060.21811.65
5.4.110.0050.21511.65
5.4.100.0050.20911.64
5.4.90.0040.21511.64
5.4.80.0020.19911.64
5.4.70.0070.21311.64
5.4.60.0070.21511.64
5.4.50.0120.21911.64
5.4.40.0040.20911.64
5.4.30.0050.20111.64
5.4.20.0080.20111.64
5.4.10.0020.20911.64
5.4.00.0040.20611.38
5.3.290.0110.19112.80
5.3.280.0050.19412.71
5.3.270.0070.20612.72
5.3.260.0100.20212.72
5.3.250.0060.19112.72
5.3.240.0100.19012.72
5.3.230.0070.19012.70
5.3.220.0060.19412.68
5.3.210.0070.19212.68
5.3.200.0060.19112.68
5.3.190.0060.19712.67
5.3.180.0050.19212.67
5.3.170.0050.19712.67
5.3.160.0040.19112.68
5.3.150.0060.18612.67
5.3.140.0080.19012.66
5.3.130.0080.18912.66
5.3.120.0130.20212.66
5.3.110.0070.19212.66
5.3.100.0060.19712.13
5.3.90.0030.20112.12
5.3.80.0080.19112.11
5.3.70.0040.19312.11
5.3.60.0070.19112.09
5.3.50.0040.19312.04
5.3.40.0080.20212.04
5.3.30.0050.19212.00
5.3.20.0070.18911.78
5.3.10.0060.18911.75
5.3.00.0060.14711.71
5.2.170.0070.1969.24
5.2.160.0070.2019.24
5.2.150.0080.2059.24
5.2.140.0090.2179.23
5.2.130.0140.1909.20
5.2.120.0150.1899.20
5.2.110.0080.2139.20
5.2.100.0060.1989.20
5.2.90.0070.2099.20
5.2.80.0050.2059.20
5.2.70.0020.2159.20
5.2.60.0050.2099.14
5.2.50.0040.2049.11
5.2.40.0040.1959.09
5.2.30.0020.1979.07
5.2.20.0070.2349.05
5.2.10.0070.2088.98
5.2.00.0060.2048.84
5.1.60.0060.2288.13
5.1.50.0070.2328.13
5.1.40.0050.2438.11
5.1.30.0030.2348.46
5.1.20.0080.2308.48
5.1.10.0040.2348.21
5.1.00.0060.2698.20
5.0.50.0050.2576.68
5.0.40.0050.2466.54
5.0.30.0070.2686.36
5.0.20.0040.2466.33
5.0.10.0030.2506.30
5.0.00.0060.2636.30
4.4.90.0030.2814.78
4.4.80.0050.2594.76
4.4.70.0090.2334.75
4.4.60.0010.2424.76
4.4.50.0060.2304.77
4.4.40.0050.2444.71
4.4.30.0050.2374.76
4.4.20.0020.2554.84
4.4.10.0030.2384.85
4.4.00.0040.2654.76
4.3.110.0040.2614.67
4.3.100.0030.2384.66
4.3.90.0040.2424.64
4.3.80.0040.2734.64
4.3.70.0080.2534.64
4.3.60.0040.2374.64
4.3.50.0040.2444.64
4.3.40.0050.2484.59
4.3.30.0030.2723.41
4.3.20.0010.2513.38
4.3.10.0040.2443.34
4.3.00.0000.22715.62

preferences:
27.33 ms | 401 KiB | 5 Q