3v4l.org

run code in 300+ PHP versions simultaneously
<?php $xml = '<?xml version="1.0" encoding="UTF-8"?> <root>Тест кириллицы</root> '; $original = new DOMDocument; $original->loadXML($xml); echo $original->saveXML(); echo PHP_EOL . PHP_EOL; // this is code from \SebastianBergmann\Comparator\DOMNodeComparator::nodeToText $document = new DOMDocument; @$document->loadXML($original->C14N()); echo $document->saveXML(); echo PHP_EOL . PHP_EOL; // if I add utf-8 xml header then document is good $document = new DOMDocument; @$document->loadXML('<?xml version="1.0" encoding="UTF-8"?>' . PHP_EOL . $original->C14N()); echo $document->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.130.0040.00418.55
8.3.120.0080.00019.12
8.3.110.0080.00020.94
8.3.100.0070.01018.56
8.3.90.0100.00026.77
8.3.80.0110.00016.88
8.3.70.0150.00617.00
8.3.60.0150.00318.66
8.3.50.0110.00717.67
8.3.40.0150.00019.04
8.3.30.0150.00019.02
8.3.20.0000.00822.33
8.3.10.0080.00021.02
8.3.00.0040.00422.11
8.2.250.0080.00016.95
8.2.240.0110.00019.34
8.2.230.0090.00322.58
8.2.220.0060.00924.06
8.2.210.0080.00026.77
8.2.200.0090.00016.75
8.2.190.0100.00717.00
8.2.180.0180.00018.58
8.2.170.0000.01422.96
8.2.160.0060.00920.69
8.2.150.0040.00425.66
8.2.140.0040.00424.66
8.2.130.0050.00226.16
8.2.120.0040.00426.16
8.2.110.0100.00022.48
8.2.100.0080.00320.74
8.2.90.0080.00018.00
8.2.80.0050.00319.38
8.2.70.0050.00318.13
8.2.60.0000.00818.34
8.2.50.0000.00918.10
8.2.40.0050.00319.73
8.2.30.0070.00020.68
8.2.20.0080.00318.33
8.2.10.0040.00419.29
8.2.00.0050.00218.42
8.1.300.0080.00820.28
8.1.290.0090.00030.84
8.1.280.0030.01525.92
8.1.270.0040.00424.66
8.1.260.0040.00426.35
8.1.250.0060.00328.09
8.1.240.0090.00022.78
8.1.230.0070.00319.25
8.1.220.0040.00718.03
8.1.210.0040.00418.77
8.1.200.0050.00517.72
8.1.190.0030.00517.73
8.1.180.0040.00418.10
8.1.170.0040.00419.06
8.1.160.0040.00419.23
8.1.150.0030.00519.14
8.1.140.0040.00420.89
8.1.130.0000.00717.65
8.1.120.0040.00417.81
8.1.110.0000.00917.64
8.1.100.0000.00717.64
8.1.90.0060.00317.81
8.1.80.0040.00417.80
8.1.70.0030.00317.80
8.1.60.0040.00417.88
8.1.50.0000.00817.71
8.1.40.0040.00417.70
8.1.30.0000.00817.82
8.1.20.0030.00717.92
8.1.10.0080.00017.91
8.1.00.0040.00417.86
8.0.300.0000.00719.98
8.0.290.0070.00017.00
8.0.280.0000.00718.73
8.0.270.0040.00317.43
8.0.260.0030.00617.02
8.0.250.0040.00417.14
8.0.240.0050.00517.29
8.0.230.0040.00417.23
8.0.220.0040.00417.24
8.0.210.0000.00717.21
8.0.200.0030.00317.27
8.0.190.0030.00417.13
8.0.180.0040.00417.26
8.0.170.0000.00817.23
8.0.160.0000.00717.25
8.0.150.0000.00817.16
8.0.140.0040.00417.04
8.0.130.0030.00313.66
8.0.120.0000.00717.04
8.0.110.0040.00417.18
8.0.100.0030.00517.27
8.0.90.0040.00417.13
8.0.80.0060.00917.23
8.0.70.0040.00417.16
8.0.60.0040.00416.93
8.0.50.0020.00517.19
8.0.30.0120.00717.41
8.0.20.0130.00617.17
8.0.10.0050.00317.37
8.0.00.0090.00817.02
7.4.330.0040.00015.55
7.4.320.0060.00016.92
7.4.300.0000.00716.75
7.4.290.0070.00316.95
7.4.280.0060.00616.70
7.4.270.0030.00316.74
7.4.260.0030.00516.70
7.4.250.0030.00516.82
7.4.240.0040.00416.88
7.4.230.0030.00316.83
7.4.220.0040.00416.66
7.4.210.0080.00916.97
7.4.200.0000.00716.99
7.4.160.0090.01116.79
7.4.140.0100.00717.86
7.4.130.0090.00916.85
7.4.120.0150.00816.68
7.4.110.0090.00916.71
7.4.100.0210.00316.85
7.4.90.0090.00916.57
7.4.80.0120.00919.39
7.4.70.0150.00616.77
7.4.60.0100.01016.67
7.4.50.0100.00716.75
7.4.40.0120.00916.71
7.4.00.0100.00515.01
7.3.330.0050.00013.33
7.3.320.0030.00313.30
7.3.310.0040.00416.42
7.3.300.0040.00416.58
7.3.290.0000.00716.52
7.3.280.0060.01016.45
7.3.260.0100.00816.65
7.3.230.0130.00316.79
7.3.210.0070.01016.65
7.3.200.0110.00816.84
7.3.190.0090.00616.60
7.3.180.0100.00616.48
7.3.170.0120.00416.71
7.3.160.0060.01216.45
7.3.120.0040.01414.95
7.3.110.0070.00714.66
7.3.100.0040.00714.79
7.3.90.0040.01214.88
7.3.80.0130.00314.61
7.3.70.0030.00715.02
7.3.60.0090.00614.69
7.3.50.0070.00814.83
7.3.40.0020.00914.65
7.3.30.0070.00714.89
7.3.20.0080.00616.78
7.3.10.0030.00816.77
7.3.00.0040.00816.65
7.2.330.0090.00916.75
7.2.320.0180.00316.99
7.2.310.0150.01116.96
7.2.300.0100.00616.93
7.2.290.0120.00817.09
7.2.250.0040.01515.26
7.2.240.0100.01015.27
7.2.230.0130.00314.91
7.2.220.0100.00714.90
7.2.210.0060.01315.15
7.2.200.0050.00514.95
7.2.190.0030.01415.20
7.2.180.0040.00914.97
7.2.170.0090.00315.05
7.2.160.0160.00614.95
7.2.150.0120.01216.93
7.2.140.0120.00016.88
7.2.130.0060.00916.89
7.2.120.0130.00616.88
7.2.110.0100.01016.98
7.2.100.0150.00616.95
7.2.90.0120.00416.86
7.2.80.0100.00617.12
7.2.70.0190.00517.19
7.2.60.0100.00316.98
7.2.50.0000.01117.20
7.2.40.0080.00416.95
7.2.30.0110.00416.98
7.2.20.0060.00617.14
7.2.10.0080.01516.89
7.2.00.0140.00916.91
7.1.330.0030.01015.64
7.1.320.0000.01715.60
7.1.310.0030.01215.78
7.1.300.0100.00315.84
7.1.290.0080.00415.68
7.1.280.0060.00715.92
7.1.270.0080.00915.74
7.1.260.0090.00215.77
7.1.250.0060.01515.54

preferences:
18.75 ms | 403 KiB | 5 Q