3v4l.org

run code in 300+ PHP versions simultaneously
<?php $c = " total used free shared buffers cached\nMem: 494 383 111 0 29 200\n-/+ buffers/cache: 153 341\nSwap: 255 0 255"; preg_match("/Mem:\s+(?P<total>\d+)\s+(?P<used>\d+)\s+(?P<free>\d+)\s+(?P<shared>\d+)\s+(?P<buffers>\d+)\s+(?P<cached>\d+)/", $c ,$r); print_r($r); preg_match("/Swap:\s+(?P<swapTotal>\d+)\s+(?P<swapUsed>\d+)\s+(?P<swapFree>\d+)/", $c ,$r); print_r($r);

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.0110.00418.55
8.3.50.0100.00917.50
8.3.40.0120.00318.67
8.3.30.0040.01118.57
8.3.20.0000.00818.73
8.3.10.0080.00020.48
8.3.00.0040.00417.63
8.2.180.0090.00616.88
8.2.170.0130.00722.96
8.2.160.0070.01020.55
8.2.150.0050.00324.18
8.2.140.0040.00424.66
8.2.130.0080.00026.16
8.2.120.0000.00919.95
8.2.110.0090.00020.39
8.2.100.0040.00817.91
8.2.90.0040.00419.13
8.2.80.0000.00817.97
8.2.70.0040.00417.75
8.2.60.0000.00817.80
8.2.50.0040.00418.07
8.2.40.0050.00218.03
8.2.30.0040.00418.04
8.2.20.0000.00817.64
8.2.10.0080.00017.70
8.2.00.0030.00617.83
8.1.280.0150.00025.92
8.1.270.0080.00024.66
8.1.260.0070.00026.35
8.1.250.0050.00328.09
8.1.240.0100.00023.69
8.1.230.0070.00423.91
8.1.220.0040.00418.77
8.1.210.0040.00418.79
8.1.200.0100.00017.48
8.1.190.0080.00017.39
8.1.180.0090.00018.10
8.1.170.0000.00818.77
8.1.160.0040.00418.86
8.1.150.0030.00518.75
8.1.140.0080.00317.47
8.1.130.0000.00717.85
8.1.120.0000.00817.55
8.1.110.0080.00017.52
8.1.100.0060.00317.47
8.1.90.0040.00417.47
8.1.80.0050.00317.51
8.1.70.0040.00417.55
8.1.60.0030.00617.51
8.1.50.0030.00617.58
8.1.40.0060.00317.55
8.1.30.0030.00617.75
8.1.20.0000.00817.77
8.1.10.0020.00517.57
8.1.00.0000.00817.49
8.0.300.0070.00019.88
8.0.290.0040.00416.75
8.0.280.0040.00418.32
8.0.270.0040.00417.23
8.0.260.0000.00716.84
8.0.250.0000.00716.93
8.0.240.0060.00316.95
8.0.230.0030.00316.96
8.0.220.0040.00416.93
8.0.210.0000.00716.88
8.0.200.0040.00416.98
8.0.190.0030.00617.04
8.0.180.0030.00517.06
8.0.170.0040.00416.90
8.0.160.0000.00716.96
8.0.150.0000.00916.99
8.0.140.0030.00616.88
8.0.130.0050.00013.48
8.0.120.0050.00316.95
8.0.110.0000.00716.88
8.0.100.0070.00017.03
8.0.90.0040.00417.06
8.0.80.0090.01017.00
8.0.70.0050.00216.88
8.0.60.0050.00316.89
8.0.50.0050.00316.99
8.0.30.0060.01317.41
8.0.20.0060.01117.05
8.0.10.0040.00417.07
8.0.00.0100.01016.71
7.4.330.0020.00213.09
7.4.320.0000.00716.67
7.4.300.0000.00616.74
7.4.290.0030.00316.71
7.4.280.0030.00716.77
7.4.270.0030.00516.79
7.4.260.0000.00813.44
7.4.250.0040.00416.61
7.4.240.0000.00716.71
7.4.230.0040.00416.70
7.4.220.0070.01016.82
7.4.210.0050.01016.74
7.4.200.0070.00016.77
7.4.190.0000.00716.62
7.4.160.0100.00616.78
7.4.150.0120.00616.61
7.4.140.0120.00616.64
7.4.130.0080.01116.69
7.4.120.0060.01116.69
7.4.110.0120.00616.53
7.4.100.0030.01316.63
7.4.90.0070.01016.67
7.4.80.0120.00416.65
7.4.70.0070.01316.55
7.4.60.0120.00916.72
7.4.50.0030.00616.37
7.4.40.0040.01116.60
7.4.30.0090.01216.70
7.4.00.0030.01315.16
7.3.330.0060.00013.04
7.3.320.0000.00613.02
7.3.310.0040.00416.29
7.3.300.0030.00316.22
7.3.290.0000.01416.27
7.3.280.0080.01016.32
7.3.270.0090.00816.37
7.3.260.0140.00816.43
7.3.250.0110.00716.44
7.3.240.0120.00316.75
7.3.230.0060.01016.51
7.3.210.0100.00616.28
7.3.200.0090.01319.39
7.3.190.0110.00716.33
7.3.180.0050.01116.66
7.3.170.0100.00716.47
7.3.160.0070.01016.59
7.3.120.0140.00014.98
7.2.330.0170.00616.58
7.2.320.0110.00516.69
7.2.310.0070.01316.54
7.2.300.0040.01316.55
7.2.290.0150.00316.58
7.1.70.0000.00717.03
7.1.60.0100.01419.40
7.1.50.0230.01035.01
7.1.00.0070.07022.38
7.0.200.0040.00716.75
7.0.140.0000.07721.95
7.0.120.0000.07022.17
7.0.60.0130.08020.00
7.0.50.0170.06317.88
7.0.40.0030.04320.54
7.0.30.0530.04720.28
7.0.20.0200.05020.19
7.0.10.0370.07020.23
7.0.00.0070.08320.21
5.6.280.0000.07720.81
5.6.210.0030.07720.74
5.6.200.0070.04018.18
5.6.190.0070.08320.62
5.6.180.0430.07020.49
5.6.170.0170.04720.55
5.6.160.0130.08020.53
5.6.150.0070.06718.18
5.6.140.0130.07318.21
5.6.130.0000.04318.21
5.6.120.0070.03721.11
5.6.110.0100.07721.02
5.6.100.0130.07021.10
5.6.90.0070.04021.09
5.6.80.0100.06320.39
5.6.70.3630.04020.39
5.5.350.0330.06320.39
5.5.340.0100.08317.97
5.5.330.0030.08020.47
5.5.320.0070.05020.41
5.5.310.0300.07720.23
5.5.300.0100.07717.95
5.5.290.0100.03317.94
5.5.280.0070.04720.64
5.5.270.0030.04320.86
5.5.260.0170.07320.75
5.5.250.0070.04720.66
5.5.240.0070.08320.27
5.4.450.0070.08019.33
5.4.440.0100.06319.20
5.4.430.0030.06019.47
5.4.420.0130.07019.47
5.4.410.0100.06019.05
5.4.400.0000.04719.08
5.4.390.0030.04719.00
5.4.380.0030.07719.20
5.4.370.0030.08019.16
5.4.360.0000.06718.89
5.4.350.0100.07019.24
5.4.340.0030.05019.17
5.4.320.0030.07019.09
5.4.310.0130.04019.14
5.4.300.0030.07018.99
5.4.290.0030.05319.23
5.4.280.0070.07719.24
5.4.270.0100.07719.15
5.4.260.0030.07319.00
5.4.250.0100.07019.23
5.4.240.0070.05319.15
5.4.230.0100.06019.14
5.4.220.0070.06319.14
5.4.210.0070.06319.23
5.4.200.0130.03719.07
5.4.190.0100.07319.22
5.4.180.0130.04318.96
5.4.170.0030.05319.13
5.4.160.0030.06019.25
5.4.150.0070.03719.23
5.4.140.0030.08016.48
5.4.130.0100.03716.34
5.4.120.0030.03716.34
5.4.110.0070.03316.44
5.4.100.0030.03716.50
5.4.90.0070.04316.58
5.4.80.0070.03716.46
5.4.70.0100.03716.34
5.4.60.0100.06716.36
5.4.50.0030.03716.52
5.4.40.0100.07016.27
5.4.30.0130.06716.34
5.4.20.0000.07316.43
5.4.10.0070.05016.36
5.4.00.0070.06015.84
5.3.290.0030.08314.73
5.3.280.0030.07314.60
5.3.270.0070.04714.63
5.3.260.0030.06714.66
5.3.250.0000.05014.52
5.3.240.0070.03314.60
5.3.230.0030.07014.73
5.3.220.0030.04014.72
5.3.210.0070.05714.60
5.3.200.0030.04714.59
5.3.190.0000.05714.61
5.3.180.0000.05314.55
5.3.170.0070.07014.59
5.3.160.0070.06014.55
5.3.150.0070.03714.55
5.3.140.0170.03014.51
5.3.130.0070.06714.54
5.3.120.0030.03714.57
5.3.110.0170.07014.55
5.3.100.0000.08014.08
5.3.90.0170.07014.01
5.3.80.0130.05313.93
5.3.70.0100.07014.16
5.3.60.0130.06314.00
5.3.50.0070.06013.99
5.3.40.0070.07713.94
5.3.30.0100.05713.95
5.3.20.0070.05713.65
5.3.10.0000.04313.70
5.3.00.0000.06713.68
5.2.170.0030.06311.06
5.2.160.0100.05011.20
5.2.150.0030.06311.06
5.2.140.0030.04311.13
5.2.130.0100.03711.15
5.2.120.0070.02711.02
5.2.110.0100.05311.06
5.2.100.0100.06011.25
5.2.90.0030.02710.99
5.2.80.0030.03011.05
5.2.70.0070.05311.01
5.2.60.0030.06311.09
5.2.50.0030.03711.07
5.2.40.0070.06310.96
5.2.30.0030.05311.13
5.2.20.0000.04010.96
5.2.10.0000.03310.80
5.2.00.0070.03010.87
5.1.60.0000.0339.83
5.1.50.0000.05310.00
5.1.40.0030.0279.99
5.1.30.0030.06010.38
5.1.20.0030.05710.35
5.1.10.0070.04710.13
5.1.00.0030.03010.13
5.0.50.0030.0278.52
5.0.40.0070.0178.42
5.0.30.0100.0508.23
5.0.20.0000.0438.20
5.0.10.0000.0408.31
5.0.00.0000.0338.12
4.4.90.0000.0308.04
4.4.80.0030.0308.04
4.4.70.0000.0208.04
4.4.60.0000.0208.04
4.4.50.0000.0408.04
4.4.40.0000.0308.04
4.4.30.0030.0378.04
4.4.20.0030.0138.04
4.4.10.0000.0208.04
4.4.00.0100.0478.04
4.3.110.0070.0278.04
4.3.100.0030.0378.04
4.3.90.0000.0208.04
4.3.80.0000.0538.04
4.3.70.0070.0108.04
4.3.60.0070.0308.04
4.3.50.0030.0338.04
4.3.40.0070.0308.04
4.3.30.0000.0208.04
4.3.20.0000.0238.04
4.3.10.0030.0338.04
4.3.00.0000.0308.04

preferences:
42.46 ms | 401 KiB | 5 Q