3v4l.org

run code in 300+ PHP versions simultaneously
<?php function ved_decode($ved) { /* // Copyright 2013 Deed Poll Office Ltd, UK <https://deedpolloffice.com> // Licensed under Apache Licence v2.0 <http://apache.org/licenses/LICENSE-2.0> $keys = array('t' => 2, 'r' => 6, 's' => 7, 'i' => 1); $ret = array(); if (substr($ved, 0, 1) == '1') { preg_match_all('/([a-z]+):([0-9]+)/i', $ved, $matches, PREG_SET_ORDER); foreach ($matches as $m) $ret[isset($keys[$m[1]]) ? $keys[$m[1]] : $m[1]] = (int) $m[2]; return $ret; } */ preg_match_all('/([\x80-\xff]*[\0-\x7f])([\x80-\xff]*[\0-\x7f])/', base64_decode(str_replace(array('_','-'), array('+','/'), substr($ved, 1))), $matches, PREG_SET_ORDER); foreach ($matches as $m) { var_dump($m); $key = $val = 0; foreach (str_split($m[1]) as $i => $c) $key += (ord($c) & 0x7f) << $i * 7; foreach (str_split($m[2]) as $i => $c) $val += (ord($c) & 0x7f) << $i * 7; $ret[$key >> 3] = $val; } return $ret; } // Example of use: print_r(ved_decode('ahUKEwiHlMTro9_bAhVEtxQKHbTpDKAQFgiIAjAL'));

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.0090.00916.75
8.3.50.0230.00018.31
8.3.40.0160.00019.08
8.3.30.0070.00718.93
8.3.20.0060.00319.07
8.3.10.0050.00321.10
8.3.00.0030.00623.53
8.2.180.0120.00917.00
8.2.170.0120.00322.96
8.2.160.0070.00720.52
8.2.150.0030.00624.18
8.2.140.0080.00024.66
8.2.130.0090.00019.85
8.2.120.0080.00026.35
8.2.110.0130.00722.27
8.2.100.0080.00318.03
8.2.90.0000.00818.09
8.2.80.0000.00817.97
8.2.70.0000.00818.05
8.2.60.0040.00418.16
8.2.50.0050.00318.10
8.2.40.0050.00319.51
8.2.30.0050.00319.53
8.2.20.0030.00518.11
8.2.10.0040.00418.21
8.2.00.0000.00819.51
8.1.280.0090.00925.92
8.1.270.0040.00422.02
8.1.260.0000.00826.35
8.1.250.0030.00528.09
8.1.240.0030.00622.14
8.1.230.0070.00722.21
8.1.220.0080.00017.79
8.1.210.0080.00018.91
8.1.200.0060.00317.48
8.1.190.0030.00517.47
8.1.180.0000.00818.10
8.1.170.0040.00418.63
8.1.160.0040.00418.79
8.1.150.0000.00718.79
8.1.140.0000.00717.64
8.1.130.0000.00819.00
8.1.120.0050.00317.59
8.1.110.0040.00417.54
8.1.100.0000.01017.68
8.1.90.0030.00717.55
8.1.80.0050.00317.63
8.1.70.0030.00617.57
8.1.60.0000.00817.75
8.1.50.0000.00817.63
8.1.40.0050.00317.61
8.1.30.0040.00717.74
8.1.20.0000.00717.68
8.1.10.0050.00317.74
8.1.00.0040.00417.64
8.0.300.0030.00519.92
8.0.290.0030.00516.88
8.0.280.0040.00418.41
8.0.270.0000.00717.19
8.0.260.0030.00317.28
8.0.250.0030.00317.11
8.0.240.0030.00517.09
8.0.230.0080.00016.96
8.0.220.0070.00317.05
8.0.210.0000.00816.95
8.0.200.0030.00316.99
8.0.190.0000.00717.09
8.0.180.0030.00616.95
8.0.170.0030.00716.96
8.0.160.0020.00517.04
8.0.150.0000.00716.87
8.0.140.0000.00817.06
8.0.130.0060.00013.48
8.0.120.0050.00316.91
8.0.110.0000.00817.02
8.0.100.0050.00316.91
8.0.90.0040.00417.02
8.0.80.0080.01317.01
8.0.70.0080.00016.86
8.0.60.0000.00817.09
8.0.50.0050.00316.88
8.0.30.0090.01217.22
8.0.20.0120.00817.44
8.0.10.0040.00417.16
8.0.00.0130.00917.00
7.4.330.0000.00515.55
7.4.320.0000.00616.70
7.4.300.0000.00616.72
7.4.290.0040.00416.70
7.4.280.0070.00416.71
7.4.270.0070.00316.71
7.4.260.0040.00416.59
7.4.250.0050.00316.67
7.4.240.0040.00416.77
7.4.230.0000.00716.82
7.4.220.0080.00016.53
7.4.210.0030.01216.73
7.4.200.0000.00716.48
7.4.160.0100.00716.87
7.4.140.0140.00817.86
7.4.130.0070.01116.53
7.4.120.0140.00616.59
7.4.110.0110.00816.54
7.4.100.0130.00316.71
7.4.90.0140.00416.54
7.4.80.0030.01619.39
7.4.70.0120.00616.69
7.4.60.0070.01016.66
7.4.50.0040.00716.54
7.4.40.0080.01016.57
7.3.330.0030.00313.52
7.3.320.0060.00013.51
7.3.310.0000.00716.62
7.3.300.0030.00316.48
7.3.290.0070.00016.46
7.3.280.0090.01216.45
7.3.260.0090.01116.75
7.3.240.0100.01216.58
7.3.230.0150.00416.58
7.3.210.0040.01516.57
7.3.200.0150.00616.70
7.3.190.0030.01416.77
7.3.180.0120.00516.80
7.3.170.0080.01516.85
7.3.160.0060.01116.49
7.2.330.0070.01316.90
7.2.320.0150.00516.95
7.2.310.0170.00316.95
7.2.300.0120.00616.86
7.2.290.0090.01617.00

preferences:
57.46 ms | 401 KiB | 5 Q