3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Insurance{ function clsNAme(){ echo get_class($this); } } $cl = new Insurance(); $cl->clsName(); Insurance::clsName(); var_dump (3*4); $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "http://www.example.com/"); curl_setopt($ch, CURLOPT_HEADER, 0); curl_exec($ch); curl_close($ch); $var = "testing module"; $statement = 'This is a $var'; echo ($statement); $var = "testing module"; $statement = "This is a $var"; echo ($statement); $arr = array("foo","bar","baz"); for ( $i = 0; $i < count($arr); $i++){ $item = $arr[$i]; } echo "<pre>"; print_r($item); echo "</pre><br/>\r\n"; $a = 3; print '$a'."\r\n"; echo '$a'."\r\n"; print "$a\r\n"; echo "$a\r\n"; $array = array(array(141,151,161), 2, 3, array(101, 202, 303)); function DisplayArray($array) { foreach ($array as $value) { if (is_array($value)) { DisplayArray($value); } else { echo $value . " "; } } } DisplayArray($array); echo 0x10; ?>

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.0110.01118.43
8.3.50.0130.00721.99
8.3.40.0070.00718.73
8.3.30.0070.01018.86
8.3.20.0050.00220.34
8.3.10.0050.00320.59
8.3.00.0040.00420.72
8.2.180.0170.00316.86
8.2.170.0060.00922.96
8.2.160.0100.00322.14
8.2.150.0030.00524.18
8.2.140.0050.00324.66
8.2.130.0070.00021.00
8.2.120.0040.00426.35
8.2.110.0040.00819.45
8.2.100.0110.00018.04
8.2.90.0000.00819.11
8.2.80.0060.00317.97
8.2.70.0000.00917.50
8.2.60.0040.00417.93
8.2.50.0000.00918.09
8.2.40.0080.00020.61
8.2.30.0070.00319.35
8.2.20.0040.00417.84
8.2.10.0020.00518.13
8.2.00.0040.00418.02
8.1.280.0150.00325.92
8.1.270.0070.00723.92
8.1.260.0050.00328.09
8.1.250.0000.00828.09
8.1.240.0060.00320.99
8.1.230.0110.00017.83
8.1.220.0060.00317.74
8.1.210.0030.00618.77
8.1.200.0070.00317.23
8.1.190.0080.00017.35
8.1.180.0030.00618.10
8.1.170.0000.00818.52
8.1.160.0050.00220.69
8.1.150.0040.00418.88
8.1.140.0060.00319.55
8.1.130.0040.00417.64
8.1.120.0000.00717.48
8.1.110.0000.00717.41
8.1.100.0030.00617.33
8.1.90.0020.00517.34
8.1.80.0000.00817.45
8.1.70.0070.00017.39
8.1.60.0040.00417.64
8.1.50.0000.00817.54
8.1.40.0030.00717.61
8.1.30.0030.00617.64
8.1.20.0000.00717.52
8.1.10.0030.00517.55
8.1.00.0030.00617.44
8.0.300.0040.00418.77
8.0.290.0000.00716.72
8.0.280.0000.00718.42
8.0.270.0030.00317.17
8.0.260.0030.00517.30
8.0.250.0030.00716.95
8.0.240.0040.00417.04
8.0.230.0000.00816.86
8.0.220.0000.00716.88
8.0.210.0030.00516.85
8.0.200.0000.00616.96
8.0.190.0030.00617.05
8.0.180.0000.00716.84
8.0.170.0040.00416.86
8.0.160.0000.00716.86
8.0.150.0020.01016.86
8.0.140.0030.00516.89
8.0.130.0000.00513.36
8.0.120.0040.00416.92
8.0.110.0040.00416.76
8.0.100.0000.00716.99
8.0.90.0040.00416.84
8.0.80.0070.01016.82
8.0.70.0050.00316.94
8.0.60.0040.00416.76
8.0.50.0000.00716.90
8.0.30.0130.00717.23
8.0.20.0100.01117.43
8.0.10.0040.00417.03
8.0.00.0090.00816.81
7.4.330.0000.00516.83
7.4.320.0000.00616.57
7.4.300.0050.00216.68
7.4.290.0030.00316.54
7.4.280.0000.00816.50
7.4.270.0040.00416.47
7.4.260.0030.00516.54
7.4.250.0040.00416.53
7.4.240.0030.00316.54
7.4.230.0000.00716.54
7.4.220.0100.01016.50
7.4.210.0090.00616.59
7.4.200.0080.00016.73
7.4.160.0130.00316.71
7.4.150.0100.00717.40
7.4.140.0090.01217.86
7.4.130.0040.01416.54
7.4.120.0090.01016.51
7.4.110.0060.01016.48
7.4.100.0160.00716.52
7.4.90.0090.00916.50
7.4.80.0190.00419.39
7.4.70.0100.01016.59
7.4.60.0110.01116.57
7.4.50.0110.00416.85
7.4.40.0100.00716.46
7.4.30.0170.00616.37
7.4.00.0070.01015.19
7.3.330.0030.00313.41
7.3.320.0000.00713.41
7.3.310.0040.00316.43
7.3.300.0070.00016.41
7.3.290.0080.00716.37
7.3.280.0070.00916.38
7.3.270.0100.00817.40
7.3.260.0100.00716.46
7.3.240.0100.00816.57
7.3.230.0060.01016.43
7.3.210.0140.00416.45
7.3.200.0160.00616.32
7.3.190.0090.00916.67
7.3.180.0120.00616.57
7.3.170.0140.00316.52
7.3.160.0060.00916.45
7.3.10.0030.01016.52
7.3.00.0030.00716.63
7.2.330.0090.00916.45
7.2.320.0030.01416.82
7.2.310.0130.00316.70
7.2.300.0030.01816.45
7.2.290.0130.00316.71
7.2.130.0030.01016.61
7.2.120.0070.00716.66
7.2.110.0080.00416.94
7.2.100.0030.01116.73
7.2.90.0040.00816.74
7.2.80.0070.01116.93
7.2.70.0120.00316.97
7.2.60.0030.01017.02
7.2.50.0060.00616.96
7.2.40.0070.01016.86
7.2.30.0030.00716.95
7.2.20.0090.00616.74
7.2.10.0150.00317.05
7.2.00.0030.00918.13
7.1.250.0040.01015.79
7.1.200.0070.00715.60
7.1.100.0030.00618.13
7.1.70.0040.00416.72
7.1.60.0000.02219.27
7.1.50.0110.01116.90
7.1.00.0100.06322.35
7.0.200.0430.00414.62
7.0.60.0030.08721.55
7.0.50.0130.07717.90
7.0.40.0130.07720.02
7.0.30.0270.06720.16
7.0.20.0330.07720.33
7.0.10.0030.05020.24
7.0.00.0200.06320.10
5.6.280.0070.07021.14
5.6.210.0070.05720.78
5.6.200.0000.04318.24
5.6.190.0030.08320.47
5.6.180.0230.04320.48
5.6.170.0370.07320.54
5.6.160.0030.07020.45
5.6.150.0100.06018.19
5.6.140.0030.08718.18
5.6.130.0070.05718.25
5.6.120.0330.04021.01
5.6.110.0030.04321.02
5.6.100.0100.03321.11
5.6.90.0030.04321.04
5.6.80.0130.06320.53
5.5.350.0270.02720.46
5.5.340.0070.06318.02
5.5.330.0170.07320.43
5.5.320.0300.06720.38
5.5.310.0270.07720.51
5.5.300.0030.04317.94
5.5.290.0070.04717.94
5.5.280.0000.04720.75
5.5.270.0070.07020.91
5.5.260.0130.08020.81
5.5.250.0170.07020.81
5.5.240.0100.05320.28

preferences:
60.22 ms | 401 KiB | 5 Q