3v4l.org

run code in 300+ PHP versions simultaneously
<?php $oses = array( 'Windows 8' => 'windows nt 6.2', 'Windows 7' => 'windows nt 6.1', 'Windows Vista' => 'windows nt 6.0', 'Windows XP' => array('winnt5.1', 'windows nt 5.1'), 'Windows 2000' => array('winnt5.0', 'windows nt 5.0'), 'Windows NT' => array('winnt4.0', 'windows nt 4.0'), 'Windows 95' => array('win95', 'windows 95'), 'Windows 98' => array('win98', 'windows 98'), 'Windows 2003 Server' => 'windows nt 5.2', 'Windows CE' => 'windows ce', 'Windows ME' => array('windows 9x 4.90', 'windows me'), 'Windows Unatended' => 'windows', 'Mac OS X 10.0' => 'mac os x 10.0', 'Mac OS X 10.1' => 'mac os x 10.1', 'Mac OS X 10.2' => 'mac os x 10.2', 'Mac OS X 10.3' => 'mac os x 10.3', 'Mac OS X 10.4' => 'mac os x 10.4', 'Mac OS X 10.5' => 'mac os x 10.5', 'Mac OS X 10.6' => 'mac os x 10.6', 'Mac OS X 10.7' => 'mac os x 10.7', 'Mac OS X 10.8' => 'mac os x 10.8', 'Mac OS X 10.9' => 'mac os x 10.9', 'Mac OS X' => 'mac os x', 'Macintosh' => array('powerpc', 'macintosh'), 'iOS' => array('iphone', 'ipad', 'ipod'), 'Android 5.x' => 'android 5', 'Android 4.x' => 'android 4', 'Android 3.x' => 'android 3', 'Android 2.x' => 'android 2', 'Android 1.x' => 'android 1', 'Android' => 'android', 'Linux' => 'linux', 'Free BSD' => 'freebsd', 'Net BSD' => 'netbsd', 'Open BSD' => 'openbsd', 'Sun OS' => 'sunos', 'Symbian' => 'symbian', 'Tapatalk' => 'tapatalk', ); #$useragent = strtolower('Mozilla/5.0 (iPad; CPU OS 5_1_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9B206 Safari/7534.48.3'); $useragent = strtolower('Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_1 like Mac OS X; en-us) AppleWebKit/532.9 (KHTML, like Gecko) Version/4.0.5 Mobile/8B117 Safari/6531.22.7 (compatible; Googlebot-Mobile/2.1; +http://www.google.com/bot.html)'); #$useragent = strtolower('Mozilla/4.0 (compatible; MSIE 4.0; Windows 95; .NET CLR 1.1.4322; .NET CLR 2.0.50727'); foreach ($oses as $os => $identificator) { if (is_array($identificator)) { #user_error($useragent, E_USER_NOTICE); foreach ($identificator as $ident) { user_error($ident, E_USER_NOTICE); if (preg_match("#$ident#i", $useragent)) { user_error('FOUND!', E_USER_NOTICE); $browser['os'] = $os; break; } } } else { user_error($identificator, E_USER_NOTICE); if (preg_match("#$identificator#i", $useragent)) { $browser['os'] = $os; break; } } } user_error($browser['os'], E_USER_NOTICE); ?>

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)
8.3.60.0140.00718.81
8.3.50.0090.00922.16
8.3.40.0100.01319.09
8.3.30.0040.01119.21
8.3.20.0000.00920.38
8.3.10.0030.00523.51
8.3.00.0080.00020.94
8.2.180.0120.00318.31
8.2.170.0090.00622.96
8.2.160.0140.00020.35
8.2.150.0080.00024.18
8.2.140.0100.01024.66
8.2.130.0040.00426.16
8.2.120.0040.00420.84
8.2.110.0070.00422.38
8.2.100.0120.00019.89
8.2.90.0000.00919.40
8.2.80.0000.00917.97
8.2.70.0050.00317.63
8.2.60.0030.00618.04
8.2.50.0040.00418.07
8.2.40.0040.00418.14
8.2.30.0040.00418.38
8.2.20.0060.00317.99
8.2.10.0050.00318.25
8.2.00.0090.00017.86
8.1.280.0160.00325.92
8.1.270.0090.00023.91
8.1.260.0040.00426.35
8.1.250.0000.00828.09
8.1.240.0150.00719.05
8.1.230.0110.00019.35
8.1.220.0030.00617.79
8.1.210.0000.00918.77
8.1.200.0060.00717.60
8.1.190.0000.00817.48
8.1.180.0080.00018.10
8.1.170.0060.00318.90
8.1.160.0000.00822.04
8.1.150.0040.00418.76
8.1.140.0000.00817.64
8.1.130.0040.00418.00
8.1.120.0000.00717.54
8.1.110.0040.00417.64
8.1.100.0030.00617.69
8.1.90.0040.00417.54
8.1.80.0050.00317.54
8.1.70.0000.00717.50
8.1.60.0050.00317.75
8.1.50.0040.00417.63
8.1.40.0030.00517.60
8.1.30.0000.00817.80
8.1.20.0030.00617.81
8.1.10.0000.00817.76
8.1.00.0030.00617.71
8.0.300.0040.00418.77
8.0.290.0040.00417.00
8.0.280.0080.00018.52
8.0.270.0030.00317.32
8.0.260.0070.00017.36
8.0.250.0000.00717.19
8.0.240.0000.00817.16
8.0.230.0000.00817.21
8.0.220.0050.00317.04
8.0.210.0050.00217.07
8.0.200.0000.00817.17
8.0.190.0040.00417.15
8.0.180.0080.00017.10
8.0.170.0040.00417.21
8.0.160.0040.00417.03
8.0.150.0050.00317.11
8.0.140.0060.00317.05
8.0.130.0030.00313.61
8.0.120.0030.00517.12
8.0.110.0080.00017.15
8.0.100.0000.00717.02
8.0.90.0040.00417.07
8.0.80.0130.01017.10
8.0.70.0040.00417.09
8.0.60.0070.00017.21
8.0.50.0000.00816.99
8.0.30.0070.01617.22
8.0.20.0070.01417.40
8.0.10.0040.00417.12
8.0.00.0050.01417.00
7.4.330.0000.00515.04
7.4.320.0070.00016.77
7.4.300.0030.00316.85
7.4.290.0040.00416.80
7.4.280.0000.00916.73
7.4.270.0000.00916.84
7.4.260.0060.00316.78
7.4.250.0040.00416.74
7.4.240.0020.00616.88
7.4.230.0000.00816.77
7.4.220.0130.00616.79
7.4.210.0060.01016.88
7.4.200.0000.00716.79
7.4.190.0070.00016.84
7.4.160.0080.00816.77
7.4.150.0070.01017.40
7.4.140.0090.01317.86
7.4.130.0050.01416.82
7.4.120.0070.01116.78
7.4.110.0050.01516.82
7.4.100.0080.01016.81
7.4.90.0100.01316.63
7.4.80.0070.01119.39
7.4.70.0100.00716.79
7.4.60.0040.01716.71
7.4.50.0030.00516.98
7.4.40.0110.00916.82
7.4.30.0090.00916.69
7.4.00.0050.00315.29
7.3.330.0000.00613.41
7.3.320.0000.00713.35
7.3.310.0040.00416.62
7.3.300.0020.00516.59
7.3.290.0110.00416.60
7.3.280.0080.00916.55
7.3.270.0040.01617.40
7.3.260.0130.00916.66
7.3.250.0070.01216.60
7.3.240.0070.01316.73
7.3.230.0000.01716.76
7.3.210.0160.00016.81
7.3.200.0000.01816.74
7.3.190.0170.00816.52
7.3.180.0070.01016.55
7.3.170.0090.00616.57
7.3.160.0140.00416.50
7.3.120.0030.01315.25
7.2.330.0110.01216.88
7.2.320.0130.01016.92
7.2.310.0070.01116.84
7.2.300.0100.01016.92
7.2.290.0050.01416.87
7.2.00.0000.01619.88
7.1.100.0040.00818.59
7.1.70.0090.00317.45
7.1.60.0060.01919.70
7.1.50.0240.01434.87
7.1.00.0100.07022.48
7.0.200.0170.00416.65
7.0.140.0000.07721.99
7.0.100.0170.05020.01
7.0.90.0200.08720.05
7.0.80.0170.08020.02
7.0.70.0200.04720.05
7.0.60.0230.04319.98
7.0.50.0170.06020.43
7.0.40.0070.07320.03
7.0.30.0000.09020.13
7.0.20.0030.08320.13
7.0.10.0100.09020.03
7.0.00.0030.08319.93
5.6.280.0030.07320.88
5.6.250.0070.06320.62
5.6.240.0030.06020.77
5.6.230.0100.08320.68
5.6.220.0070.05020.61
5.6.210.0030.08720.69
5.6.200.0130.07721.13
5.6.190.0130.08021.11
5.6.180.0100.07321.10
5.6.170.0170.06021.04
5.6.160.0100.07021.05
5.6.150.0130.07320.97
5.6.140.0030.05721.08
5.6.130.0000.08321.15
5.6.120.0000.06720.97
5.6.110.0030.05321.18
5.6.100.0100.07021.05
5.6.90.0100.05021.09
5.6.80.0170.07020.43
5.6.70.0100.07720.43
5.6.60.0100.07320.34
5.6.50.0230.03720.44
5.6.40.0130.04720.32
5.6.30.0000.04320.55
5.6.20.0000.04320.32
5.6.10.0000.04320.31
5.6.00.0030.04020.54
5.5.380.0030.08020.40
5.5.370.0070.08020.45
5.5.360.0070.08720.37
5.5.350.0070.08320.48
5.5.340.0100.04720.76
5.5.330.0170.07320.86
5.5.320.0130.07320.86
5.5.310.0030.08020.78
5.5.300.0100.08020.88
5.5.290.0030.05320.89
5.5.280.0100.08020.92
5.5.270.0130.07320.87
5.5.260.0070.08720.75
5.5.250.0100.07720.47
5.5.240.0030.05720.27
5.5.230.0170.06020.27
5.5.220.0100.07020.22
5.5.210.0070.07720.30
5.5.200.0030.06720.15
5.5.190.0070.03720.30
5.5.180.0000.04320.26
5.5.160.0030.04020.18
5.5.150.0070.05320.17
5.5.140.0070.03720.13
5.5.130.0000.04320.16
5.5.120.0100.03320.28
5.5.110.0030.03720.28
5.5.100.0070.03319.97
5.5.90.0070.06719.92
5.5.80.0170.06320.03
5.5.70.0000.08320.17
5.5.60.0130.03720.07
5.5.50.0130.06720.08
5.5.40.0070.05320.08
5.5.30.0000.04320.16
5.5.20.0000.08320.17
5.5.10.0070.03720.05
5.5.00.0000.04320.04
5.4.450.0070.07719.15
5.4.440.0130.07719.37
5.4.430.0100.03719.13
5.4.420.0030.05319.27
5.4.410.0070.07719.34
5.4.400.0230.05719.07
5.4.390.0100.06718.79
5.4.380.0130.06718.90
5.4.370.0070.08019.13
5.4.360.0070.04018.95
5.4.350.0070.04318.81
5.4.340.0030.04018.96
5.4.320.0030.03718.97
5.4.310.0070.03719.08
5.4.300.0070.03319.04
5.4.290.0000.04319.07
5.4.280.0070.04018.95
5.4.270.0100.07319.03
5.4.260.0170.07019.03
5.4.250.0070.06719.03
5.4.240.0130.06318.82
5.4.230.0070.06319.00
5.4.220.0130.06319.08
5.4.210.0070.05018.95
5.4.200.0030.04318.96
5.4.190.0170.06318.80
5.4.180.0030.03718.98
5.4.170.0070.04318.80
5.4.160.0130.02719.05
5.4.150.0000.04018.77
5.4.140.0070.03316.39
5.4.130.0170.02316.29
5.4.120.0000.03716.17
5.4.110.0030.05316.27
5.4.100.0000.03716.51
5.4.90.0000.04016.46
5.4.80.0070.03716.46
5.4.70.0000.04316.47
5.4.60.0030.03316.25
5.4.50.0030.03316.44
5.4.40.0070.05316.38
5.4.30.0000.03716.35
5.4.20.0030.06716.24
5.4.10.0100.03016.29
5.4.00.0100.03315.86
5.3.290.0100.03314.68
5.3.280.0070.07014.61
5.3.270.0030.06314.60
5.3.260.0000.05714.63
5.3.250.0030.03714.59
5.3.240.0030.06714.55
5.3.230.0000.04014.47
5.3.220.0130.04014.57
5.3.210.0070.03714.59
5.3.200.0070.03314.45
5.3.190.0030.03714.58
5.3.180.0030.03714.45
5.3.170.0130.02714.46
5.3.160.0030.06314.50
5.3.150.0130.02714.50
5.3.140.0000.07314.57
5.3.130.0000.04314.39
5.3.120.0000.04714.42
5.3.110.0030.05714.56
5.3.100.0000.05713.93
5.3.90.0030.04013.90
5.3.80.0070.03713.91
5.3.70.0070.03313.91
5.3.60.0000.03713.89
5.3.50.0030.03713.96
5.3.40.0100.07013.95
5.3.30.0100.06313.79
5.3.20.0030.07313.63
5.3.10.0100.06713.67
5.3.00.0070.07313.58
5.2.170.0000.04011.04
5.2.160.0030.02711.17
5.2.150.0100.06011.02
5.2.140.0100.05310.99
5.2.130.0030.05710.95
5.2.120.0070.05310.92
5.2.110.0070.05011.08
5.2.100.0070.06711.08
5.2.90.0000.05711.09
5.2.80.0100.03011.13
5.2.70.0130.05011.12
5.2.60.0130.05711.00
5.2.50.0100.05711.09
5.2.40.0100.05711.08
5.2.30.0100.05711.01
5.2.20.0070.05710.80
5.2.10.0070.05710.77
5.2.00.0030.05710.82
5.1.60.0070.05310.06
5.1.50.0030.03010.01
5.1.40.0030.05310.00
5.1.30.0100.04710.41
5.1.20.0070.03010.24
5.1.10.0030.0439.94
5.1.00.0030.0509.98
5.0.50.0030.0438.60
5.0.40.0030.0408.50
5.0.30.0000.0638.40
5.0.20.0070.0408.40
5.0.10.0070.0408.40
5.0.00.0030.0638.40
4.4.90.0000.0378.40
4.4.80.0030.0338.40
4.4.70.0000.0378.40
4.4.60.0000.0278.40
4.4.50.0100.0308.40
4.4.40.0030.0438.40
4.4.30.0000.0378.40
4.4.20.0070.0308.40
4.4.10.0000.0378.40
4.4.00.0100.0478.40
4.3.110.0000.0208.40
4.3.100.0030.0378.40
4.3.90.0030.0338.40
4.3.80.0070.0508.40
4.3.70.0100.0278.40
4.3.60.0000.0378.40
4.3.50.0000.0338.40
4.3.40.0000.0538.40
4.3.30.0030.0338.40
4.3.20.0030.0378.40
4.3.10.0000.0378.40
4.3.00.0000.0378.40

preferences:
45.31 ms | 401 KiB | 5 Q