3v4l.org

run code in 300+ PHP versions simultaneously
<?php $x = new DOMDocument('1.0, 'UTF-8); $x->loadHTML('<html><head></head><body><p>fi</p><p>fai</p><p>foe</p><p>fum</p></body></html>'); $e = $x->getElementsByTagName('p')->item(0); $y = new DOMDocument('1.0, 'UTF-8); $y->appendChild($y->importNode($e, true); var_dump($y->saveHTML());

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.4.270.0070.04012.39
5.4.260.0030.06718.93
5.4.250.0200.05018.93
5.4.240.0170.07018.66
5.4.230.0170.07018.87
5.4.220.0100.07018.75
5.4.210.0170.06318.65
5.4.200.0100.06318.96
5.4.190.0000.06319.02
5.4.180.0070.05318.97
5.4.170.0100.05318.87
5.4.160.0170.04318.89
5.4.150.0070.05318.96
5.4.140.0170.05316.46
5.4.130.0100.05016.25
5.4.120.0200.05016.27
5.4.110.0100.06016.65
5.4.100.0130.04316.41
5.4.90.0100.07016.65
5.4.80.0170.05316.44
5.4.70.0100.06716.46
5.4.60.0100.05316.51
5.4.50.0170.05316.34
5.4.40.0130.04716.56
5.4.30.0130.05016.45
5.4.20.0270.05016.32
5.4.10.0030.06316.37
5.4.00.0230.04715.84
5.3.280.0200.05314.61
5.3.270.0100.05014.48
5.3.260.0100.05314.76
5.3.250.0200.04014.38
5.3.240.0100.05014.62
5.3.230.0070.07314.39
5.3.220.0070.06014.34
5.3.210.0100.07314.50
5.3.200.0130.04714.28
5.3.190.0170.05014.45
5.3.180.0100.05014.61
5.3.170.0100.06014.45
5.3.160.0070.05014.45
5.3.150.0130.05014.66
5.3.140.0170.06014.65
5.3.130.0170.05014.46
5.3.120.0130.05714.54
5.3.110.0130.06314.55
5.3.100.0200.04014.05
5.3.90.0200.06713.71
5.3.80.0000.07713.88
5.3.70.0100.06314.05
5.3.60.0130.04313.84
5.3.50.0130.07313.96
5.3.40.0130.05313.72
5.3.30.0130.04713.82
5.3.20.0170.05313.48
5.3.10.0130.05013.80
5.3.00.0100.05313.67
5.2.170.0070.04311.16
5.2.160.0130.05311.16
5.2.150.0070.05711.15
5.2.140.0070.04311.05
5.2.130.0130.04711.03
5.2.120.0030.05711.11
5.2.110.0100.04311.11
5.2.100.0100.04011.00
5.2.90.0030.05010.98
5.2.80.0070.04711.09
5.2.70.0070.05010.99
5.2.60.0100.05311.16
5.2.50.0070.04010.94
5.2.40.0070.05010.76
5.2.30.0130.04010.97
5.2.20.0030.05710.88
5.2.10.0170.04010.94
5.2.00.0130.03710.93
5.1.60.0000.04010.14
5.1.50.0070.0379.84
5.1.40.0030.03710.12
5.1.30.0070.03710.51
5.1.20.0070.05010.19
5.1.10.0070.0509.83
5.1.00.0070.0479.99
5.0.50.0070.0238.50
5.0.40.0030.0378.55
5.0.30.0070.0508.27
5.0.20.0070.0338.18
5.0.10.0130.0278.36
5.0.00.0030.0478.39
4.4.90.0070.0277.55
4.4.80.0100.0237.55
4.4.70.0000.0337.55
4.4.60.0000.0277.55
4.4.50.0070.0237.55
4.4.40.0100.0277.55
4.4.30.0130.0177.55
4.4.20.0070.0237.55
4.4.10.0070.0277.55
4.4.00.0000.0377.55
4.3.110.0030.0307.55
4.3.100.0030.0237.55
4.3.90.0100.0207.55
4.3.80.0000.0507.55
4.3.70.0030.0237.55
4.3.60.0000.0237.55
4.3.50.0130.0237.55
4.3.40.0100.0407.55
4.3.30.0030.0307.55
4.3.20.0070.0277.55
4.3.10.0000.0307.55
4.3.00.0370.01313.25

preferences:
168.29 ms | 1394 KiB | 7 Q