3v4l.org

run code in 300+ PHP versions simultaneously
<?php $aDOM = new DOMDocument(); $aDOM->loadXML('<f2f:o xmlns:f2f=" http://friend2friend.net " xmlns:default="default"><default:i xmlns="default"><f2f:watch-me/></default:i></f2f:o>'); echo 'Initial DOM is '.$aDOM->saveXML().chr(13); $newNode= $aDOM->createElementNS(" http://friend2friend.net ", 'newnode'); $newNode->appendChild($aDOM->documentElement); echo 'Appending the document Element to f2f:newnode, it all looks OK: '.chr(13).$aDOM->saveXML($newNode).chr(13).chr(13); $aDOM->appendChild($newNode); echo 'But adding <f2f:newnode> back as the documentElement changes a namespace '.$aDOM->saveXML();

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.90.0050.00326.77
8.3.80.0030.00719.36
8.3.70.0210.00318.68
8.3.60.0150.00017.00
8.3.50.0100.01222.13
8.3.40.0090.00619.23
8.3.30.0190.00018.98
8.3.20.0040.00421.03
8.3.10.0040.00421.91
8.3.00.0030.00619.81
8.2.210.0060.01226.77
8.2.200.0100.00318.91
8.2.190.0120.00918.79
8.2.180.0070.01117.13
8.2.170.0110.00422.96
8.2.160.0110.00422.52
8.2.150.0000.00824.18
8.2.140.0040.00424.66
8.2.130.0050.00319.58
8.2.120.0080.00026.35
8.2.110.0030.00722.35
8.2.100.0000.01118.16
8.2.90.0060.00318.15
8.2.80.0040.00417.97
8.2.70.0060.00317.88
8.2.60.0000.00818.30
8.2.50.0060.00318.10
8.2.40.0000.00922.50
8.2.30.0030.00619.64
8.2.20.0000.00818.43
8.2.10.0040.00418.46
8.2.00.0040.00417.86
8.1.290.0070.00330.84
8.1.280.0180.00025.92
8.1.270.0070.00022.49
8.1.260.0050.00226.35
8.1.250.0040.00428.09
8.1.240.0100.00022.77
8.1.230.0080.00421.34
8.1.220.0060.00318.03
8.1.210.0030.00619.10
8.1.200.0030.00617.63
8.1.190.0060.00317.48
8.1.180.0030.00618.10
8.1.170.0080.00019.09
8.1.160.0030.00322.42
8.1.150.0040.00419.14
8.1.140.0080.00019.97
8.1.130.0000.00719.45
8.1.120.0000.00717.82
8.1.110.0040.00417.77
8.1.100.0020.00517.62
8.1.90.0000.00817.70
8.1.80.0040.00417.74
8.1.70.0000.00717.80
8.1.60.0080.00017.82
8.1.50.0030.00517.71
8.1.40.0030.00617.84
8.1.30.0080.00017.84
8.1.20.0040.00417.99
8.1.10.0040.00417.91
8.1.00.0030.00717.88
8.0.300.0000.00720.41
8.0.290.0000.00917.00
8.0.280.0080.00018.80
8.0.270.0030.00317.53
8.0.260.0000.00717.59
8.0.250.0000.00717.30
8.0.240.0000.00717.32
8.0.230.0030.00417.35
8.0.220.0030.00617.32
8.0.210.0000.00817.24
8.0.200.0030.00317.30
8.0.190.0000.00917.30
8.0.180.0040.00417.30
8.0.170.0070.00017.25
8.0.160.0040.00417.28
8.0.150.0040.00417.29
8.0.140.0040.00417.21
8.0.130.0040.00413.76
8.0.120.0030.00617.28
8.0.110.0030.00517.19
8.0.100.0040.00417.20
8.0.90.0030.00617.24
8.0.80.0060.01317.20
8.0.70.0000.00817.21
8.0.60.0000.00817.21
8.0.50.0020.00517.20
8.0.30.0130.00617.31
8.0.20.0130.00617.41
8.0.10.0070.00017.16
8.0.00.0160.00017.01
7.4.330.0050.00015.55
7.4.320.0050.00216.87
7.4.300.0030.00316.91
7.4.290.0030.00316.71
7.4.280.0000.00716.68
7.4.270.0070.00016.84
7.4.260.0000.00716.72
7.4.250.0050.00216.78
7.4.240.0060.00316.95
7.4.230.0000.00816.95
7.4.220.0040.01316.72
7.4.210.0100.00916.86
7.4.200.0040.00416.94
7.4.160.0050.01116.88
7.4.150.0090.00917.40
7.4.140.0130.00417.86
7.4.130.0090.00816.83
7.4.120.0080.01116.78
7.3.330.0000.00613.59
7.3.320.0060.00013.33
7.3.310.0030.00316.54
7.3.300.0030.00316.57
7.3.290.0090.00916.68
7.3.280.0100.00716.63
7.3.270.0090.00917.40
7.3.260.0130.00816.83
7.3.250.0090.00916.77
7.3.240.0070.01416.73
7.1.00.0130.05322.71

preferences:
31.07 ms | 401 KiB | 5 Q