3v4l.org

run code in 300+ PHP versions simultaneously
<?php $foo = 'foo'; switch ($foo) { case 'foo': echo "first foo\n"; break; case 'bar': echo "second foo\n"; break; 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.280.0000.07720.91
5.6.210.0100.08020.75
5.6.200.0170.05018.12
5.6.190.0170.07020.41
5.6.180.0330.07720.41
5.6.170.0230.05720.33
5.6.160.0070.04020.50
5.6.150.0070.06018.12
5.6.140.0030.06318.23
5.6.130.0070.08018.07
5.6.120.0000.04721.14
5.6.110.0030.08321.11
5.6.100.0000.04320.88
5.6.90.0030.08321.09
5.6.80.0100.08020.37
5.5.350.0230.07720.46
5.5.340.0030.04017.92
5.5.330.0030.04020.11
5.5.320.0030.05720.34
5.5.310.0370.07320.41
5.5.300.0070.04017.98
5.5.290.0100.07717.98
5.5.280.0030.04020.80
5.5.270.0000.04720.89
5.5.260.0100.06320.84
5.5.250.0070.06020.53
5.5.240.0000.08020.25
5.4.450.0200.05719.21
5.4.440.0270.06319.44
5.4.430.0270.03719.41
5.4.420.0230.03719.15
5.4.410.0300.04019.27
5.4.400.0300.06318.92
5.4.390.0300.04719.11
5.4.380.0200.03719.06
5.4.370.0230.05019.24
5.4.360.0330.05319.16
5.4.350.0230.05719.10
5.4.340.0200.04019.22
5.4.320.0200.03719.13
5.4.310.0500.03019.24
5.4.300.0270.03719.08
5.4.290.0270.07318.77
5.4.280.0230.04018.78
5.4.270.0230.04018.88
5.4.260.0300.03719.21
5.4.250.0270.05319.05
5.4.240.0270.07718.82
5.4.230.0270.03319.21
5.4.220.0270.04018.87
5.4.210.0270.03319.21
5.4.200.0370.06319.08
5.4.190.0330.06719.07
5.4.180.0300.06319.07
5.4.170.0300.04019.21
5.4.160.0270.03718.89
5.4.150.0270.07319.00
5.4.140.0230.04316.57
5.4.130.0300.04016.25
5.4.120.0400.06016.37
5.4.110.0230.05016.20
5.4.100.0200.06716.23
5.4.90.0230.04316.45
5.4.80.0330.06316.48
5.4.70.0370.04716.37
5.4.60.0430.02716.45
5.4.50.0230.04316.46
5.4.40.0230.03316.20
5.4.30.0230.06316.42
5.4.20.0230.05716.36
5.4.10.0270.03016.50
5.4.00.0230.07015.63
5.3.290.0270.03714.61
5.3.280.0200.04014.62
5.3.270.0230.04714.55
5.3.260.0300.07714.46
5.3.250.0230.06714.46
5.3.240.0270.07314.47
5.3.230.0230.04714.43
5.3.220.0270.04014.52
5.3.210.0330.06714.42
5.3.200.0300.07314.54
5.3.190.0270.05314.51
5.3.180.0400.06014.49
5.3.170.0230.04714.44
5.3.160.0230.04314.54
5.3.150.0300.04014.39
5.3.140.0230.07014.48
5.3.130.0230.07014.49
5.3.120.0170.04714.38
5.3.110.0300.04314.50
5.3.100.0200.03714.06
5.3.90.0170.07013.98
5.3.80.0230.04013.96
5.3.70.0300.06013.96
5.3.60.0230.07013.95
5.3.50.0330.06013.90
5.3.40.0270.05013.72
5.3.30.0200.04713.95
5.3.20.0230.06013.78
5.3.10.0300.04313.49
5.3.00.0200.06013.58

preferences:
141.39 ms | 1394 KiB | 7 Q