3v4l.org

run code in 300+ PHP versions simultaneously
<?php $dom = new DOMDocument(); $dom->loadXML('<?xml version="1.0" encoding="UTF-8"?> <root> <test>head text <b>some bold text</b> tail text</test> </root> '); $xpath = new DOMXPath($dom); $elements = $xpath->query('/root/test/text()'); foreach ($elements as $element) { echo $element->nodeValue; }

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.70.0060.00918.68
8.3.60.0060.00918.52
8.3.50.0110.01017.90
8.3.40.0150.00618.97
8.3.30.0150.00019.01
8.3.20.0060.00320.66
8.3.10.0040.00419.10
8.3.00.0040.00422.10
8.2.190.0060.01218.58
8.2.180.0080.00816.63
8.2.170.0070.00722.96
8.2.160.0140.00020.84
8.2.150.0080.00024.18
8.2.140.0050.00324.66
8.2.130.0000.00726.16
8.2.120.0050.00320.08
8.2.110.0060.00620.85
8.2.100.0110.00018.09
8.2.90.0040.00418.09
8.2.80.0000.00917.97
8.2.70.0030.00617.88
8.2.60.0060.00318.41
8.2.50.0050.00318.07
8.2.40.0040.00418.54
8.2.30.0040.00418.35
8.2.20.0040.00418.40
8.2.10.0060.00318.43
8.2.00.0040.00418.47
8.1.280.0160.00625.92
8.1.270.0080.00024.17
8.1.260.0040.00426.35
8.1.250.0040.01128.09
8.1.240.0000.00921.03
8.1.230.0090.00323.09
8.1.220.0030.00618.16
8.1.210.0000.00919.16
8.1.200.0000.00917.60
8.1.190.0000.00817.60
8.1.180.0060.00318.10
8.1.170.0000.00819.37
8.1.160.0050.00219.33
8.1.150.0000.00720.61
8.1.140.0080.00019.49
8.1.130.0000.00719.13
8.1.120.0000.00817.66
8.1.110.0040.00417.83
8.1.100.0030.00617.91
8.1.90.0040.00417.88
8.1.80.0050.00217.88
8.1.70.0040.00417.65
8.1.60.0050.00318.00
8.1.50.0080.00317.93
8.1.40.0030.00817.93
8.1.30.0080.00018.13
8.1.20.0030.00518.07
8.1.10.0000.00818.02
8.1.00.0070.00017.86
8.0.300.0060.00320.41
8.0.290.0040.00417.13
8.0.280.0030.00618.80
8.0.270.0030.00317.43
8.0.260.0030.00320.42
8.0.250.0070.00017.16
8.0.240.0050.00317.41
8.0.230.0040.00417.37
8.0.220.0080.00017.32
8.0.210.0040.00417.18
8.0.200.0070.00017.14
8.0.190.0000.00717.12
8.0.180.0050.00217.13
8.0.170.0040.00417.34
8.0.160.0030.00517.35
8.0.150.0030.00617.08
8.0.140.0030.00317.07
8.0.130.0060.00013.65
8.0.120.0000.00817.23
8.0.110.0000.00817.30
8.0.100.0000.00717.22
8.0.90.0030.00517.21
8.0.80.0120.00317.24
8.0.70.0040.00417.38
8.0.60.0000.00817.20
8.0.50.0030.00517.16
8.0.30.0110.01017.31
8.0.20.0110.00917.57
8.0.10.0070.00017.43
8.0.00.0090.00917.30
7.4.330.0000.00515.55
7.4.320.0030.00316.93
7.4.300.0000.00617.03
7.4.290.0070.00016.77
7.4.280.0030.00817.03
7.4.270.0070.00016.94
7.4.260.0000.00716.94
7.4.250.0040.00416.82
7.4.240.0000.00816.99
7.4.230.0050.00217.09
7.4.220.0130.00317.00
7.4.210.0080.00616.92
7.4.200.0030.00316.81
7.4.160.0090.00916.92
7.4.150.0110.00617.40
7.4.140.0110.00817.86
7.4.130.0040.01516.88
7.4.120.0110.01216.86
7.4.110.0090.00916.76
7.4.100.0100.00716.68
7.4.90.0100.00716.73
7.4.80.0070.01019.39
7.4.70.0060.01216.70
7.4.60.0090.00616.79
7.4.50.0060.01216.72
7.4.40.0060.01516.73
7.4.30.0070.01116.93
7.4.00.0090.00615.20
7.3.330.0000.00513.26
7.3.320.0000.00613.34
7.3.310.0030.00316.35
7.3.300.0070.00016.68
7.3.290.0040.00416.44
7.3.280.0080.00616.65
7.3.270.0090.01217.40
7.3.260.0110.00716.86
7.3.250.0080.01016.76
7.3.240.0100.00816.78
7.3.230.0120.00616.77
7.3.210.0120.00616.88
7.3.200.0100.00616.61
7.3.190.0170.00316.52
7.3.180.0130.00316.46
7.3.170.0060.01116.76
7.3.160.0100.00716.56
7.2.330.0110.00616.71
7.2.320.0030.01316.82
7.2.310.0120.01216.85
7.2.300.0030.01617.16
7.2.290.0060.01016.61
7.2.60.0040.01116.80
7.2.00.0100.01017.84
7.1.200.0030.00716.04
7.1.120.0070.01316.82
7.1.110.0130.00616.39
7.1.100.0100.00716.50
7.1.90.0110.00318.45
7.1.80.0070.00718.30
7.1.70.0060.00617.39
7.1.60.0220.00335.41
7.1.50.0260.00734.70
7.1.40.0160.01334.52
7.1.30.0130.01634.58
7.1.20.0120.01734.59
7.1.10.0250.00414.81
7.1.00.0000.01316.85

preferences:
20.58 ms | 401 KiB | 5 Q