3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $val = 12; $bin_val = 1 << ($val -1); var_dump($bin_val); var_dump(pow(2, $val)); $val = 1 >> ($val - 1); var_dump($val);
based on vHlpi

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.2.60.0060.00616.85
7.2.00.0030.00919.03
7.1.200.0090.00615.79
7.1.100.0060.00617.90
7.1.70.0060.00317.13
7.1.60.0130.01019.32
7.1.50.0070.01416.61
7.1.00.0070.07322.48
7.0.200.0000.00916.48
7.0.140.0130.06322.11
7.0.70.3770.03719.91
7.0.60.0070.07719.98
7.0.50.0070.06017.88
7.0.40.0130.03720.23
7.0.30.0230.04720.04
7.0.20.0370.06720.18
7.0.10.0170.04720.18
7.0.00.0070.08320.01
5.6.280.0070.07020.98
5.6.210.0070.05020.71
5.6.200.0070.08018.19
5.6.190.0000.06720.63
5.6.180.0030.04320.36
5.6.170.0300.07020.38
5.6.160.0100.08020.70
5.6.150.0070.08318.11
5.6.140.0030.08718.11
5.6.130.0100.08018.11
5.6.120.0100.08021.08
5.6.110.0130.08021.14
5.6.100.0070.06720.97
5.6.90.0070.05720.98
5.6.80.0100.07720.52
5.6.70.0300.06320.52
5.5.350.0030.07720.31
5.5.340.0070.05018.03
5.5.330.0130.05020.47
5.5.320.0070.03720.57
5.5.310.0400.07020.17
5.5.300.0030.04717.88
5.5.290.0070.08717.95
5.5.280.0100.08020.75
5.5.270.0100.06720.71
5.5.260.0170.02720.96
5.5.250.0100.06020.68
5.5.240.0030.07320.25
5.4.450.0500.03319.46
5.4.440.0970.06019.60
5.4.430.0200.04319.41
5.4.420.0670.00019.25
5.4.410.0630.00019.31
5.4.400.0630.00019.18
5.4.390.0630.00019.26
5.4.380.0230.06718.59
5.4.370.0300.06318.53
5.4.360.0470.06318.69
5.4.350.0500.06318.57
5.4.340.0400.07018.70
5.4.320.0070.03812.45
5.4.310.0070.03812.45
5.4.300.0090.04212.45
5.4.290.0070.03712.45
5.4.280.0070.04012.35
5.4.270.0060.04112.35
5.4.260.0050.03812.35
5.4.250.0080.03612.34
5.4.240.0050.03912.34
5.4.230.0090.04412.34
5.4.220.0080.03412.34
5.4.210.0060.03712.34
5.4.200.0040.03912.34
5.4.190.0070.03912.34
5.4.180.0090.03712.34
5.4.170.0120.04212.35
5.4.160.0070.03412.34
5.4.150.0050.03712.34
5.4.140.0030.03912.02
5.4.130.0100.03612.01
5.4.120.0090.03611.97
5.4.110.0060.03911.96
5.4.100.0090.03511.96
5.4.90.0040.04011.96
5.4.80.0030.04011.96
5.4.70.0100.03511.96
5.4.60.0060.04011.96
5.4.50.0080.03311.96
5.4.40.0110.03711.95
5.4.30.0090.04011.95
5.4.20.0080.03711.95
5.4.10.0030.03711.95
5.4.00.0100.03111.44
5.3.290.0050.04212.80
5.3.280.0110.04412.71
5.3.270.0070.04512.73
5.3.260.0080.03612.72
5.3.250.0110.03812.72
5.3.240.0070.03612.72
5.3.230.0030.04012.71
5.3.220.0060.03612.68
5.3.210.0070.04612.68
5.3.200.0100.03612.68
5.3.190.0080.03512.68
5.3.180.0080.04812.68
5.3.170.0090.03912.67
5.3.160.0060.03712.68
5.3.150.0070.03512.68
5.3.140.0050.04112.66
5.3.130.0110.03312.66
5.3.120.0070.03812.66
5.3.110.0060.03812.66
5.3.100.0060.04812.12
5.3.90.0070.03412.08
5.3.80.0070.03912.08
5.3.70.0050.03812.07
5.3.60.0050.03612.07
5.3.50.0070.03412.00
5.3.40.0070.03512.00
5.3.30.0040.03711.94
5.3.20.0090.03211.72
5.3.10.0060.03411.69
5.3.00.0120.03011.68
5.2.170.0050.0309.18
5.2.160.0030.0319.18
5.2.150.0050.0329.18
5.2.140.0040.0319.18
5.2.130.0030.0309.13
5.2.120.0020.0309.13
5.2.110.0040.0299.14
5.2.100.0070.0279.14
5.2.90.0030.0319.14
5.2.80.0040.0339.14
5.2.70.0020.0339.14
5.2.60.0030.0329.09
5.2.50.0040.0309.05
5.2.40.0040.0299.03
5.2.30.0020.0329.01
5.2.20.0050.0288.99
5.2.10.0050.0278.92
5.2.00.0060.0278.78
5.1.60.0040.0238.06
5.1.50.0050.0238.06
5.1.40.0040.0258.04
5.1.30.0040.0278.39
5.1.20.0040.0268.41
5.1.10.0030.0278.13
5.1.00.0060.0248.13
5.0.50.0040.0196.62
5.0.40.0010.0216.47
5.0.30.0060.0286.29
5.0.20.0040.0186.26
5.0.10.0060.0176.23
5.0.00.0020.0316.22
4.4.90.0040.0144.78
4.4.80.0030.0154.75
4.4.70.0030.0174.75
4.4.60.0040.0154.75
4.4.50.0040.0144.77
4.4.40.0050.0224.71
4.4.30.0030.0154.76
4.4.20.0050.0134.84
4.4.10.0050.0134.85
4.4.00.0040.0244.75
4.3.110.0020.0164.67
4.3.100.0050.0124.66
4.3.90.0020.0184.63
4.3.80.0010.0254.58
4.3.70.0050.0124.63
4.3.60.0030.0144.63
4.3.50.0030.0154.63
4.3.40.0030.0234.54
4.3.30.0060.0113.32
4.3.20.0030.0153.30
4.3.10.0060.0133.25
4.3.00.0030.02016.39