3v4l.org

run code in 300+ PHP versions simultaneously
<?php for($i=1;$i<1001;$i*=10) { $starttime=round( microtime(TRUE)*$i); $now= shortenb64($starttime); $len=strlen($now); $min= str_repeat("0", $len); $max= str_repeat("z", $len); $nowtime=date("Y-m-d H:i:s", $nowS=epxandb64($now)/$i); $minS=epxandb64($min)/$i; $maxS=epxandb64($max)/$i; $minYear = 1970+($minS/ (60*60*24*365.25)); $maxYear = 1970+($maxS/ (60*60*24*365.25)); echo "$i \t $starttime \t $now ($nowtime): \t min year ($minYear) \t max year ($maxYear)\n"; } function shortenb64($id, $alphabet='-0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz') { $base = strlen($alphabet); $short = ''; while($id) { $id = ($id-($r=$id%$base))/$base; $short = $alphabet{$r} . $short; } return $short; } function epxandb64($id, $alphabet='-0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz') { $base = strlen($alphabet); $len = strlen($id)-1; $long = 0.0; $mul=1; for($i=$len;$i>=0;$i--) { $long += strpos($alphabet, substr($id, $i,1))*$mul; $mul *= $base; } return $long; }

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.2.00.0000.01319.46
7.1.70.0040.00817.46
7.1.60.0130.01019.17
7.1.50.0140.01017.15
7.1.00.0000.06022.37
7.0.200.0070.00716.73
7.0.140.0030.07722.08
7.0.90.0070.04019.90
7.0.80.0030.04320.09
7.0.70.0230.03719.94
7.0.60.0070.03319.89
7.0.50.0230.06020.22
7.0.40.0030.04320.08
7.0.30.0030.04320.05
7.0.20.0030.04319.95
7.0.10.0030.04320.05
7.0.00.0100.03320.08
5.6.280.0030.07321.16
5.6.240.0100.03320.59
5.6.230.0030.05720.63
5.6.220.0030.05020.45
5.6.210.0070.04720.52
5.6.200.0100.03721.04
5.6.190.0030.04021.09
5.6.180.0070.04021.11
5.6.170.0070.04021.13
5.6.160.0030.04721.12
5.6.150.0070.04020.96
5.6.140.0070.04021.07
5.6.130.0030.04721.05
5.6.120.0030.04321.05
5.6.110.0000.04721.11
5.6.100.0030.06021.03
5.6.90.0030.03720.95
5.6.80.0000.03720.33
5.6.70.0000.03720.42
5.6.60.0070.03720.55
5.6.50.0000.04020.46
5.6.40.0030.04020.41
5.6.30.0070.03020.33
5.6.20.0070.03020.38
5.6.10.0070.03020.44
5.6.00.0070.03020.39
5.5.380.0030.04320.36
5.5.370.0030.03720.27
5.5.360.0070.03720.32
5.5.350.0100.06320.41
5.5.340.0100.07320.82
5.5.330.0070.04720.94
5.5.320.0000.04720.75
5.5.310.0030.04320.89
5.5.300.0070.04320.81
5.5.290.0100.03320.84
5.5.280.0030.03720.84
5.5.270.0030.03720.80
5.5.260.0070.04320.78
5.5.250.0070.03720.59
5.5.240.0030.04020.22
5.5.230.0070.03020.26
5.5.220.0070.03020.21
5.5.210.0070.03720.13
5.5.200.0030.03320.26
5.5.190.0100.02720.23
5.5.180.0030.04320.27
5.5.160.0030.04020.29
5.5.150.0100.03020.28
5.5.140.0070.03020.14
5.5.130.0000.04020.17
5.5.120.0070.03020.13
5.5.110.0070.03320.24
5.5.100.0070.03720.17
5.5.90.0030.03320.04
5.5.80.0030.03320.05
5.5.70.0000.04020.16
5.5.60.0030.03020.13
5.5.50.0070.03019.95
5.5.40.0000.05020.16
5.5.30.0070.05720.11
5.5.20.0170.06720.01
5.5.10.0000.06020.09
5.5.00.0000.05020.00
5.4.450.0100.03019.54
5.4.440.0000.04719.23
5.4.430.0030.03719.58
5.4.420.0030.04319.23
5.4.410.0000.03719.45
5.4.400.0030.04019.09
5.4.390.0000.04019.03
5.4.380.0100.03019.11
5.4.370.0030.03319.12
5.4.360.0030.03719.18
5.4.350.0030.03018.91
5.4.340.0030.04019.22
5.4.320.0000.03319.07
5.4.310.0070.03019.21
5.4.300.0030.04719.08
5.4.290.0070.03318.99
5.4.280.0100.02719.13
5.4.270.0030.03719.27
5.4.260.0000.03319.26
5.4.250.0070.03719.08
5.4.240.0070.03019.25
5.4.230.0030.03719.17
5.4.220.0100.02718.94
5.4.210.0070.03719.07
5.4.200.0100.02719.20
5.4.190.0000.03719.11
5.4.180.0200.06318.93
5.4.170.0100.07318.93
5.4.160.0000.07719.09
5.4.150.0100.07319.16
5.4.140.0030.04716.25
5.4.130.0030.08016.41
5.4.120.0030.05016.50
5.4.110.0100.07716.54
5.4.100.0130.04316.50
5.4.90.0030.08016.58
5.4.80.0030.07316.54
5.4.70.0070.03716.39
5.4.60.0030.05316.47
5.4.50.0070.05016.42
5.4.40.0130.06716.51
5.4.30.0200.05716.43
5.4.20.0000.08016.45
5.4.10.0070.07316.28
5.4.00.0170.06315.73
5.3.290.0100.02714.67
5.3.280.0030.04314.63
5.3.270.0100.06014.74
5.3.260.0070.04314.62
5.3.250.0030.04314.76
5.3.240.0070.08014.63
5.3.230.0000.07714.61
5.3.220.0100.04014.72
5.3.210.0030.06314.60
5.3.200.0070.04314.72
5.3.190.0000.06014.74
5.3.180.0100.06314.60
5.3.170.0030.08014.59
5.3.160.0070.06314.70
5.3.150.0270.05014.70
5.3.140.0100.06714.55
5.3.130.0070.07014.55
5.3.120.0130.07014.57
5.3.110.0070.07014.60
5.3.100.0030.07314.07
5.3.90.0130.06714.16
5.3.80.0070.07714.15
5.3.70.0170.03314.16
5.3.60.0130.06014.08
5.3.50.0030.07313.89
5.3.40.0130.07714.02
5.3.30.0030.04013.90
5.3.20.0100.03313.76
5.3.10.0100.06313.79
5.3.00.0070.05013.77
5.2.170.0030.04311.16
5.2.160.0030.05711.15
5.2.150.0100.05711.25
5.2.140.0000.04011.39
5.2.130.0070.04711.34
5.2.120.0030.04711.42
5.2.110.0070.05711.36
5.2.100.0030.03011.36
5.2.90.0100.02711.35
5.2.80.0030.06711.13
5.2.70.0100.05311.16
5.2.60.0000.07011.28
5.2.50.0070.06011.16
5.2.40.0070.06711.14
5.2.30.0000.05711.23
5.2.20.0100.03711.21
5.2.10.0100.06010.93
5.2.00.0070.05710.97
5.1.60.0070.05010.30
5.1.50.0100.04310.30
5.1.40.0000.05710.30
5.1.30.0070.05310.48
5.1.20.0130.03010.45
5.1.10.0070.02310.30
5.1.00.0000.03010.30
5.0.50.0030.05010.30
5.0.40.0030.03310.30
5.0.30.0100.05310.30
5.0.20.0000.04310.30
5.0.10.0000.04710.30
5.0.00.0030.05710.30
4.4.90.0030.03310.30
4.4.80.0000.03710.30
4.4.70.0030.03710.30
4.4.60.0000.03010.30
4.4.50.0030.02710.30
4.4.40.0000.05010.30
4.4.30.0000.02010.30
4.4.20.0100.03710.30
4.4.10.0000.02310.30
4.4.00.0000.02710.30
4.3.110.0000.01710.30
4.3.100.0030.03010.30
4.3.90.0030.01710.30
4.3.80.0000.02710.30
4.3.70.0030.02010.30
4.3.60.0030.01310.30
4.3.50.0030.03010.30
4.3.40.0000.03710.30
4.3.30.0030.03710.30
4.3.20.0000.03010.30
4.3.10.0030.02310.30
4.3.00.0000.04010.30

preferences:
44.15 ms | 401 KiB | 5 Q