3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str=<<<XML <scales> <scale id="1" gender="*" age="*"> <d scid="hi" raw="10" t="76" /> <d scid="pn" raw="12" t="80" /> </scale> <scale id="2" gender="m" age="*"> <d scid="hi" raw="8" t="79" /> <d scid="pn" raw="2" t="50" /> </scale> <scale id="3" gender="*" age="19-39"> <d scid="hi" raw="0" t="48" /> <d scid="pn" raw="10" t="49" /> </scale> </scales> XML; $xml=simplexml_load_string($str); $result=$xml->xpath('//scale[@gender="*" or @gender="m"]/d[@age="*" or @age="39-59"]/d'); foreach($result as $node) { echo $node->attributes()->id."\n"; }

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.01217.00
8.3.50.0160.00717.76
8.3.40.0090.00918.92
8.3.30.0150.00018.92
8.3.20.0040.00419.02
8.3.10.0050.00320.86
8.3.00.0040.00419.50
8.2.180.0140.00717.00
8.2.170.0070.00722.96
8.2.160.0100.00321.41
8.2.150.0000.00824.18
8.2.140.0040.00424.66
8.2.130.0050.00326.16
8.2.120.0100.01019.68
8.2.110.0070.00422.68
8.2.100.0040.00820.77
8.2.90.0050.00318.59
8.2.80.0090.00018.30
8.2.70.0040.00418.18
8.2.60.0000.00918.18
8.2.50.0030.00618.10
8.2.40.0040.00418.53
8.2.30.0030.00618.45
8.2.20.0090.00018.10
8.2.10.0000.00718.21
8.2.00.0040.00417.93
8.1.280.0110.00425.92
8.1.270.0040.00424.66
8.1.260.0040.00426.35
8.1.250.0060.00328.09
8.1.240.0040.00424.09
8.1.230.0080.00319.40
8.1.220.0090.00018.04
8.1.210.0040.00418.77
8.1.200.0090.00017.73
8.1.190.0030.00617.48
8.1.180.0060.00318.10
8.1.170.0080.00019.12
8.1.160.0040.00419.20
8.1.150.0040.00418.83
8.1.140.0080.00017.70
8.1.130.0040.00418.27
8.1.120.0000.00717.76
8.1.110.0040.00417.82
8.1.100.0070.00017.88
8.1.90.0040.00417.82
8.1.80.0000.00717.88
8.1.70.0040.00417.86
8.1.60.0000.00917.84
8.1.50.0000.00817.86
8.1.40.0060.00317.93
8.1.30.0000.00718.10
8.1.20.0040.00417.88
8.1.10.0000.00817.84
8.1.00.0080.00017.56
8.0.300.0040.00420.14
8.0.290.0120.00017.13
8.0.280.0080.00218.81
8.0.270.0000.00717.57
8.0.260.0090.00317.17
8.0.250.0050.00217.25
8.0.240.0000.00717.27
8.0.230.0000.00717.48
8.0.220.0000.00717.19
8.0.210.0000.00817.41
8.0.200.0000.00717.42
8.0.190.0040.00417.43
8.0.180.0030.00517.38
8.0.170.0000.00917.42
8.0.160.0030.00517.37
8.0.150.0030.00617.32
8.0.140.0040.00417.07
8.0.130.0030.00313.71
8.0.120.0080.00017.30
8.0.110.0040.00417.27
8.0.100.0040.00417.37
8.0.90.0000.00717.21
8.0.80.0000.01417.19
8.0.70.0040.00417.36
8.0.60.0070.00017.26
8.0.50.0040.00417.13
8.0.30.0110.01117.43
8.0.20.0120.00717.32
8.0.10.0040.00417.55
8.0.00.0130.00517.32
7.4.330.0000.00513.39
7.4.320.0040.00416.86
7.4.300.0070.00317.03
7.4.290.0000.00716.90
7.4.280.0090.00016.89
7.4.270.0000.00716.92
7.4.260.0030.00313.73
7.4.250.0000.00916.88
7.4.240.0000.00816.91
7.4.230.0000.00716.77
7.4.220.0030.01516.96
7.4.210.0050.01016.90
7.4.200.0050.00216.73
7.4.190.0080.00016.98
7.4.160.0090.00616.96
7.4.150.0060.01116.80
7.4.140.0080.01016.92
7.4.130.0110.01016.79
7.4.120.0130.00816.74
7.4.110.0100.00716.82
7.4.100.0070.01016.79
7.4.90.0180.00316.96
7.4.80.0060.01616.87
7.4.70.0120.00617.03
7.4.60.0090.00916.84
7.4.50.0000.00716.83
7.4.40.0080.00816.82
7.4.30.0130.00316.56
7.4.00.0070.01115.03
7.3.330.0000.00713.61
7.3.320.0030.00313.60
7.3.310.0040.00416.46
7.3.300.0000.00716.71
7.3.290.0070.01116.60
7.3.280.0050.01216.71
7.3.270.0060.01316.83
7.3.260.0080.01516.85
7.3.250.0110.00916.72
7.3.240.0060.01116.91
7.3.230.0140.00616.82
7.3.210.0130.00316.73
7.3.200.0120.00619.39
7.3.190.0080.00816.72
7.3.180.0070.01016.95
7.3.170.0160.00016.72
7.3.160.0090.00916.90
7.3.120.0080.01015.04
7.3.110.0030.01015.05
7.3.100.0020.01115.06
7.3.90.0060.01114.86
7.3.80.0050.00815.00
7.3.70.0010.00815.02
7.3.60.0030.00914.95
7.3.50.0080.00914.93
7.3.40.0090.00315.02
7.3.30.0100.00315.03
7.3.20.0070.00716.71
7.3.10.0060.01016.73
7.3.00.0040.01016.78
7.2.330.0060.01316.99
7.2.320.0070.01117.01
7.2.310.0070.01616.66
7.2.300.0070.01017.11
7.2.290.0070.01116.88
7.2.250.0100.00714.98
7.2.240.0070.00915.26
7.2.230.0020.01115.07
7.2.220.0090.00515.26
7.2.210.0030.01115.15
7.2.200.0090.00615.16
7.2.190.0040.00915.18
7.2.180.0040.00915.24
7.2.170.0070.00815.21
7.2.160.0060.00615.12
7.2.150.0030.00717.17
7.2.140.0120.00317.11
7.2.130.0090.00717.01
7.2.120.0040.01017.11
7.2.110.0040.01117.17
7.2.100.0050.01016.98
7.2.90.0060.00717.13
7.2.80.0060.00917.19
7.2.70.0070.00717.05
7.2.60.0070.00717.02
7.2.50.0040.01117.12
7.2.40.0070.00717.13
7.2.30.0070.00817.16
7.2.20.0070.00617.07
7.2.10.0040.01017.09
7.2.00.0080.00817.72
7.1.330.0070.00816.00
7.1.320.0050.00715.98
7.1.310.0070.00716.03
7.1.300.0070.00415.85
7.1.290.0030.00715.87
7.1.280.0030.01015.77
7.1.270.0050.00915.85
7.1.260.0060.00616.06
7.1.250.0040.00815.84
7.1.100.0000.01318.47
7.1.70.0030.00617.06
7.1.60.0030.02119.40
7.1.50.0130.01016.91
7.1.00.0030.05322.57
7.0.200.0030.00517.04
7.0.140.0070.07022.18
7.0.120.0100.06722.27
7.0.60.0100.06720.17
7.0.50.0100.07717.99
7.0.40.0200.07320.25
7.0.30.0400.06020.38
7.0.20.0230.07720.39
7.0.10.0030.04320.22
7.0.00.0170.08020.39
5.6.280.0070.08721.21
5.6.210.0070.06321.03
5.6.200.0030.04718.40
5.6.190.0100.07720.65
5.6.180.2700.03720.83
5.6.170.0270.05320.70
5.6.160.0030.08720.78
5.6.150.0100.03718.34
5.6.140.0030.06718.27
5.6.130.0070.04318.34
5.6.120.0070.06021.12
5.6.110.0130.08021.17
5.6.100.0170.07721.16
5.6.90.0030.07021.19
5.6.80.0070.08320.60
5.6.70.3800.03020.66
5.5.350.0100.08320.59
5.5.340.0130.07718.17
5.5.330.0100.08320.38
5.5.320.3070.04320.56
5.5.310.0270.06020.46
5.5.300.0100.06318.10
5.5.290.0000.04318.10
5.5.280.0070.08320.79
5.5.270.0100.03721.14
5.5.260.0030.07020.91
5.5.250.0030.04320.81
5.5.240.0200.02720.41
5.4.450.0130.06319.49
5.4.440.0070.06319.27
5.4.430.0170.06319.34
5.4.420.0070.08019.72
5.4.410.0030.07019.33
5.4.400.0170.03719.37
5.4.390.0030.05319.24
5.4.380.0030.04019.41
5.4.370.0070.07318.95
5.4.360.0130.04319.32
5.4.350.0130.07019.48
5.4.340.0170.07019.36
5.4.320.0070.04019.27
5.4.310.0000.06319.14
5.4.300.0000.07319.32
5.4.290.0100.04319.30
5.4.280.0030.05719.30
5.4.270.0030.04719.30
5.4.260.0130.06719.23
5.4.250.0030.08318.94
5.4.240.0070.08019.30
5.4.230.0070.07319.27
5.4.220.0130.04318.94
5.4.210.0130.06319.29
5.4.200.0100.03319.23
5.4.190.0070.04319.38
5.4.180.0070.06318.94
5.4.170.0100.03319.15
5.4.160.0100.04719.12
5.4.150.0100.04019.14
5.4.140.0070.07316.41
5.4.130.0030.04016.41
5.4.120.0070.04316.37
5.4.110.0170.06316.59
5.4.100.0070.07716.73
5.4.90.0030.05016.73
5.4.80.0000.07316.48
5.4.70.0030.06716.49
5.4.60.0100.04016.45
5.4.50.0070.03316.42
5.4.40.0030.04016.46
5.4.30.0100.07016.50
5.4.20.0100.04016.45
5.4.10.0000.07716.46
5.4.00.0070.04316.07
5.3.290.0100.06714.84
5.3.280.0100.04314.74
5.3.270.0070.03714.75
5.3.260.0130.07014.61
5.3.250.0030.07014.75
5.3.240.0070.04014.80
5.3.230.0030.06014.80
5.3.220.0030.03714.74
5.3.210.0030.05314.60
5.3.200.0100.07314.61
5.3.190.0030.05014.58
5.3.180.0070.08314.64
5.3.170.0130.03714.71
5.3.160.0070.03714.76
5.3.150.0070.03314.76
5.3.140.0030.07714.59
5.3.130.0100.07314.70
5.3.120.0070.05714.71
5.3.110.0100.05314.63
5.3.100.0100.07714.18
5.3.90.0030.07714.21
5.3.80.0030.05314.23
5.3.70.0070.03714.02
5.3.60.0070.07714.25
5.3.50.0030.03714.09
5.3.40.0030.08014.16
5.3.30.0070.07014.16
5.3.20.0130.06313.81
5.3.10.0030.07313.80
5.3.00.0070.07313.80
5.2.170.0070.06011.26
5.2.160.0070.06311.30
5.2.150.0000.04311.35
5.2.140.0000.06011.32
5.2.130.0000.07011.34
5.2.120.0070.06011.16
5.2.110.0070.04711.40
5.2.100.0070.05011.34
5.2.90.0070.05711.14
5.2.80.0070.06011.13
5.2.70.0070.03011.31
5.2.60.0070.03311.26
5.2.50.0030.03011.13
5.2.40.0030.02711.20
5.2.30.0000.03311.28
5.2.20.0030.02711.19
5.2.10.0070.02311.14
5.2.00.0030.02710.82
5.1.60.0000.02710.14
5.1.50.0000.03010.27
5.1.40.0000.02710.15
5.1.30.0000.03010.52
5.1.20.0000.02710.65
5.1.10.0070.02010.29
5.1.00.0000.02710.31
5.0.50.0000.0208.82
5.0.40.0000.0208.66
5.0.30.0000.0308.30
5.0.20.0000.0238.45
5.0.10.0000.0208.50
5.0.00.0000.0308.30
4.4.90.0000.0177.65
4.4.80.0030.0137.65
4.4.70.0070.0107.65
4.4.60.0030.0137.65
4.4.50.0030.0137.65
4.4.40.0000.0237.65
4.4.30.0030.0137.65
4.4.20.0000.0177.65
4.4.10.0030.0137.65
4.4.00.0000.0277.65
4.3.110.0030.0137.65
4.3.100.0000.0137.65
4.3.90.0000.0207.65
4.3.80.0030.0207.65
4.3.70.0000.0137.65
4.3.60.0000.0137.65
4.3.50.0000.0177.65
4.3.40.0000.0237.65
4.3.30.0000.0177.65
4.3.20.0000.0177.65
4.3.10.0030.0137.65
4.3.00.0000.0137.65

preferences:
45.59 ms | 401 KiB | 5 Q