3v4l.org

run code in 300+ PHP versions simultaneously
<?php class testclass{ public $xmlRequestDom = NULL; function __construct($xmlrequest) { if (gettype($xmlrequest)=='object') { $this->xmlRequestDom = $xmlrequest; } else { $this->xmlRequestDom = new DomDocument(); $this->xmlRequestDom->loadXML($xmlrequest); } $this->setParamsFromXMLRequest(); } function setParamsFromXMLRequest() { $children = $this->xmlRequestDom->documentElement->childNodes; foreach($children as $child) { if($child->nodeType != XML_ELEMENT_NODE) continue; echo $child->nodeName."\n"; } } } $newxml = "<?xml version=\"1.0\" encoding=\"UTF-8\"?> <c:tellervo xmlns:c=\"http://www.tellervo.org/schema/1.0\" xmlns:gml=\"http://www.opengis.net/gml\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" xmlns:tridas=\"http://www.tridas.org/1.2.2\"> <c:request type=\"create\"> <tridas:object> <tridas:title>ppp</tridas:title> <tridas:type normalStd=\"Tellervo\" normalId=\"1\" normal=\"Site\" /> <tridas:genericField name=\"tellervo.objectLabCode\">ppp</tridas:genericField> </tridas:object>"; $myParamObj = new testclass($newxml);

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.01119.05
8.3.50.0120.00722.05
8.3.40.0110.00418.89
8.3.30.0070.00719.04
8.3.20.0000.00819.01
8.3.10.0080.00021.34
8.3.00.0080.00023.91
8.2.180.0160.00618.86
8.2.170.0070.00722.96
8.2.160.0040.01120.60
8.2.150.0050.00324.18
8.2.140.0060.00324.66
8.2.130.0060.00326.16
8.2.120.0050.00320.20
8.2.110.0060.00321.31
8.2.100.0040.00818.09
8.2.90.0040.00419.48
8.2.80.0090.00017.97
8.2.70.0050.00317.75
8.2.60.0100.00018.05
8.2.50.0030.00518.07
8.2.40.0030.00618.47
8.2.30.0050.00219.72
8.2.20.0000.00717.80
8.2.10.0040.00417.95
8.2.00.0040.00418.07
8.1.280.0120.00325.92
8.1.270.0080.00023.99
8.1.260.0050.00326.35
8.1.250.0090.00028.09
8.1.240.0060.00321.42
8.1.230.0040.00717.64
8.1.220.0040.00417.91
8.1.210.0070.00318.77
8.1.200.0030.00717.60
8.1.190.0000.00817.48
8.1.180.0030.00618.10
8.1.170.0030.00618.71
8.1.160.0040.00419.09
8.1.150.0000.00718.75
8.1.140.0000.00717.68
8.1.130.0040.00418.00
8.1.120.0100.00017.68
8.1.110.0000.00817.61
8.1.100.0040.00417.80
8.1.90.0080.00017.75
8.1.80.0000.00717.71
8.1.70.0030.00617.51
8.1.60.0090.00017.81
8.1.50.0040.00417.70
8.1.40.0040.00417.71
8.1.30.0040.00417.70
8.1.20.0050.00317.92
8.1.10.0000.00717.75
8.1.00.0040.00417.77
8.0.300.0020.00518.77
8.0.290.0040.00416.84
8.0.280.0040.00418.84
8.0.270.0000.00717.46
8.0.260.0000.00717.11
8.0.250.0040.00417.25
8.0.240.0000.00817.21
8.0.230.0050.00217.19
8.0.220.0080.00017.18
8.0.210.0040.00417.18
8.0.200.0030.00317.39
8.0.190.0040.00417.22
8.0.180.0040.00417.16
8.0.170.0040.00417.21
8.0.160.0080.00017.21
8.0.150.0060.00316.98
8.0.140.0050.00317.06
8.0.130.0050.00313.84
8.0.120.0040.00417.00
8.0.110.0060.00317.09
8.0.100.0000.00717.02
8.0.90.0050.00217.27
8.0.80.0040.01117.16
8.0.70.0080.00016.99
8.0.60.0080.00017.23
8.0.50.0000.00717.06
8.0.30.0110.00817.47
8.0.20.0100.00917.40
8.0.10.0000.00717.39
8.0.00.0100.00916.91
7.4.330.0030.00315.08
7.4.320.0070.00016.89
7.4.300.0000.00616.68
7.4.290.0070.00016.88
7.4.280.0040.00416.81
7.4.270.0030.00516.80
7.4.260.0030.00313.66
7.4.250.0000.00916.77
7.4.240.0070.00016.82
7.4.230.0030.00316.54
7.4.220.0090.00916.86
7.4.210.0060.01016.80
7.4.200.0000.00716.92
7.4.190.0000.00716.95
7.4.160.0060.01516.77
7.4.150.0030.01417.40
7.4.140.0120.00517.86
7.4.130.0110.00616.70
7.4.120.0120.00516.78
7.4.110.0080.00916.71
7.4.100.0090.01216.70
7.4.90.0130.00316.95
7.4.80.0060.01319.39
7.4.70.0130.00716.79
7.4.60.0070.01116.68
7.4.50.0030.00616.71
7.4.40.0070.00722.52
7.4.30.0070.01016.93
7.4.00.0040.01115.26
7.3.330.0020.00313.55
7.3.320.0020.00213.62
7.3.310.0040.00416.60
7.3.300.0050.00216.55
7.3.290.0120.00316.61
7.3.280.0080.00616.57
7.3.270.0100.00617.40
7.3.260.0110.00718.24
7.3.250.0060.01016.71
7.3.240.0080.00816.64
7.3.230.0100.00616.73
7.3.210.0030.01416.68
7.3.200.0030.01519.39
7.3.190.0170.00616.63
7.3.180.0100.00716.78
7.3.170.0130.00316.77
7.3.160.0000.01516.60
7.3.120.0100.00614.98
7.2.330.0080.00816.67
7.2.320.0030.01416.68
7.2.310.0170.00716.69
7.2.300.0070.01017.02
7.2.290.0110.01117.02
7.1.100.0780.01016.04
7.1.70.0000.01017.09
7.1.60.0100.01319.40
7.1.50.0170.00616.88
7.1.00.0000.08022.55
7.0.200.0000.00916.78
7.0.140.0170.06022.10
7.0.60.0130.07320.10
7.0.50.0100.06018.09
7.0.40.0030.05720.21
7.0.30.0670.06020.33
7.0.20.0300.07320.23
7.0.10.0300.08020.20
7.0.00.0070.07720.33
5.6.280.0000.07721.05
5.6.210.0130.06720.76
5.6.200.0070.05718.39
5.6.190.0100.08720.70
5.6.180.0330.04720.55
5.6.170.0230.06720.67
5.6.160.0100.08320.65
5.6.150.0070.04318.33
5.6.140.0200.06718.27
5.6.130.0030.09018.26
5.6.120.0030.05021.03
5.6.110.0030.07721.01
5.6.100.0030.04321.13
5.6.90.0130.08021.03
5.6.80.0100.08320.40
5.6.70.4230.04020.41
5.5.350.0230.06020.40
5.5.340.0070.04318.23
5.5.330.0100.08020.61
5.5.320.0270.03720.33
5.5.310.0300.07020.43
5.5.300.0030.04318.13
5.5.290.0070.09018.15
5.5.280.0130.04720.82
5.5.270.0100.07020.92
5.5.260.0100.07720.94
5.5.250.0100.03320.55
5.5.240.0030.08320.24
5.4.450.3200.04319.69
5.4.440.3370.04019.35
5.4.430.3170.04019.66
5.4.420.2900.03719.54
5.4.410.3330.03719.56
5.4.400.3400.04019.30
5.4.390.3370.04719.14
5.4.380.3370.03019.12
5.4.370.3330.03319.34
5.4.360.3400.04019.30
5.4.350.3130.03719.34
5.4.340.3400.03719.37
5.4.320.4230.03719.04
5.4.310.3330.03319.07
5.4.300.3300.04019.39
5.4.290.3200.04719.14
5.4.280.3230.03719.02
5.4.270.3430.03719.33
5.4.260.3270.03719.02
5.4.250.3270.04019.14
5.4.240.3370.03719.33
5.4.230.3470.04019.33
5.4.220.3400.03319.11
5.4.210.3070.04019.29
5.4.200.2730.03719.07
5.4.190.1470.03019.06
5.4.180.1870.03719.16
5.4.170.2270.04019.23
5.4.160.2600.04019.28
5.4.150.2400.03719.05
5.4.140.2600.03316.49
5.4.130.2670.02716.63
5.4.120.2830.03716.43
5.4.110.2970.04316.58
5.4.100.2630.03716.41
5.4.90.2830.03316.69
5.4.80.2430.03716.66
5.4.70.3170.02716.53
5.4.60.3070.03716.51
5.4.50.2930.03316.51
5.4.40.2900.03316.68
5.4.30.2830.04016.34
5.4.20.2630.03316.70
5.4.10.2930.03016.55
5.4.00.4100.04016.04
5.3.290.3530.04714.73
5.3.280.3270.04014.80
5.3.270.3030.03714.66
5.3.260.3270.03014.82
5.3.250.3500.03314.69
5.3.240.3330.04014.70
5.3.230.3070.04014.90
5.3.220.3330.03314.72
5.3.210.3530.03714.64
5.3.200.3430.03714.81
5.3.190.3330.03714.87
5.3.180.3330.03714.63
5.3.170.3230.04014.63
5.3.160.3170.04014.76
5.3.150.3330.03714.77
5.3.140.3400.04014.61
5.3.130.3330.03714.64
5.3.120.3070.03714.63
5.3.110.3200.03714.71
5.3.100.3270.04014.10
5.3.90.3330.03714.25
5.3.80.3330.03714.18
5.3.70.3470.03714.19
5.3.60.3830.03714.25
5.3.50.3700.03714.02
5.3.40.3630.03014.02
5.3.30.3900.03313.90
5.3.20.3870.03313.75
5.3.10.3030.03313.82
5.3.00.3300.03313.70
5.2.170.2600.03311.32
5.2.160.2930.03011.21
5.2.150.2600.02311.21
5.2.140.2700.03711.45
5.2.130.2630.02011.16
5.2.120.2570.02711.16
5.2.110.2570.02711.14
5.2.100.2570.02711.16
5.2.90.2930.02711.26
5.2.80.2830.03311.15
5.2.70.2670.03011.19
5.2.60.2600.03311.31
5.2.50.2530.03011.18
5.2.40.2430.05711.30
5.2.30.2300.03311.24
5.2.20.2430.02711.00
5.2.10.2600.02010.92
5.2.00.2000.03311.02
5.1.60.2070.02310.15
5.1.50.2230.02710.20
5.1.40.2100.02710.05
5.1.30.2300.02710.50
5.1.20.2030.02710.43
5.1.10.2330.02310.25
5.1.00.2300.02710.23
5.0.50.1030.0238.80
5.0.40.1270.0238.61
5.0.30.1300.0338.48
5.0.20.1300.0138.21
5.0.10.1470.0238.20
5.0.00.1370.0338.22
4.4.90.1230.0135.81
4.4.80.1430.0175.76
4.4.70.1470.0175.85
4.4.60.1270.0135.88
4.4.50.1530.0105.84
4.4.40.1230.0275.93
4.4.30.1370.0175.83
4.4.20.1300.0135.93
4.4.10.1530.0205.94
4.4.00.1470.0275.79
4.3.110.1300.0135.71
4.3.100.1530.0205.74
4.3.90.1600.0105.76
4.3.80.1500.0235.77
4.3.70.1530.0135.75
4.3.60.0930.0235.75
4.3.50.1670.0175.80
4.3.40.1230.0275.69
4.3.30.0630.0175.19
4.3.20.0600.0175.19
4.3.10.0600.0175.19
4.3.00.0570.0175.19

preferences:
48.34 ms | 401 KiB | 5 Q