3v4l.org

run code in 300+ PHP versions simultaneously
<?php /** * How to get SVG tag content with PHP * @link http://stackoverflow.com/a/16234458/367456 */ $string = <<<BUFFER <?xml version="1.0" encoding="utf-8"?> <!-- comment --> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="202.5px" height="226.084px" viewBox="0 0 202.5 226.084" enable-background="new 0 0 202.5 226.084" xml:space="preserve"> <g> <path d="M0,13.628c47.7940,13.628z"/> <polygon points="108.48,207.874 145.506,196.948 145.506,204.536 108.48,214.854 "/> <path fill="none" stroke="#000000" d="M114.55,223.959"/> </g> </svg> BUFFER; $xml = simplexml_load_string($string); $xml->registerXPathNamespace('svg', 'http://www.w3.org/2000/svg'); $xml->xpath('path')[0]->asXML('php://output');

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.0090.00618.81
8.3.50.0120.01022.16
8.3.40.0080.00819.21
8.3.30.0130.00319.14
8.3.20.0030.00619.10
8.3.10.0040.00421.47
8.3.00.0040.00423.91
8.2.180.0110.00717.13
8.2.170.0080.00822.96
8.2.160.0040.01120.69
8.2.150.0060.00324.18
8.2.140.0000.00824.66
8.2.130.0080.00026.16
8.2.120.0000.00721.47
8.2.110.0030.00622.48
8.2.100.0040.00818.41
8.2.90.0050.00319.45
8.2.80.0040.00419.52
8.2.70.0000.00818.13
8.2.60.0050.00318.30
8.2.50.0090.00018.07
8.2.40.0080.00018.59
8.2.30.0000.00719.77
8.2.20.0000.00718.03
8.2.10.0000.00818.11
8.2.00.0040.00418.09
8.1.280.0090.00925.92
8.1.270.0040.00423.99
8.1.260.0030.00526.35
8.1.250.0040.00428.09
8.1.240.0060.00322.71
8.1.230.0100.00021.26
8.1.220.0030.00518.77
8.1.210.0090.00019.22
8.1.200.0040.00417.60
8.1.190.0080.00017.77
8.1.180.0000.00818.10
8.1.170.0040.00418.99
8.1.160.0000.00719.18
8.1.150.0050.00318.93
8.1.140.0070.00017.72
8.1.130.0040.00418.23
8.1.120.0000.00717.75
8.1.110.0000.00817.62
8.1.100.0030.00517.88
8.1.90.0050.00217.90
8.1.80.0000.00717.83
8.1.70.0030.00317.63
8.1.60.0040.00417.99
8.1.50.0030.00617.91
8.1.40.0040.00417.98
8.1.30.0040.00418.10
8.1.20.0040.00418.11
8.1.10.0060.00317.88
8.1.00.0030.00517.85
8.0.300.0070.00020.14
8.0.290.0070.00017.55
8.0.280.0040.00418.77
8.0.270.0030.00317.56
8.0.260.0050.00317.23
8.0.250.0000.00717.42
8.0.240.0020.00517.35
8.0.230.0000.00717.18
8.0.220.0030.00417.35
8.0.210.0000.00817.26
8.0.200.0000.00617.20
8.0.190.0030.00517.44
8.0.180.0030.00517.42
8.0.170.0000.00817.39
8.0.160.0040.00417.40
8.0.150.0020.00517.25
8.0.140.0000.00717.19
8.0.130.0030.00313.77
8.0.120.0090.00017.09
8.0.110.0070.00017.06
8.0.100.0080.00017.41
8.0.90.0040.00417.18
8.0.80.0060.00917.20
8.0.70.0000.00817.17
8.0.60.0040.00417.09
8.0.50.0040.00417.21
8.0.30.0110.00717.54
8.0.20.0140.00717.41
8.0.10.0070.00017.41
8.0.00.0080.01017.13
7.4.330.0030.00317.10
7.4.320.0000.00616.99
7.4.300.0000.00717.05
7.4.290.0000.00816.89
7.4.280.0110.00016.98
7.4.270.0000.00816.87
7.4.260.0030.00313.66
7.4.250.0050.00316.95
7.4.240.0000.00816.99
7.4.230.0030.00316.98
7.4.220.0070.02016.95
7.4.210.0090.00816.96
7.4.200.0030.00317.08
7.4.190.0000.00717.03
7.4.160.0130.00316.75
7.4.150.0110.00717.40
7.4.140.0070.01117.86
7.4.130.0110.01116.98
7.4.120.0090.00916.87
7.4.110.0070.01016.88
7.4.100.0100.01416.85
7.4.90.0060.01216.80
7.4.80.0040.01419.39
7.4.70.0050.01117.00
7.4.60.0060.01116.92
7.4.50.0020.00216.91
7.4.40.0070.01022.77
7.4.30.0100.00716.92
7.4.10.0030.01315.18
7.4.00.0090.00815.30
7.3.330.0020.00313.47
7.3.320.0030.00313.34
7.3.310.0050.00316.74
7.3.300.0070.00016.68
7.3.290.0120.00616.77
7.3.280.0120.00816.74
7.3.270.0170.00017.40
7.3.260.0100.00918.24
7.3.250.0100.00916.70
7.3.240.0110.00616.98
7.3.230.0120.00416.86
7.3.210.0110.00516.73
7.3.200.0150.00719.39
7.3.190.0100.00716.66
7.3.180.0130.00316.89
7.3.170.0100.01016.68
7.3.160.0130.00316.66
7.3.130.0000.01714.92
7.3.120.0070.00815.07
7.3.110.0070.01314.78
7.3.100.0040.01014.97
7.3.90.0060.00615.06
7.3.80.0110.00315.13
7.3.70.0060.00814.73
7.3.60.0050.00914.86
7.3.50.0080.00814.83
7.3.40.0070.00714.91
7.3.30.0030.01014.88
7.3.20.0040.00816.76
7.3.10.0050.01016.78
7.3.00.0090.00316.78
7.2.330.0120.00616.93
7.2.320.0060.01317.16
7.2.310.0090.00916.85
7.2.300.0110.00617.02
7.2.290.0070.01017.21
7.2.260.0040.01515.02
7.2.250.0020.01615.12
7.2.240.0070.00714.86
7.2.230.0100.00515.19
7.2.220.0000.01115.26
7.2.210.0070.00715.09
7.2.200.0070.00315.22
7.2.190.0070.00615.13
7.2.180.0050.01214.99
7.2.170.0050.01315.19
7.2.160.0060.00615.34
7.2.150.0070.00717.00
7.2.140.0130.00317.01
7.2.130.0040.00816.99
7.2.120.0070.00717.09
7.2.110.0070.00716.99
7.2.100.0090.00616.85
7.2.90.0000.01616.91
7.2.80.0070.01017.10
7.2.70.0100.00717.01
7.2.60.0010.01216.99
7.2.50.0120.00417.08
7.2.40.0030.00617.03
7.2.30.0100.00717.13
7.2.20.0030.00917.11
7.2.10.0000.01516.99
7.2.00.0030.01218.20
7.1.330.0030.01016.09
7.1.320.0100.00515.93
7.1.310.0060.00615.94
7.1.300.0060.00816.02
7.1.290.0120.00515.85
7.1.280.0020.01015.92
7.1.270.0070.00615.97
7.1.260.0080.00416.01
7.1.250.0030.01216.17
7.1.240.0090.00615.92
7.1.230.0090.00615.93
7.1.220.0060.01215.82
7.1.210.0080.00815.88
7.1.200.0070.00616.03
7.1.190.0060.00615.98
7.1.180.0070.01016.02
7.1.170.0040.01215.92
7.1.160.0040.00815.83
7.1.150.0100.00715.87
7.1.140.0070.00715.99
7.1.130.0030.00915.88
7.1.120.0060.00916.00
7.1.110.0070.01115.81
7.1.100.0070.00617.05
7.1.90.0040.00715.94
7.1.80.0070.00716.04
7.1.70.0040.00716.61
7.1.60.0050.01317.48
7.1.50.0090.01216.61
7.1.40.0070.00415.68
7.1.30.0140.00015.86
7.1.20.0030.01015.99
7.1.10.0000.01415.91
7.1.00.0020.04219.27
7.0.330.0040.00815.48
7.0.320.0060.00615.54
7.0.310.0060.01015.47
7.0.300.0070.00715.59
7.0.290.0090.00615.45
7.0.280.0090.00615.39
7.0.270.0080.00315.69
7.0.260.0030.01015.73
7.0.250.0120.00615.46
7.0.240.0060.00915.45
7.0.230.0060.00615.79
7.0.220.0040.01215.68
7.0.210.0000.01115.59
7.0.200.0030.00716.41
7.0.190.0000.01715.52
7.0.180.0130.00315.45
7.0.170.0060.00615.66
7.0.160.0070.00715.61
7.0.150.0040.01115.47
7.0.140.0020.04018.95
7.0.130.0070.00715.44
7.0.120.0030.01015.45
7.0.110.0030.00515.56
7.0.100.0080.00415.63
7.0.90.0030.01015.62
7.0.80.0000.01215.53
7.0.70.0050.00315.54
7.0.60.0050.03717.80
7.0.50.0070.04316.88
7.0.40.0090.02017.14
7.0.30.0120.02616.95
7.0.20.0220.03216.90
7.0.10.0130.04816.95
7.0.00.0150.04016.99
5.6.400.0000.01314.59
5.6.390.0000.01514.46
5.6.380.0070.00314.80
5.6.370.0130.00314.65
5.6.360.0110.00414.68
5.6.350.0060.00614.89
5.6.340.0070.01014.41
5.6.330.0090.00314.73
5.6.320.0100.00614.86
5.6.310.0030.00914.39
5.6.300.0090.00014.60
5.6.290.0090.00314.79
5.6.280.0050.04017.91
5.6.270.0030.00614.70
5.6.260.0160.00014.29
5.6.250.0030.01014.51
5.6.240.0060.00614.55
5.6.230.0080.00614.56
5.6.220.0080.00014.84
5.6.210.0060.02317.54
5.6.200.0060.04516.47
5.6.190.0060.04517.61
5.6.180.0060.04817.57
5.6.170.0130.04417.65
5.6.160.0060.02317.40
5.6.150.0050.03216.36
5.6.140.0070.03716.42
5.6.130.0060.04316.57
5.6.120.0090.04117.83
5.6.110.0020.04917.72
5.6.100.0140.03017.99
5.6.90.0090.03717.96
5.6.80.0090.03917.53
5.6.70.0090.03417.47
5.6.60.0030.01014.45
5.6.50.0070.00714.39
5.6.40.0160.00014.52
5.6.30.0090.00014.39
5.6.20.0070.00714.38
5.6.10.0040.00814.58
5.6.00.0030.01014.28
5.5.380.0040.01114.40
5.5.370.0090.00414.32
5.5.360.0140.00414.43
5.5.350.0200.04117.63
5.5.340.0070.02216.30
5.5.330.0050.03217.58
5.5.320.0020.02617.63
5.5.310.0120.03517.51
5.5.300.0080.03616.38
5.5.290.0030.04716.42
5.5.280.0020.04917.76
5.5.270.0030.02917.71
5.5.260.0030.04817.70
5.5.250.0130.03817.38
5.5.240.0110.03317.34
5.5.230.0040.00714.18
5.5.220.0070.00714.43
5.5.210.0080.00614.36
5.5.200.0060.00614.24
5.5.190.0000.01014.41
5.5.180.0090.00614.30
5.5.170.0060.00614.32
5.5.160.0060.00614.16
5.5.150.0070.00714.61
5.5.140.0030.01014.61
5.5.130.0070.01014.15
5.5.120.0060.00614.39
5.5.110.0040.01114.37
5.5.100.0000.01114.29
5.5.90.0060.00614.08
5.5.80.0040.01114.21
5.5.70.0000.00814.37
5.5.60.0060.00614.20
5.5.50.0070.00714.16
5.5.40.0030.01314.17
5.5.30.0070.00714.53
5.5.20.0060.00614.20
5.5.10.0060.00614.22
5.5.00.0070.00714.08
5.4.450.0150.04015.42
5.4.440.0100.03615.53
5.4.430.0190.03515.47
5.4.420.0100.03215.50
5.4.410.0200.01815.32
5.4.400.0130.02015.17
5.4.390.0110.02315.32
5.4.380.0110.02015.22
5.4.370.0140.02015.33
5.4.360.0090.02415.32
5.4.350.0100.02215.33
5.4.340.0110.02315.36
5.4.330.0000.00711.33
5.4.320.0150.01815.32
5.4.310.0120.02715.33
5.4.300.0120.02215.31
5.4.290.0080.02115.26
5.4.280.0100.02115.17
5.4.270.0150.01915.31
5.4.260.0200.01715.22
5.4.250.0140.02215.33
5.4.240.0130.01815.17
5.4.230.0150.02415.29
5.4.220.0160.01815.31
5.4.210.0140.01815.30
5.4.200.0110.02215.17
5.4.190.0080.03015.25
5.4.180.0160.02415.31
5.4.170.0190.01915.30
5.4.160.0080.02515.35
5.4.150.0070.02515.37
5.4.140.0200.01713.96
5.4.130.0080.02513.95
5.4.120.0170.01813.89
5.4.110.0180.01713.94
5.4.100.0120.02313.99
5.4.90.0240.03113.94
5.4.80.0170.03113.95
5.4.70.0180.02214.00
5.4.60.0140.02113.95
5.4.50.0130.02113.93
5.4.40.0220.02013.98
5.4.30.0130.02113.89
5.4.20.0130.02214.04
5.4.10.0170.03014.03
5.4.00.0130.02813.63
5.3.290.0120.02012.96
5.3.280.0180.01812.97
5.3.270.0170.03212.93
5.3.260.0140.02112.93
5.3.250.0110.02312.96
5.3.240.0190.02212.95
5.3.230.0130.02312.93
5.3.220.0190.02212.93
5.3.210.0180.02712.91
5.3.200.0130.02712.92
5.3.190.0140.02312.89
5.3.180.0200.02212.84
5.3.170.0180.03812.93
5.3.160.0190.01612.84
5.3.150.0230.02012.92
5.3.140.0080.02312.92
5.3.130.0180.03312.85
5.3.120.0160.01812.91
5.3.110.0130.02712.86
5.3.100.0130.02512.65
5.3.90.0160.02512.61
5.3.80.0100.02612.58
5.3.70.0170.03312.64
5.3.60.0120.02712.64
5.3.50.0150.03312.62
5.3.40.0130.04012.61
5.3.30.0180.03812.58
5.3.20.0130.02712.47
5.3.10.0130.01912.47
5.3.00.0150.03412.45
5.2.170.0130.03311.09
5.2.160.0230.03711.04
5.2.150.0170.04011.03
5.2.140.0200.05711.08
5.2.130.0230.02311.04
5.2.120.0170.02711.00
5.2.110.0200.03711.01
5.2.100.0230.05310.98
5.2.90.0230.04011.04
5.2.80.0170.03310.98
5.2.70.0230.06011.07
5.2.60.0270.03710.95
5.2.50.0130.05011.01
5.2.40.0200.05310.89
5.2.30.0200.03310.82
5.2.20.0100.05310.96
5.2.10.0270.04710.90
5.2.00.0230.03710.91
5.1.60.0300.02310.05
5.1.50.0200.02310.12
5.1.40.0200.02010.20
5.1.30.0170.03010.30
5.1.20.0200.02710.37
5.1.10.0200.05310.18
5.1.00.0170.02310.13
5.0.50.0100.0378.77
5.0.40.0070.0438.62
5.0.30.0030.0478.35
5.0.20.0130.0378.24
5.0.10.0130.0208.14
5.0.00.0130.0278.13
4.4.90.0070.0277.39
4.4.80.0100.0337.39
4.4.70.0070.0277.39
4.4.60.0030.0207.39
4.4.50.0130.0177.39
4.4.40.0070.0277.39
4.4.30.0100.0137.39
4.4.20.0100.0177.39
4.4.10.0030.0207.39
4.4.00.0100.0477.39
4.3.110.0070.0307.39
4.3.100.0170.0237.39
4.3.90.0200.0137.39
4.3.80.0070.0237.39
4.3.70.0070.0177.39
4.3.60.0070.0207.39
4.3.50.0100.0137.39
4.3.40.0100.0437.39
4.3.30.0130.0177.39
4.3.20.0070.0337.39
4.3.10.0030.0237.39
4.3.00.0070.0207.39

preferences:
50.98 ms | 401 KiB | 5 Q