3v4l.org

run code in 300+ PHP versions simultaneously
<?php //var_dump(false); /*preg_match('@^(?:http://)?([^/]+)@i','http://www.php.net/index.html',$matches); ${"a"} = $matches[1]; &$a = 12; echo &$a; var_export(${"a"});*/ /*echo ${"a"};*/ /*trait Foo { private $name = '123'; } class Bar { //use Foo; private static $name = '321'; public static function getName(){return static::$name;} } */ /*echo sprintf(' "%04d"', 1);*/ /* $num = array('11' , '12', '13'); foreach ($num as $val) { $val++; } print_r($num);*/ /* class Foo extends Bar{private static $name='123';} $bar = new Foo(); $bar::getName();*/ /*echo false; */ class Faz {}// $i = new Faz(); echo $i->t;/* class Baz extends Faz {} interface Foo {public function du(Faz $param);} class A implements Foo { public function du(Baz $param){ echo false; } } $c = new A(); $c->du(new Baz()); /* $i = 5; echo $i++; echo $i;*/ /* namespace Bar; function strlen($string){return 5;} namespace Foo; use Bar; echo strlen('Baz');*/ //var_dump(array_values(ksort(array('re'=>'asd', '3'=>'asda')))); //echo true;

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.0090.00616.75
8.3.50.0120.00722.83
8.3.40.0120.00618.84
8.3.30.0140.00019.14
8.3.20.0080.00020.18
8.3.10.0040.00421.98
8.3.00.0040.00419.13
8.2.180.0100.01016.50
8.2.170.0140.00022.96
8.2.160.0110.00320.50
8.2.150.0080.00024.18
8.2.140.0070.00024.66
8.2.130.0070.00026.16
8.2.120.0030.00621.10
8.2.110.0060.00320.86
8.2.100.0110.00017.72
8.2.90.0040.00417.72
8.2.80.0050.00517.97
8.2.70.0050.00517.50
8.2.60.0000.00817.77
8.2.50.0000.01018.07
8.2.40.0000.00718.19
8.2.30.0030.00517.99
8.2.20.0040.00417.68
8.2.10.0070.00017.91
8.2.00.0000.00817.55
8.1.280.0060.00825.92
8.1.270.0040.00423.86
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0100.00022.48
8.1.230.0080.00420.89
8.1.220.0040.00417.74
8.1.210.0050.00318.91
8.1.200.0060.00317.22
8.1.190.0000.00817.10
8.1.180.0050.00318.10
8.1.170.0000.00818.69
8.1.160.0070.00022.05
8.1.150.0050.00218.85
8.1.140.0040.00417.25
8.1.130.0030.00319.55
8.1.120.0030.00317.36
8.1.110.0080.00017.42
8.1.100.0030.00417.38
8.1.90.0030.00317.31
8.1.80.0000.00717.28
8.1.70.0040.00417.36
8.1.60.0060.00317.52
8.1.50.0000.00817.50
8.1.40.0000.00717.48
8.1.30.0060.00317.64
8.1.20.0040.00417.55
8.1.10.0040.00417.24
8.1.00.0040.00417.31
8.0.300.0000.00819.91
8.0.290.0060.00316.75
8.0.280.0000.00718.29
8.0.270.0000.00717.18
8.0.260.0030.00317.10
8.0.250.0000.00616.85
8.0.240.0030.00516.80
8.0.230.0030.00316.82
8.0.220.0000.00716.88
8.0.210.0000.00716.77
8.0.200.0000.00616.95
8.0.190.0000.00816.91
8.0.180.0050.00316.94
8.0.170.0050.00316.80
8.0.160.0070.00016.95
8.0.150.0040.00416.95
8.0.140.0040.00816.75
8.0.130.0030.00313.29
8.0.120.0030.00516.78
8.0.110.0040.00416.90
8.0.100.0030.00516.71
8.0.90.0040.00416.87
8.0.80.0160.00016.84
8.0.70.0040.00416.78
8.0.60.0000.00716.78
8.0.50.0000.00717.00
8.0.30.0080.01116.76
8.0.20.0080.01317.40
8.0.10.0070.00017.06
8.0.00.0100.00616.56
7.4.330.0000.00515.09
7.4.320.0000.00616.43
7.4.300.0030.00316.41
7.4.290.0000.00716.52
7.4.280.0000.00716.42
7.4.270.0070.00016.39
7.4.260.0050.00316.38
7.4.250.0050.00316.41
7.4.240.0030.00416.41
7.4.230.0030.00316.61
7.4.220.0080.00816.53
7.4.210.0030.01016.64
7.4.200.0000.00716.52
7.4.160.0060.01016.50
7.4.150.0090.00917.40
7.4.140.0100.00817.86
7.4.130.0250.03216.54
7.4.120.0130.00616.50
7.4.110.0090.01216.43
7.4.100.0130.01016.44
7.4.90.0350.02516.59
7.4.80.0160.00019.39
7.4.70.0050.01116.61
7.4.60.0070.01316.30
7.4.50.0040.00416.34
7.4.40.0070.01016.25
7.4.30.0150.00016.37
7.4.00.0060.00615.18
7.3.330.0050.00013.24
7.3.320.0020.00213.16
7.3.310.0030.00316.25
7.3.300.0000.00716.26
7.3.290.0140.00316.23
7.3.280.0080.00716.24
7.3.270.0080.00817.40
7.3.260.0120.00816.23
7.3.240.0080.00816.36
7.3.230.0140.00316.51
7.3.210.0080.01116.10
7.3.200.0040.01419.39
7.3.190.0090.00916.58
7.3.180.0100.00616.41
7.3.170.0090.00616.38
7.3.160.0100.01016.39
7.3.120.0030.01214.89
7.3.110.0090.00614.82
7.3.100.0100.00314.34
7.3.90.0030.01014.63
7.3.80.0040.01114.65
7.3.70.0100.00714.68
7.3.60.0030.01014.66
7.3.50.0030.01014.69
7.3.40.0040.01414.80
7.3.30.0030.00914.72
7.3.20.0070.00316.44
7.3.10.0090.00616.61
7.3.00.0090.00316.54
7.2.330.0120.00616.47
7.2.320.0030.01316.66
7.2.310.0130.00316.40
7.2.300.0100.00616.40
7.2.290.0120.00316.33
7.2.240.0060.00914.67
7.2.230.0060.00615.00
7.2.220.0100.00714.73
7.2.210.0130.00314.60
7.2.200.0030.01315.02
7.2.190.0060.00614.93
7.2.180.0030.01014.78
7.2.170.0100.00714.76
7.2.160.0000.01514.90
7.2.150.0090.00616.65
7.2.140.0000.01516.29
7.2.130.0110.00416.45
7.2.120.0060.00616.60
7.2.110.0090.00616.75
7.2.100.0130.00316.83
7.2.90.0110.00416.89
7.2.80.0090.00616.89
7.2.70.0090.00616.56
7.2.60.0050.01016.67
7.2.50.0060.01116.65
7.2.40.0070.01016.83
7.2.30.0070.00716.68
7.2.20.0060.00916.78
7.2.10.0040.01116.70
7.2.00.0070.00817.93
7.1.330.0000.01615.33
7.1.320.0090.00615.64
7.1.310.0100.00315.69
7.1.300.0040.01115.51
7.1.290.0070.00715.58
7.1.280.0090.00615.27
7.1.270.0080.00515.69
7.1.260.0090.00315.61
7.1.250.0070.00415.36
7.1.200.0090.00315.80
7.1.70.0000.00917.00
7.1.60.0070.01819.40
7.1.50.0040.01816.83
7.1.00.0030.07322.32
7.0.200.0130.00316.75
7.0.140.0100.06322.18
7.0.60.0000.08019.95
7.0.50.0100.07717.97
7.0.40.0100.08320.20
7.0.30.0230.05020.24
7.0.20.0270.03020.07
7.0.10.0130.07720.12
7.0.00.0100.07320.08
5.6.280.0100.06321.08
5.6.210.0070.03720.52
5.6.200.0130.08018.19
5.6.190.0100.05320.52
5.6.180.0270.06320.64
5.6.170.0200.04720.55
5.6.160.0030.05320.55
5.6.150.0100.04718.14
5.6.140.0030.05018.28
5.6.130.0130.07718.23
5.6.120.0170.06321.05
5.6.110.0130.07720.96
5.6.100.0100.08020.97
5.6.90.0030.06321.11
5.6.80.0130.07320.44
5.5.350.3400.04720.42
5.5.340.0170.06717.99
5.5.330.0200.06720.34
5.5.320.0400.05020.51
5.5.310.0370.07020.25
5.5.300.0070.06717.98
5.5.290.0130.07317.99
5.5.280.0130.07720.74
5.5.270.0100.08720.68
5.5.260.0130.08020.98
5.5.250.0130.06320.60
5.5.240.0100.07020.05
5.4.450.1500.04019.49
5.4.440.1530.04719.63
5.4.430.1800.05019.64
5.4.420.1600.03719.54
5.4.410.1770.03019.29
5.4.400.1470.04019.14
5.4.390.1530.04019.00
5.4.380.2100.04718.98
5.4.370.1670.03319.09
5.4.360.0030.03718.87
5.4.350.0000.04019.13
5.4.340.0300.04719.16
5.4.320.0030.04018.84
5.4.310.0100.03019.20
5.4.300.0000.04018.94
5.4.290.0530.03318.87
5.4.280.0170.03718.98
5.4.270.0170.03719.16
5.4.260.0200.03318.95
5.4.250.0200.03319.14
5.4.240.0270.04319.08
5.4.230.0170.04319.23
5.4.220.0170.03718.99
5.4.210.0200.03319.16
5.4.200.0230.03319.15
5.4.190.0100.06319.15
5.4.180.0170.05018.83
5.4.170.0100.04318.98
5.4.160.0370.03019.03
5.4.150.0130.04019.29
5.4.140.0130.03716.55
5.4.130.0200.03016.44
5.4.120.0170.03016.40
5.4.110.0170.03316.45
5.4.100.0170.04316.56
5.4.90.0170.04016.64
5.4.80.0200.03016.28
5.4.70.0200.03016.57
5.4.60.0130.03716.43
5.4.50.0170.03316.38
5.4.40.0130.03716.51
5.4.30.0130.04016.55
5.4.20.0100.04716.51
5.4.10.0200.03316.51
5.4.00.0200.04015.77
5.3.290.0170.05014.72
5.3.280.0270.05014.68
5.3.270.0200.08014.58
5.3.260.0170.04314.70
5.3.250.0130.04314.63
5.3.240.0170.03714.68
5.3.230.0130.04014.57
5.3.220.0170.03714.69
5.3.210.0200.03714.72
5.3.200.0200.03314.66
5.3.190.0270.02714.58
5.3.180.0200.03314.49
5.3.170.0130.04014.55
5.3.160.0170.03714.57
5.3.150.0200.04714.65
5.3.140.0170.04314.56
5.3.130.0130.04014.56
5.3.120.0200.04714.54
5.3.110.0330.02714.45
5.3.100.0200.04713.95
5.3.90.0200.04713.93
5.3.80.0100.04714.04
5.3.70.0230.03313.93
5.3.60.0170.03714.13
5.3.50.0200.03313.96
5.3.40.0230.06713.88
5.3.30.0100.04313.89
5.3.20.0070.03713.70
5.3.10.0230.03313.73
5.3.00.0200.03313.66
5.2.170.0170.02711.08
5.2.160.0100.03011.23
5.2.150.0000.03311.08
5.2.140.0000.03011.06
5.2.130.0000.03311.12
5.2.120.0930.02311.08
5.2.110.0030.02711.33
5.2.100.0000.04711.26
5.2.90.0000.03011.01
5.2.80.0970.02711.00
5.2.70.0000.03011.07
5.2.60.0030.03011.12
5.2.50.0000.03311.11
5.2.40.0100.05710.86
5.2.30.0000.04010.92
5.2.20.0030.04710.94
5.2.10.0070.03310.95
5.2.00.0070.04310.77
5.1.60.0000.03010.08
5.1.50.0000.0339.93
5.1.40.0030.0279.96
5.1.30.0030.02710.27
5.1.20.0030.04310.43
5.1.10.0000.03710.06
5.1.00.0070.02710.05
5.0.50.0630.0278.48
5.0.40.0570.0238.35
5.0.30.0130.0238.13
5.0.20.0030.0178.36
5.0.10.0000.0238.07
5.0.00.0000.0308.07
4.4.90.0030.0137.90
4.4.80.0430.0137.90
4.4.70.0530.0177.90
4.4.60.0570.0207.90
4.4.50.0670.0207.90
4.4.40.0030.0277.90
4.4.30.0070.0107.90
4.4.20.0000.0207.90
4.4.10.0000.0337.90
4.4.00.0000.0237.90
4.3.110.0030.0137.90
4.3.100.0070.0237.90
4.3.90.0430.0137.90
4.3.80.0570.0237.90
4.3.70.0670.0207.90
4.3.60.0570.0137.90
4.3.50.0530.0177.90
4.3.40.0670.0337.90
4.3.30.0000.0337.90
4.3.20.0000.0307.90
4.3.10.0030.0307.90
4.3.00.0000.0377.90

preferences:
46.35 ms | 404 KiB | 6 Q