3v4l.org

run code in 300+ PHP versions simultaneously
<?php $foo = 'foo'; switch ($foo) { case 'foo': echo "first foo\n"; break; case 'foo': echo "second foo\n"; default: echo "first default\n"; default: echo "second default\n"; }

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)
5.6.210.0170.06320.62
5.6.200.0070.05318.18
5.6.190.0000.09020.57
5.6.180.0300.04020.56
5.6.170.0270.07720.46
5.6.160.0070.03720.38
5.6.150.0070.05318.22
5.6.140.0000.06318.17
5.6.130.0130.07318.21
5.6.120.0030.05721.02
5.6.110.0170.08021.11
5.6.100.0070.06021.06
5.6.90.0170.07721.00
5.6.80.0070.03320.28
5.6.70.4570.04320.39
5.5.350.0100.08020.37
5.5.340.0070.08318.01
5.5.330.0030.08020.57
5.5.320.0270.04020.41
5.5.310.0170.04320.31
5.5.300.0000.04018.00
5.5.290.0170.06717.98
5.5.280.0100.08020.77
5.5.270.0000.04320.86
5.5.260.0000.04720.72
5.5.250.0100.07720.68
5.5.240.3900.04320.23
5.4.450.0300.04319.21
5.4.440.0200.04719.26
5.4.430.0230.05019.09
5.4.420.0200.04319.53
5.4.410.0200.04018.99
5.4.400.0170.05318.92
5.4.390.0330.03719.13
5.4.380.0470.05318.63
5.4.370.0370.04718.50
5.4.360.0230.05318.69
5.4.350.0370.05718.67
5.4.340.0300.05018.79
5.4.320.0120.03812.45
5.4.310.0090.03712.45
5.4.300.0110.04112.45
5.4.290.0060.03912.45
5.4.280.0070.03412.34
5.4.270.0050.03712.34
5.4.260.0080.03512.34
5.4.250.0080.03612.35
5.4.240.0050.04012.35
5.4.230.0100.03412.34
5.4.220.0090.03412.34
5.4.210.0070.03412.34
5.4.200.0070.03612.34
5.4.190.0110.03112.34
5.4.180.0070.03512.33
5.4.170.0060.04212.35
5.4.160.0040.04912.34
5.4.150.0110.03812.34
5.4.140.0060.05012.02
5.4.130.0070.03712.01
5.4.120.0080.04411.97
5.4.110.0060.04311.96
5.4.100.0100.03111.96
5.4.90.0090.05011.96
5.4.80.0120.04411.96
5.4.70.0090.04311.96
5.4.60.0030.04411.96
5.4.50.0080.03411.96
5.4.40.0020.03911.95
5.4.30.0080.03311.95
5.4.20.0070.03511.95
5.4.10.0100.04111.95
5.4.00.0030.04111.43
5.3.290.0070.03812.80
5.3.280.0070.04912.71
5.3.270.0060.03912.72
5.3.260.0090.03812.71
5.3.250.0080.04412.72
5.3.240.0100.04512.72
5.3.230.0140.03612.71
5.3.220.0080.03712.68
5.3.210.0070.06012.68
5.3.200.0080.05412.68
5.3.190.0100.05212.68
5.3.180.0050.03612.68
5.3.170.0140.04512.67
5.3.160.0070.04312.68
5.3.150.0100.05012.67
5.3.140.0040.04012.66
5.3.130.0090.04612.66
5.3.120.0100.03912.66
5.3.110.0090.05112.66
5.3.100.0080.04212.11
5.3.90.0060.04012.08
5.3.80.0090.03612.08
5.3.70.0100.04012.07
5.3.60.0130.04112.06
5.3.50.0070.04212.00
5.3.40.0070.03912.00
5.3.30.0070.03711.94
5.3.20.0050.04211.72
5.3.10.0080.04011.69
5.3.00.0050.04311.67
5.2.170.0040.0349.18
5.2.160.0060.0369.18
5.2.150.0070.0359.18
5.2.140.0080.0429.17
5.2.130.0090.0309.13
5.2.120.0060.0279.13
5.2.110.0030.0419.14
5.2.100.0050.0359.14
5.2.90.0080.0269.14
5.2.80.0070.0289.14
5.2.70.0060.0359.14
5.2.60.0080.0389.09
5.2.50.0080.0289.05
5.2.40.0080.0399.03
5.2.30.0070.0369.01
5.2.20.0040.0458.99
5.2.10.0090.0308.92
5.2.00.0060.0378.77
5.1.60.0040.0258.06
5.1.50.0120.0238.06
5.1.40.0060.0278.04
5.1.30.0040.0268.39
5.1.20.0030.0398.41
5.1.10.0050.0338.13
5.1.00.0020.0308.14
5.0.50.0070.0306.62
5.0.40.0080.0266.47
5.0.30.0040.0406.29
5.0.20.0070.0156.26
5.0.10.0040.0196.23
5.0.00.0030.0316.23
4.4.90.0030.0174.77
4.4.80.0050.0154.75
4.4.70.0040.0254.75
4.4.60.0020.0164.76
4.4.50.0040.0194.77
4.4.40.0050.0344.71
4.4.30.0030.0174.76
4.4.20.0050.0214.84
4.4.10.0020.0174.85
4.4.00.0060.0274.76
4.3.110.0040.0274.67
4.3.100.0040.0204.66
4.3.90.0040.0144.63
4.3.80.0020.0254.58
4.3.70.0020.0184.63
4.3.60.0030.0234.63
4.3.50.0020.0204.63
4.3.40.0050.0384.54
4.3.30.0020.0173.29
4.3.20.0010.0293.27
4.3.10.0020.0223.23
4.3.00.0070.01315.90

preferences:
136.97 ms | 1394 KiB | 7 Q