3v4l.org

run code in 200+ php & hhvm versions
<?php function base64_encode_url($string) { return str_replace(['+','/','='], ['-','_',''], base64_encode($string)); } function base64_decode_url($string) { return base64_decode(str_replace(['-','_'], ['+','/'], $string)); } for ($i=0; $i<20000; $i++) { $data = random_bytes(rand(12,20)); if (base64_decode_url(base64_encode($data)) !== $data) { echo "FAIL"; } } echo "OK";
based on 9TR6J

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).
Note: hhvm uses a JIT which only kicks in after a few runs. Since we run scripts only once, hhvm always runs slower.

VersionSystem time (s)User time (s)Memory (MiB)
7.4.0alpha10.0310.03014.97
7.3.60.0320.01414.78
7.3.50.0290.02914.82
7.3.40.0240.03414.83
7.3.30.0250.03514.63
7.3.20.0510.01614.83
7.3.10.0650.02814.68
7.3.00.0850.02214.67
7.2.190.0280.02114.96
7.2.180.0290.02515.08
7.2.170.0390.03015.05
7.2.160.0330.02015.03
7.2.150.0320.03915.01
7.2.140.0340.02415.22
7.2.130.0800.02715.03
7.2.120.0950.02715.12
7.2.110.0600.03114.98
7.2.100.2180.02514.80
7.2.90.1790.02714.87
7.2.80.1700.03114.80
7.2.70.1560.03014.95
7.2.60.1600.02714.96
7.2.50.1600.02614.92
7.2.40.1460.03614.93
7.2.30.1530.03215.05
7.2.20.1360.03215.00
7.2.10.1350.03315.02
7.2.00.1400.03315.02
7.1.300.0480.02214.04
7.1.290.0500.01814.06
7.1.280.0390.02614.06
7.1.270.0410.03113.90
7.1.260.0350.02814.09
7.1.250.0900.03013.88
7.1.240.0650.04113.92
7.1.230.0830.03613.86
7.1.220.1080.03613.84
7.1.210.1940.03013.90
7.1.200.1940.03313.73
7.1.190.1600.03213.88
7.1.180.1610.03113.86
7.1.170.1710.03413.82
7.1.160.1460.03713.90
7.1.150.1530.03513.72
7.1.140.1390.03913.82
7.1.130.1570.03713.88
7.1.120.1260.03913.88
7.1.110.1570.03613.88
7.1.100.1380.03713.85
7.1.90.1340.03413.88
7.1.80.1510.03613.84
7.1.70.1340.02913.79
7.1.60.1090.03222.63
7.1.50.1230.03522.60
7.1.40.1200.03322.77
7.1.30.1220.03522.76
7.1.20.1120.03222.77
7.1.10.1010.03313.71
7.1.00.1000.03613.75
7.0.330.1030.03413.51
7.0.310.2600.04113.54
7.0.300.2490.04813.59
7.0.290.2910.03213.60
7.0.280.2100.03613.45
7.0.270.2560.03613.66
7.0.260.2580.04813.39
7.0.250.2480.03613.64
7.0.240.2160.05213.72
7.0.230.1940.04113.70
7.0.220.2180.04013.52
7.0.210.1500.03013.61
7.0.200.1320.04313.49
7.0.190.1510.04813.46
7.0.180.1260.03913.59
7.0.170.1420.04413.62
7.0.160.1250.03913.53
7.0.150.1090.03813.43
7.0.140.1070.02513.39
7.0.130.1110.03913.62
7.0.120.1940.03713.66
7.0.110.1120.03013.61
7.0.100.1110.03913.55
7.0.90.1080.03713.35
7.0.80.1230.03113.43
7.0.70.1080.03513.59
7.0.60.1210.04113.41
7.0.50.1120.04213.53
7.0.40.0710.04713.68
7.0.30.1050.04213.60
7.0.20.1210.04213.69
7.0.10.0710.04413.47
7.0.00.0660.04213.41
hhvm-3.22.00.1240.20790.49
hhvm-3.21.30.1070.20890.00
hhvm-3.21.00.1360.21390.29
hhvm-3.20.20.1000.23390.53
hhvm-3.19.20.1370.21389.40
hhvm-3.18.50.1080.20488.33
hhvm-3.18.40.1330.20588.24
hhvm-3.17.30.1070.21387.27
hhvm-3.15.40.1170.17485.21
hhvm-3.13.20.1160.19596.54
hhvm-3.12.140.1140.23295.34
hhvm-3.11.10.1150.20487.63
hhvm-3.10.10.1130.17284.95
5.6.400.0130.01314.05
5.6.390.0140.00414.20
5.6.380.0100.01014.02
5.6.370.0130.00814.19
5.6.360.0120.00914.14
5.6.350.0110.01114.17
5.6.340.0110.01214.30
5.6.330.0120.01014.22
5.6.320.0150.00514.08
5.6.310.0110.00914.35
5.6.300.0110.01014.11
5.6.290.0090.01014.27
5.6.280.0120.00914.23
5.6.270.0110.01114.06
5.6.260.0080.01213.94
5.6.250.0160.00514.16
5.6.240.0140.00614.23
5.6.230.0090.01214.38
5.6.220.0120.01014.08
5.6.210.0120.00814.05
5.6.200.0120.01114.11
5.6.190.0200.00214.12
5.6.180.0150.00714.25
5.6.170.0130.00914.19
5.6.160.0170.00314.29
5.6.150.0170.00314.08
5.6.140.0210.00014.03
5.6.130.0120.00614.22
5.6.120.0170.00314.32
5.6.110.0130.00714.20
5.6.100.0160.00514.19
5.6.90.0130.00514.12
5.6.80.0180.00414.12
5.6.70.0120.00814.04
5.6.60.0130.00714.05
5.6.50.0090.01014.27
5.6.40.0090.01114.22
5.6.30.0160.00414.01
5.6.20.0070.01314.02
5.6.10.0120.00814.22
5.6.00.0140.00714.07
5.5.380.0110.00510.95
5.5.370.0100.00511.08
5.5.360.0120.00511.03
5.5.350.0100.00510.85
5.5.340.0060.00811.22
5.5.330.0100.00610.99
5.5.320.0040.01111.11
5.5.310.0070.00910.97
5.5.300.0100.00511.21
5.5.290.0090.00711.18
5.5.280.0110.00311.08
5.5.270.0120.00211.02
5.5.260.0060.01111.09
5.5.250.0030.01011.12
5.5.240.0060.01010.94
5.5.230.0050.00911.09
5.5.220.0070.00911.05
5.5.210.0070.00711.11
5.5.200.0100.00411.06
5.5.190.0100.00411.01
5.5.180.0120.00310.91
5.5.170.0120.00913.99
5.5.160.0110.00311.08
5.5.150.0070.00711.08
5.5.140.0100.00410.97
5.5.130.0090.00510.94
5.5.120.0120.00110.98
5.5.110.0080.00810.87
5.5.100.0090.00311.09
5.5.90.0110.00511.08
5.5.80.0120.00310.95
5.5.70.0100.00511.11
5.5.60.0120.00510.98
5.5.50.0070.00811.03
5.5.40.0140.00510.94
5.5.30.0040.01110.95
5.5.20.0190.00711.05
5.5.10.0110.00411.07
5.5.00.0080.00811.05
5.4.450.0100.00411.06
5.4.440.0140.00010.90
5.4.430.0110.00511.14
5.4.420.0080.00711.02
5.4.410.0100.00610.88
5.4.400.0070.00710.93
5.4.390.0050.00911.03
5.4.380.0150.00910.97
5.4.370.0160.00210.91
5.4.360.0090.00611.04
5.4.350.0070.00810.97
5.4.340.0060.00611.01
5.4.330.0090.00411.02
5.4.320.0100.00410.84
5.4.310.0080.00711.03
5.4.300.0120.00311.00
5.4.290.0060.00811.05
5.4.280.0110.00410.90
5.4.270.0120.00110.82
5.4.260.0090.00610.90
5.4.250.0120.00310.85
5.4.240.0090.00510.94
5.4.230.0150.00111.04
5.4.220.0150.00010.84
5.4.210.0130.00210.84
5.4.200.0140.00111.08
5.4.190.0090.00610.83
5.4.180.0070.00811.04
5.4.170.0060.00910.94
5.4.160.0080.00611.06
5.4.150.0070.00910.95
5.4.140.0080.00710.88
5.4.130.0120.00310.89
5.4.120.0100.00411.03
5.4.110.0090.00511.00
5.4.100.0070.00910.99
5.4.90.0080.00511.00
5.4.80.0100.00411.08
5.4.70.0110.00311.02
5.4.60.0060.00711.01
5.4.50.0090.00511.08
5.4.40.0090.00611.07
5.4.30.0110.00511.05
5.4.20.0090.00610.96
5.4.10.0090.00411.02
5.4.00.0080.00711.03
5.3.290.0100.00410.56
5.3.280.0070.00710.53
5.3.270.0180.00210.59
5.3.260.0070.00410.65
5.3.250.0110.00310.65
5.3.240.0080.00510.56
5.3.230.0070.00710.62
5.3.220.0080.00510.67
5.3.210.0090.00510.67
5.3.200.0090.00510.67
5.3.190.0110.00310.57
5.3.180.0060.00710.77
5.3.170.0080.00610.72
5.3.160.0030.01010.76
5.3.150.0100.00310.72
5.3.140.0080.00410.73
5.3.130.0030.01110.68
5.3.120.0070.00610.68
5.3.110.0080.00410.59
5.3.100.0130.00010.57
5.3.90.0100.00310.72
5.3.80.0080.00710.67
5.3.70.0080.00810.53
5.3.60.0080.00610.61
5.3.50.0100.00310.65
5.3.40.0060.00910.66
5.3.30.0110.00210.63
5.3.20.0050.00910.63
5.3.10.0080.00510.54
5.3.00.0060.00710.57
5.2.170.0040.00610.34
5.2.160.0090.00310.34
5.2.150.0050.00610.34
5.2.140.0070.00410.34
5.2.130.0090.00410.34
5.2.120.0070.00310.34
5.2.110.0060.00510.34
5.2.100.0020.01010.34
5.2.90.0080.00410.34
5.2.80.0070.00410.34
5.2.70.0010.01110.34
5.2.60.0110.00210.34
5.2.50.0060.00510.34
5.2.40.0050.00710.34
5.2.30.0080.00410.34
5.2.20.0070.00310.34
5.2.10.0070.00310.34
5.2.00.0060.00310.34
5.1.60.0030.00510.34
5.1.50.0050.00610.34
5.1.40.0070.00210.34
5.1.30.0070.00310.34
5.1.20.0030.00610.34
5.1.10.0020.00610.34
5.1.00.0070.00310.34
5.0.50.0080.00210.34
5.0.40.0070.00110.34
5.0.30.0050.00210.34
5.0.20.0060.00310.34
5.0.10.0030.00510.34
5.0.00.0080.00010.34
4.4.90.0050.00310.34
4.4.80.0010.00510.34
4.4.70.0000.00710.34
4.4.60.0030.00310.34
4.4.50.0050.00210.34
4.4.40.0060.00210.34
4.4.30.0040.00410.34
4.4.20.0040.00410.34
4.4.10.0040.00310.34
4.4.00.0020.00610.34
4.3.110.0050.00110.34
4.3.100.0060.00110.34
4.3.90.0060.00110.34
4.3.80.0060.00210.34
4.3.70.0050.00210.34
4.3.60.0040.00310.34
4.3.50.0030.00510.34
4.3.40.0010.00710.34
4.3.30.0030.00510.34
4.3.20.0030.00310.34
4.3.10.0020.00310.34
4.3.00.0040.00210.34