3v4l.org

run code in 500+ PHP versions simultaneously
<?php $urls = ['document/âne', 'ドキュメント/ウィスキー', '/документ/водка', '/etc/ôöœt', '/etc/', 'etc/fstab', 'etc/', '/fstab', 'fstab']; $format = "%-25s %-20s %s\n"; printf($format, '$url', 'basename($url)', 'substr(strrchr("/$url", "/"), 1)'); echo str_repeat('-', 80), PHP_EOL; foreach ($urls as $url) { printf($format, $url, fix_offset($url) .basename($url), fix_offset(basename($url)).substr(strrchr("/$url", '/'), 1)); } function fix_offset($str) { return str_repeat(' ', strlen($str) - mb_strlen($str)); }

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.5.80.0130.00516.62
8.5.70.0080.00816.72
8.5.60.0120.00716.71
8.5.50.0080.00918.16
8.5.30.0080.00921.42
8.5.20.0110.00820.15
8.5.10.0060.01319.49
8.5.00.0150.00920.09
8.4.230.0090.00519.57
8.4.220.0120.01019.43
8.4.210.0080.01021.23
8.4.180.0150.00819.66
8.4.170.0110.01023.82
8.4.160.0100.01123.69
8.4.150.0090.00416.74
8.4.140.0120.00917.53
8.4.130.0060.00517.87
8.4.120.0030.00720.53
8.4.110.0080.00222.50
8.4.100.0140.00617.50
8.4.90.0150.00418.75
8.4.80.0050.00317.56
8.4.70.0150.00517.62
8.4.60.0120.00820.52
8.4.50.0130.00719.51
8.4.40.0080.01217.46
8.4.30.0080.00020.39
8.4.20.0140.00717.63
8.4.10.0120.00924.07
8.3.320.0100.01018.30
8.3.310.0090.00418.45
8.3.300.0080.01318.30
8.3.290.0150.00720.93
8.3.280.0070.00516.15
8.3.270.0140.00616.64
8.3.260.0070.00916.54
8.3.250.0130.00618.85
8.3.240.0080.01116.65
8.3.230.0130.00816.57
8.3.220.0110.00817.02
8.3.210.0120.00716.49
8.3.200.0110.00816.58
8.3.190.0090.00917.11
8.3.180.0120.01016.51
8.3.170.0110.00316.96
8.3.160.0130.00616.49
8.3.150.0150.00420.74
8.3.140.0070.00717.24
8.3.130.0070.00318.34
8.3.120.0090.00020.64
8.3.110.0030.00618.28
8.3.100.0090.00616.54
8.3.90.0100.01018.29
8.3.80.0060.00318.18
8.3.70.0180.00416.38
8.3.60.0140.00716.62
8.3.50.0090.00616.62
8.3.40.0110.00420.21
8.3.30.0070.00720.35
8.3.20.0050.00324.18
8.3.10.0040.00424.66
8.3.00.0040.00426.16
8.2.320.0120.00718.12
8.2.310.0130.00518.02
8.2.300.0100.01018.25
8.2.290.0120.00820.48
8.2.280.0070.00318.13
8.2.270.0080.00017.20
8.2.260.0150.00418.67
8.2.250.0070.01317.11
8.2.240.0090.00017.05
8.2.230.0150.00420.94
8.2.220.0060.00324.06
8.2.210.0140.00426.77
8.2.200.0030.00616.63
8.2.190.0110.00416.75
8.2.180.0140.00716.38
8.2.170.0150.00018.87
8.2.160.0110.00322.96
8.2.150.0060.00325.66
8.2.140.0080.00024.66
8.2.130.0040.00426.16
8.2.120.0000.00721.05
8.2.110.0030.00622.25
8.2.100.0040.00420.31
8.2.70.0080.00717.61
8.1.340.0120.00817.74
8.1.330.0090.00822.09
8.1.320.0130.00716.21
8.1.310.0050.00516.43
8.1.300.0090.00616.27
8.1.290.0060.00318.88
8.1.280.0130.00625.92
8.1.270.0040.00424.66
8.1.260.0040.00426.35
8.1.250.0080.00028.09
8.1.240.0030.00618.62
8.1.230.0040.00718.58
7.4.330.0080.00317.61
5.4.160.0040.00417.61
5.3.30.0030.00517.61

preferences:
47.08 ms | 974 KiB | 5 Q