3v4l.org

run code in 300+ PHP versions simultaneously
<?php $xml = <<<XML <?xml version='1.0' standalone='yes'?> <movies> <movie> <title>PHP: Behind the Parser</title> <characters> <character> <name>Ms. Coder</name> <actor>Onlivia Actora</actor> </character> <character> <name>Mr. Coder</name> <actor>El Act&#211;r</actor> </character> </characters> <plot> So, this language. It's like, a programming language. Or is it a scripting language? All is revealed in this thrilling horror spoof of a documentary. </plot> <great-lines1> <line><![CDATA[always be testing!]]></line> </great-lines1> <great-lines2> <line>PHP solves all my web problems</line> <![CDATA[always be testing!]]> </great-lines2> <great-lines3> PHP solves all my web problems <![CDATA[always be testing!]]> </great-lines3> <rating type="thumbs">7</rating> <rating type="stars">5</rating> </movie> </movies> XML; $sml = new SimpleXMLElement ($xml); $result1 = $sml->xpath('/movies/movie/great-lines1/line'); $result2 = $sml->xpath('/movies/movie/great-lines2'); $result3 = $sml->xpath('/movies/movie/great-lines3'); var_dump($result1); var_dump($result2); var_dump($result3); echo "\n<br>--------------------\n"; echo (string) array_pop($result1); echo "\n<br>--------------------\n"; echo (string) array_pop($result2); echo "\n<br>--------------------\n"; echo (string) array_pop($result3);

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.0140.00018.43
8.3.50.0070.01422.18
8.3.40.0070.00719.17
8.3.30.0110.00419.43
8.3.20.0050.00320.54
8.3.10.0090.00020.78
8.3.00.0040.00417.84
8.2.180.0070.01116.97
8.2.170.0110.00422.96
8.2.160.0090.00620.77
8.2.150.0000.00824.18
8.2.140.0070.00024.66
8.2.130.0030.00626.16
8.2.120.0080.00022.67
8.2.110.0070.00322.75
8.2.100.0080.00418.21
8.2.90.0080.00019.55
8.2.80.0000.00817.97
8.2.70.0000.00917.88
8.2.60.0080.00418.17
8.2.50.0000.00818.13
8.2.40.0080.00018.53
8.2.30.0000.00719.64
8.2.20.0050.00318.01
8.2.10.0000.00818.48
8.2.00.0060.00318.21
8.1.280.0070.01425.92
8.1.270.0060.00324.20
8.1.260.0090.00026.35
8.1.250.0080.00028.09
8.1.240.0030.00722.54
8.1.230.0080.00319.54
8.1.220.0030.00618.16
8.1.210.0080.00018.77
8.1.200.0030.00617.60
8.1.190.0000.00817.61
8.1.180.0000.00818.10
8.1.170.0030.01018.78
8.1.160.0050.00222.31
8.1.150.0050.00319.18
8.1.140.0000.00817.78
8.1.130.0030.00318.15
8.1.120.0000.00817.91
8.1.110.0040.00417.86
8.1.100.0000.00717.64
8.1.90.0040.00417.93
8.1.80.0050.00217.73
8.1.70.0000.00717.68
8.1.60.0050.00317.99
8.1.50.0060.00317.75
8.1.40.0060.00317.94
8.1.30.0050.00318.05
8.1.20.0050.00318.10
8.1.10.0040.00417.89
8.1.00.0080.00017.70
8.0.300.0000.00718.77
8.0.290.0040.00417.38
8.0.280.0070.00018.80
8.0.270.0000.00717.55
8.0.260.0080.00017.61
8.0.250.0070.00017.51
8.0.240.0080.00017.46
8.0.230.0030.00317.42
8.0.220.0030.00317.37
8.0.210.0040.00417.38
8.0.200.0060.00017.42
8.0.190.0040.00417.20
8.0.180.0020.00517.41
8.0.170.0040.00417.24
8.0.160.0070.00017.18
8.0.150.0040.00417.34
8.0.140.0030.00517.13
8.0.130.0060.00313.59
8.0.120.0030.00617.31
8.0.110.0040.00417.16
8.0.100.0000.00717.25
8.0.90.0040.00417.34
8.0.80.0080.00817.25
8.0.70.0030.00517.10
8.0.60.0080.00017.42
8.0.50.0040.00417.16
8.0.30.0100.01217.52
8.0.20.0030.01617.44
8.0.10.0000.00817.44
8.0.00.0130.00917.38
7.4.330.0030.00315.57
7.4.320.0080.00016.78
7.4.300.0030.00316.81
7.4.290.0030.00316.86
7.4.280.0050.00516.98
7.4.270.0030.00516.90
7.4.260.0050.00216.96
7.4.250.0030.00616.99
7.4.240.0070.00217.02
7.4.230.0070.00017.03
7.4.220.0090.00917.01
7.4.210.0030.01016.87
7.4.200.0040.00416.84
7.4.160.0130.00316.79
7.4.150.0120.00617.40
7.4.140.0090.01017.86
7.4.130.0100.00816.98
7.4.120.0120.00916.97
7.4.110.0110.00716.85
7.4.100.0000.01817.04
7.4.90.0110.01116.79
7.4.80.0060.01218.80
7.4.70.0080.00816.77
7.4.60.0030.01316.82
7.4.50.0000.00916.80
7.4.40.0060.01216.64
7.4.30.0130.00616.95
7.4.00.0070.00715.24
7.3.330.0000.00513.56
7.3.320.0000.00613.54
7.3.310.0000.00716.79
7.3.300.0000.00816.65
7.3.290.0160.00316.73
7.3.280.0080.00816.68
7.3.270.0100.01317.40
7.3.260.0190.00616.64
7.3.250.0080.01016.74
7.3.240.0030.01816.54
7.3.230.0130.00516.99
7.3.210.0130.01016.92
7.3.200.0170.00319.39
7.3.190.0130.01016.60
7.3.180.0090.00916.63
7.3.170.0100.00716.73
7.3.160.0060.01416.72
7.3.00.0060.00616.67
7.2.330.0070.01317.06
7.2.320.0150.00917.12
7.2.310.0090.00916.81
7.2.300.0100.01317.03
7.2.290.0100.00716.84
7.2.130.0000.01016.86
7.2.120.0030.01016.80
7.2.110.0030.00816.79
7.2.100.0040.01116.91
7.2.90.0070.00716.97
7.2.80.0090.00616.99
7.2.70.0000.01116.90
7.2.60.0030.01216.88
7.2.50.0000.01016.82
7.2.40.0030.00917.19
7.2.30.0040.00816.87
7.2.20.0000.01417.01
7.2.10.0040.00816.80
7.2.00.0080.00518.33
7.1.250.0130.00015.95
7.1.240.0040.01115.68
7.1.230.0060.00315.64
7.1.220.0070.00716.01
7.1.210.0030.00715.73
7.1.200.0040.00815.86
7.1.190.0040.00715.76
7.1.180.0060.00615.75
7.1.170.0030.00715.86
7.1.160.0000.01015.91
7.1.150.0060.00315.75
7.1.140.0050.00515.73
7.1.130.0100.00016.09
7.1.120.0100.00315.84
7.1.110.0080.00415.73
7.1.100.0050.00617.02
7.1.90.0030.01015.77
7.1.80.0070.00716.10
7.1.70.0040.00516.46
7.1.60.0090.00516.73
7.1.50.0040.01416.43
7.1.40.0040.00815.63
7.1.30.0000.01115.74
7.1.20.0040.00715.73
7.1.10.0000.00815.73
7.1.00.0020.04319.19
7.0.330.0060.00915.52
7.0.320.0030.00515.38
7.0.310.0000.01415.27
7.0.300.0040.01115.37
7.0.290.0050.00315.38
7.0.280.0070.00315.26
7.0.270.0080.00815.47
7.0.260.0140.00015.27
7.0.250.0000.01215.78
7.0.240.0030.00915.60
7.0.230.0070.00015.60
7.0.220.0030.01015.62
7.0.210.0030.00615.44
7.0.200.0020.01016.37
7.0.190.0040.00415.66
7.0.180.0060.00615.57
7.0.170.0000.01215.25
7.0.160.0070.00715.66
7.0.150.0130.00015.59
7.0.140.0040.04018.85
7.0.130.0000.01315.55
7.0.120.0070.00015.77
7.0.110.0070.00315.63
7.0.100.0060.00615.52
7.0.90.0070.00715.45
7.0.80.0100.00315.56
7.0.70.0030.00615.45
7.0.60.0090.04317.81
7.0.50.0120.03916.88
7.0.40.0070.02316.83
7.0.30.0290.03916.90
7.0.20.0130.02316.97
7.0.10.0020.05217.04
7.0.00.0080.02516.87
5.6.380.0030.00714.94
5.6.370.0040.00814.53
5.6.360.0000.01314.54
5.6.350.0030.00914.43
5.6.340.0000.01014.50
5.6.330.0000.01014.24
5.6.320.0050.00514.37
5.6.310.0030.01014.36
5.6.300.0030.00914.36
5.6.290.0060.00614.84
5.6.280.0020.04417.81
5.6.270.0110.00314.90
5.6.260.0070.00714.59
5.6.250.0060.00614.24
5.6.240.0030.01014.62
5.6.230.0070.00414.33
5.6.220.0040.01114.30
5.6.210.0070.02517.44
5.6.200.0030.02716.26
5.6.190.0030.03617.43
5.6.180.0260.02617.54
5.6.170.0170.04317.33
5.6.160.0070.02517.40
5.6.150.0040.04616.24
5.6.140.0060.02116.46
5.6.130.0090.04316.25
5.6.120.0070.04017.78
5.6.110.0070.04617.86
5.6.100.0070.04317.76
5.6.90.0080.04317.72
5.6.80.0070.04217.53
5.6.70.0040.01114.38
5.6.60.0130.00314.22
5.6.50.0060.01014.29
5.6.40.0040.00814.57
5.6.30.0040.01114.30
5.6.20.0110.00414.17
5.6.10.0060.00914.39
5.6.00.0100.00314.25
5.5.380.0030.00711.20
5.5.370.0090.00311.18
5.5.360.0030.00311.18
5.5.350.0080.04415.89
5.5.340.0020.02314.67
5.5.330.0060.04315.79
5.5.320.0130.02715.86
5.5.310.0070.03315.77
5.5.300.0070.04014.71
5.5.290.0020.04214.70
5.5.280.0050.02316.13
5.5.270.0050.02916.08
5.5.260.0100.02716.17
5.5.250.0030.02515.97
5.5.240.0120.03815.85
5.5.230.0000.01211.30
5.5.220.0090.00311.24
5.5.210.0060.00611.23
5.5.200.0080.00411.18
5.5.190.0030.00911.24
5.5.180.0060.00611.36
5.5.170.0000.00711.18
5.5.160.0070.00311.18
5.5.150.0080.00311.20
5.5.140.0000.00811.18
5.5.130.0060.00311.33
5.5.120.0030.01011.27
5.5.110.0060.00611.29
5.5.100.0090.00311.25
5.5.90.0030.00611.20
5.5.80.0070.00011.18
5.5.70.0070.00411.18
5.5.60.0060.00311.28
5.5.50.0030.00711.20
5.5.40.0030.01011.32
5.5.30.0060.00311.18
5.5.20.0070.00311.18
5.5.10.0080.00311.29
5.5.00.0040.00411.29
5.4.450.0000.02615.43
5.4.440.0000.02515.40
5.4.430.0020.02615.44
5.4.420.0050.02015.46
5.4.410.0030.02215.29
5.4.400.0030.02015.26
5.4.390.0010.02315.19
5.4.380.0100.01715.25
5.4.370.0020.02215.28
5.4.360.0050.02215.13
5.4.350.0000.02415.28
5.4.340.0020.04015.24
5.4.330.0040.00711.18
5.4.320.0030.02215.30
5.4.310.0050.02515.24
5.4.300.0040.02615.34
5.4.290.0050.02215.24
5.4.280.0060.03815.23
5.4.270.0030.04115.20
5.4.260.0020.04515.20
5.4.250.0050.04015.19
5.4.240.0020.03215.19
5.4.230.0090.03515.21
5.4.220.0050.04215.24
5.4.210.0020.03015.32
5.4.200.0030.03815.13
5.4.190.0030.04015.31
5.4.180.0080.03115.12
5.4.170.0090.02515.27
5.4.160.0050.02915.27
5.4.150.0020.04115.20
5.4.140.0030.03813.81
5.4.130.0050.03813.87
5.4.120.0080.02013.79
5.4.110.0070.03713.75
5.4.100.0060.03813.85
5.4.90.0070.04013.89
5.4.80.0080.03713.77
5.4.70.0050.03213.88
5.4.60.0080.03313.86
5.4.50.0020.03213.83
5.4.40.0040.02113.78
5.4.30.0030.03513.88
5.4.20.0050.02713.94
5.4.10.0030.02313.78
5.4.00.0050.03813.64
5.3.290.0030.02012.99
5.3.280.0020.03312.99
5.3.270.0020.03112.99
5.3.260.0010.03812.99
5.3.250.0030.04213.00
5.3.240.0020.04212.99
5.3.230.0090.03612.99
5.3.220.0050.03712.99
5.3.210.0060.03812.99
5.3.200.0030.04012.99
5.3.190.0080.03812.99
5.3.180.0060.03412.99
5.3.170.0060.03512.99
5.3.160.0050.03812.99
5.3.150.0040.03012.99
5.3.140.0020.02813.00
5.3.130.0030.04312.99
5.3.120.0060.03812.99
5.3.110.0020.03012.99
5.3.100.0040.04012.99
5.3.90.0030.03412.99
5.3.80.0050.04012.99
5.3.70.0020.04212.99
5.3.60.0070.03712.99
5.3.50.0030.04412.99
5.3.40.0020.04012.99
5.3.30.0030.03312.99
5.3.20.0040.02312.99
5.3.10.0020.03012.99
5.3.00.0020.03812.99
5.2.170.0030.02812.99
5.2.160.0060.03012.99
5.2.150.0030.02112.99
5.2.140.0040.02912.99
5.2.130.0050.03012.99
5.2.120.0050.02312.99
5.2.110.0060.02512.99
5.2.100.0030.03412.99
5.2.90.0020.02712.99
5.2.80.0060.02112.99
5.2.70.0000.03712.99
5.2.60.0040.03712.99
5.2.50.0070.02812.99
5.2.40.0020.03512.99
5.2.30.0060.03112.99
5.2.20.0040.03312.99
5.2.10.0060.02712.99
5.2.00.0060.02512.99
5.1.60.0030.02012.99
5.1.50.0070.02512.99
5.1.40.0030.02712.99
5.1.30.0030.03212.99
5.1.20.0070.02712.99
5.1.10.0020.03212.99
5.1.00.0000.02512.99
5.0.50.0020.03012.99
5.0.40.0050.02012.99
5.0.30.0000.03312.99
5.0.20.0040.02212.99
5.0.10.0000.02112.99
5.0.00.0050.02212.99
4.4.90.0030.01812.99
4.4.80.0020.02012.99
4.4.70.0030.01512.99
4.4.60.0000.02112.99
4.4.50.0010.01912.99
4.4.40.0030.02812.99
4.4.30.0030.01812.99
4.4.20.0010.01812.99
4.4.10.0020.01712.99
4.4.00.0010.02812.99
4.3.110.0000.01812.99
4.3.100.0020.01512.99
4.3.90.0020.01812.99
4.3.80.0000.03012.99
4.3.70.0000.02212.99
4.3.60.0010.01512.99
4.3.50.0000.02012.99
4.3.40.0020.02812.99
4.3.30.0020.01912.99
4.3.20.0050.01312.99
4.3.10.0040.01212.99
4.3.00.0050.01212.99

preferences:
46.17 ms | 401 KiB | 5 Q