3v4l.org

run code in 300+ PHP versions simultaneously
<?php // "Create" the document. $xml = new DOMDocument( "1.0", "ISO-8859-15" ); $xml->xmlVersion = null; $xml->standalone = true; $xml->doctype = null; // Create some elements. $xml_album = $xml->createElement( "Album" ); $xml_track = $xml->createElement( "Track", "The ninth symphony" ); // Set the attributes. $xml_track->setAttribute( "length", "0:01:15" ); $xml_track->setAttribute( "bitrate", "64kb/s" ); $xml_track->setAttribute( "channels", "2" ); // Create another element, just to show you can add any (realistic to computer) number of sublevels. $xml_note = $xml->createElement( "Note", "The last symphony composed by Ludwig van Beethoven." ); // Append the whole bunch. $xml_track->appendChild( $xml_note ); $xml_album->appendChild( $xml_track ); // Repeat the above with some different values.. $xml_track = $xml->createElement( "Track", "Highway Blues" ); $xml_track->setAttribute( "length", "0:01:33" ); $xml_track->setAttribute( "bitrate", "64kb/s" ); $xml_track->setAttribute( "channels", "2" ); $xml_album->appendChild( $xml_track ); $xml->appendChild( $xml_album ); // Parse the XML. print $xml->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.60.0040.01517.00
8.3.50.0090.01121.99
8.3.40.0080.00818.96
8.3.30.0070.00718.84
8.3.20.0000.00720.18
8.3.10.0040.00423.77
8.3.00.0040.00419.50
8.2.180.0140.00316.74
8.2.170.0130.00622.96
8.2.160.0070.00720.52
8.2.150.0000.00825.66
8.2.140.0080.00024.66
8.2.130.0060.00319.36
8.2.120.0080.00026.35
8.2.110.0040.00721.00
8.2.100.0040.00817.79
8.2.90.0030.00519.28
8.2.80.0080.00017.97
8.2.70.0000.00817.63
8.2.60.0040.00417.80
8.2.50.0090.00018.10
8.2.40.0040.00420.57
8.2.30.0000.00820.64
8.2.20.0090.00017.63
8.2.10.0000.00817.89
8.2.00.0040.00417.95
8.1.280.0120.00325.92
8.1.270.0100.00023.81
8.1.260.0080.00028.09
8.1.250.0050.00328.09
8.1.240.0080.00319.28
8.1.230.0040.00722.82
8.1.220.0040.00417.74
8.1.210.0000.00819.89
8.1.200.0060.00317.23
8.1.190.0080.00017.23
8.1.180.0050.00318.10
8.1.170.0000.00818.51
8.1.160.0000.00721.86
8.1.150.0040.00418.85
8.1.140.0030.00519.51
8.1.130.0040.00417.73
8.1.120.0070.00017.44
8.1.110.0000.00717.41
8.1.100.0050.00317.46
8.1.90.0000.00717.43
8.1.80.0030.00417.45
8.1.70.0030.00617.45
8.1.60.0030.00617.54
8.1.50.0040.00417.63
8.1.40.0070.00417.61
8.1.30.0030.00617.64
8.1.20.0040.00417.63
8.1.10.0040.00417.56
8.1.00.0040.00417.49
8.0.300.0030.00319.94
8.0.290.0050.00316.75
8.0.280.0030.00318.45
8.0.270.0040.00417.16
8.0.260.0030.00317.33
8.0.250.0040.00417.06
8.0.240.0000.00716.97
8.0.230.0000.00716.99
8.0.220.0070.00016.93
8.0.210.0050.00216.93
8.0.200.0000.00716.98
8.0.190.0060.00316.94
8.0.180.0070.00016.89
8.0.170.0040.00416.95
8.0.160.0000.00717.04
8.0.150.0040.00416.88
8.0.140.0070.00016.94
8.0.130.0050.00013.41
8.0.120.0000.00816.93
8.0.110.0000.00817.01
8.0.100.0040.00416.94
8.0.90.0030.00416.79
8.0.80.0120.00617.04
8.0.70.0040.00417.03
8.0.60.0000.00716.79
8.0.50.0050.00316.81
8.0.30.0060.01017.30
8.0.20.0110.00817.40
8.0.10.0070.00016.98
8.0.00.0080.00916.63
7.4.330.0050.00016.85
7.4.320.0000.00616.39
7.4.300.0070.00016.62
7.4.290.0030.00316.54
7.4.280.0080.00016.54
7.4.270.0070.00016.61
7.4.260.0000.00716.57
7.4.250.0000.00816.57
7.4.240.0010.00616.67
7.4.230.0030.00316.29
7.4.220.0120.00616.68
7.4.210.0100.00816.67
7.4.200.0080.00016.44
7.4.160.0040.01116.64
7.4.150.0100.00717.40
7.4.140.0100.01317.86
7.4.130.0130.00416.44
7.4.120.0080.00916.62
7.4.110.0140.00716.47
7.4.100.0130.00616.60
7.4.90.0150.00316.49
7.4.80.0090.00919.39
7.4.70.0140.00316.46
7.4.60.0100.00716.35
7.4.50.0000.01116.54
7.4.40.0070.01016.31
7.4.30.0030.01916.53
7.4.00.0030.01015.20
7.3.330.0000.00613.11
7.3.320.0000.00513.21
7.3.310.0030.00316.24
7.3.300.0000.00716.34
7.3.290.0000.00716.39
7.3.280.0100.01116.27
7.3.270.0110.00617.40
7.3.260.0090.00916.33
7.3.250.0090.00816.40
7.3.240.0110.00616.47
7.3.230.0070.01016.50
7.3.210.0070.01016.49
7.3.200.0080.01216.27
7.3.190.0070.01016.35
7.3.180.0090.00616.53
7.3.170.0130.00916.35
7.3.160.0070.01016.27
7.2.330.0090.00916.66
7.2.320.0150.00316.59
7.2.310.0070.01116.61
7.2.300.0100.00716.63
7.2.290.0070.01016.48
7.2.60.0030.01016.38
7.2.00.0000.00919.10
7.1.200.0000.00915.61
7.1.100.0030.00918.29
7.1.70.0000.00717.13
7.1.60.0170.00719.48
7.1.50.0040.00716.76
7.1.00.0000.08022.57
7.0.200.0110.00714.77
7.0.60.0070.06319.92
7.0.50.0000.06317.93
7.0.40.0170.04320.27
7.0.30.0300.03320.00
7.0.20.0270.08320.17
7.0.10.0070.07720.00
7.0.00.0000.04320.04
5.6.280.0070.02720.89
5.6.210.0070.07720.57
5.6.200.0030.07718.18
5.6.190.0130.07720.60
5.6.180.0370.07720.41
5.6.170.0200.06320.48
5.6.160.0100.07720.47
5.6.150.0000.04018.21
5.6.140.0070.07018.17
5.6.130.0030.05718.15
5.6.120.0130.07721.12
5.6.110.0000.08021.02
5.6.100.0070.06720.96
5.6.90.0170.07021.02
5.6.80.0070.08020.40
5.5.350.4330.04020.46
5.5.340.0030.08718.02
5.5.330.0070.07720.07
5.5.320.0070.08320.29
5.5.310.0300.03320.29
5.5.300.0130.07317.91
5.5.290.0070.06718.03
5.5.280.0130.06020.78
5.5.270.0130.04720.76
5.5.260.0170.07320.88
5.5.250.0070.06020.58
5.5.240.0100.03320.13

preferences:
63.05 ms | 401 KiB | 5 Q