3v4l.org

run code in 300+ PHP versions simultaneously
<?php $txt = 'dog.cat' . str_repeat('.dog.cat', 815); for ($i = 0; $i < 5; ++$i) { $txt .= '.dog.cat'; echo count(explode('.', $txt)) . "\n"; echo strlen($txt) . "\n"; if (preg_match("/[a-z]+(\.[a-z]+)*/i", $txt, $match)) { echo "A match was found." . strlen($match[0]); } else { echo preg_last_error(); } echo "\n---\n"; }

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.4.140.0140.00818.02
8.4.130.0110.01118.02
8.4.120.0110.01020.79
8.4.110.0140.00618.96
8.4.100.0120.01017.90
8.4.90.0140.00720.86
8.4.80.0130.00818.91
8.4.70.0130.00918.86
8.4.60.0090.01218.86
8.4.50.0140.00718.81
8.4.40.0150.00719.50
8.4.30.0030.00620.59
8.4.20.0030.00620.69
8.4.10.0030.00618.82
8.3.270.0080.01116.92
8.3.260.0170.00416.87
8.3.250.0100.00519.21
8.3.240.0110.00918.89
8.3.230.0100.00916.89
8.3.220.0110.00719.22
8.3.210.0160.00418.65
8.3.200.0060.00316.96
8.3.190.0090.01017.40
8.3.180.0090.01016.99
8.3.170.0110.00718.98
8.3.160.0110.00018.66
8.3.150.0160.00317.12
8.3.140.0000.00919.07
8.3.130.0040.00418.66
8.3.120.0000.00819.13
8.3.110.0060.00320.94
8.3.100.0040.00424.06
8.3.90.0030.00526.77
8.3.80.0070.00319.36
8.3.70.0070.01317.13
8.3.60.0030.01917.13
8.3.50.0120.00916.70
8.3.40.0090.00619.05
8.3.30.0040.01119.01
8.3.20.0030.00624.18
8.3.10.0000.00824.66
8.3.00.0000.00826.16
8.2.290.0110.00917.52
8.2.280.0080.00218.75
8.2.270.0150.00318.95
8.2.260.0090.00918.28
8.2.250.0050.00318.67
8.2.240.0060.00318.88
8.2.230.0060.00322.58
8.2.220.0000.00837.54
8.2.210.0150.00326.77
8.2.200.0090.00018.88
8.2.190.0110.00417.00
8.2.180.0110.00725.92
8.2.170.0090.00619.29
8.2.160.0040.01122.96
8.2.150.0080.00025.66
8.2.140.0050.00324.66
8.2.130.0080.00026.16
8.2.120.0000.00819.64
8.2.110.0070.00320.56
8.2.100.0030.00619.27
8.1.330.0050.00516.58
8.1.320.0130.00616.46
8.1.310.0120.00618.81
8.1.300.0120.00318.25
8.1.290.0050.00530.84
8.1.280.0090.00625.92
8.1.270.0000.00824.10
8.1.260.0040.00426.35
8.1.250.0080.00028.09
8.1.240.0040.00719.04
8.1.230.0070.00322.13
7.3.330.0090.00119.24
7.2.340.0080.00317.89
7.2.00.0030.00518.70
5.5.380.0180.01019.93

preferences:
36.84 ms | 403 KiB | 5 Q