3v4l.org

run code in 300+ PHP versions simultaneously
<?php $x = new SimpleXMLElement('<root name="toplevel"></root>'); $f1 = new SimpleXMLElement('<child pos="1">alpha</child>'); $f2 = new SimpleXMLElement('<child pos="2">beta</child>'); $f3 = new SimpleXMLElement('<child pos="3">gamma</child>'); $x->{$f1->getName()} = $f1; $x->{$f2->getName()}[] = $f2; $x->{$f3->getName()}[] = $f3; echo 'count child=',$x->count(),"\n"; echo $x->asXML(); foreach ( $x->children() as $foo ) { var_dump($foo); }

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.0060.00916.88
8.3.50.0090.00616.39
8.3.40.0000.01419.04
8.3.30.0090.00619.10
8.3.20.0030.00520.54
8.3.10.0050.00322.10
8.3.00.0080.00017.88
8.2.180.0120.00616.88
8.2.170.0090.00622.96
8.2.160.0070.00720.72
8.2.150.0000.00824.18
8.2.140.0030.00524.66
8.2.130.0040.00420.72
8.2.120.0040.00426.35
8.2.110.0110.00020.71
8.2.100.0000.01118.09
8.2.90.0030.00618.13
8.2.80.0060.00319.03
8.2.70.0040.00417.88
8.2.60.0000.00818.00
8.2.50.0000.00817.88
8.2.40.0080.00019.73
8.2.30.0040.00421.34
8.2.20.0040.00418.37
8.2.10.0040.00418.41
8.2.00.0040.00418.36
8.1.280.0110.00725.92
8.1.270.0080.00024.04
8.1.260.0040.00426.35
8.1.250.0000.00828.09
8.1.240.0060.00324.11
8.1.230.0090.00321.24
8.1.220.0030.00518.82
8.1.210.0000.00918.77
8.1.200.0030.00517.60
8.1.190.0000.00817.78
8.1.180.0080.00018.10
8.1.170.0040.00417.62
8.1.160.0000.00719.27
8.1.150.0000.00819.18
8.1.140.0040.00419.82
8.1.130.0050.00219.19
8.1.120.0040.00417.77
8.1.110.0040.00417.61
8.1.100.0040.00417.73
8.1.90.0040.00417.77
8.1.80.0040.00417.76
8.1.70.0000.00717.58
8.1.60.0030.00617.77
8.1.50.0000.00817.81
8.1.40.0030.00617.86
8.1.30.0060.00617.80
8.1.20.0070.00017.81
8.1.10.0000.00817.89
8.1.00.0000.00817.68
8.0.300.0040.00420.11
8.0.290.0040.00416.88
8.0.280.0050.00218.68
8.0.270.0000.00717.53
8.0.260.0060.00017.09
8.0.250.0000.00817.23
8.0.240.0040.00417.07
8.0.230.0070.00017.27
8.0.220.0000.00717.02
8.0.210.0070.00017.17
8.0.200.0070.00017.28
8.0.190.0080.00017.22
8.0.180.0040.00417.20
8.0.170.0000.00717.19
8.0.160.0000.01017.04
8.0.150.0050.00317.00
8.0.140.0070.00017.07
8.0.130.0000.00613.57
8.0.120.0030.00517.16
8.0.110.0000.00717.14
8.0.100.0040.00416.95
8.0.90.0030.00617.21
8.0.80.0110.00417.08
8.0.70.0040.00417.26
8.0.60.0000.00717.18
8.0.50.0080.00016.94
8.0.30.0050.01117.24
8.0.20.0090.01217.49
8.0.10.0000.00717.37
8.0.00.0090.00917.11
7.4.330.0060.00015.55
7.4.320.0060.00016.83
7.4.300.0000.00616.97
7.4.290.0080.00016.85
7.4.280.0000.00816.76
7.4.270.0070.00016.62
7.4.260.0070.00416.82
7.4.250.0050.00216.89
7.4.240.0040.00416.93
7.4.230.0000.00716.91
7.4.220.0060.01316.66
7.4.210.0040.01116.71
7.4.200.0070.00016.63
7.4.160.0110.01116.83
7.4.150.0100.00817.40
7.4.140.0150.01017.86
7.4.130.0120.00616.74
7.4.120.0090.01016.81
7.4.110.0100.00716.89
7.4.100.0100.00916.82
7.4.90.0040.01316.79
7.4.80.0100.00918.05
7.4.70.0080.00916.81
7.4.60.0070.01016.83
7.4.50.0070.00816.67
7.4.40.0080.00816.77
7.4.30.0090.00816.83
7.4.20.0060.01216.89
7.4.10.0080.00815.83
7.4.00.0080.01015.50
7.3.330.0000.00613.20
7.3.320.0060.00013.41
7.3.310.0030.00316.46
7.3.300.0070.00016.54
7.3.290.0070.00816.59
7.3.280.0080.01016.55
7.3.270.0080.00817.40
7.3.260.0090.00916.69
7.3.250.0110.01216.66
7.3.240.0120.01216.76
7.3.230.0100.00716.82
7.3.220.0030.01316.74
7.3.210.0090.00816.63
7.3.200.0070.01016.61
7.3.190.0100.00616.68
7.3.180.0110.00516.56
7.3.170.0100.00616.69
7.3.160.0080.00816.83
7.3.150.0180.00016.64
7.3.140.0110.00616.69
7.3.130.0060.01015.79
7.3.120.0080.01015.60
7.3.110.0110.00715.46
7.3.100.0070.00715.39
7.3.90.0120.00415.47
7.3.80.0050.01015.68
7.3.70.0110.00515.43
7.3.60.0060.01215.46
7.3.50.0050.01115.43
7.3.40.0100.00615.45
7.3.30.0020.01215.47
7.3.20.0060.00916.86
7.3.10.0040.00916.75
7.3.00.0070.01016.67
7.2.330.0120.00616.94
7.2.320.0130.00517.00
7.2.310.0070.01016.85
7.2.300.0140.00317.08
7.2.290.0100.01017.09
7.2.280.0150.00316.80
7.2.270.0070.01116.77
7.2.260.0080.01015.92
7.2.250.0120.00615.86
7.2.240.0100.00715.78
7.2.230.0110.00615.80
7.2.220.0060.00915.83
7.2.210.0070.00615.74
7.2.200.0060.01015.81
7.2.190.0050.01015.77
7.2.180.0040.01015.76
7.2.170.0080.00815.69
7.2.160.0100.00616.19
7.2.150.0080.00817.13
7.2.140.0070.00917.12
7.2.130.0040.01116.78
7.2.120.0070.00717.03
7.2.110.0090.00816.93
7.2.100.0090.00816.97
7.2.90.0020.01516.86
7.2.80.0070.00916.90
7.2.70.0070.00717.14
7.2.60.0040.01117.06
7.2.50.0070.00916.88
7.2.40.0160.01217.22
7.2.30.0060.01116.96
7.2.20.0140.00317.13
7.2.10.0080.00916.91
7.2.00.0060.00917.88
7.1.330.0070.00715.88
7.1.320.0080.00615.97
7.1.310.0070.00916.00
7.1.300.0070.00915.79
7.1.290.0100.00615.99
7.1.280.0080.00815.75
7.1.270.0050.00815.85
7.1.260.0030.01115.90
7.1.250.0220.01015.92
7.1.240.0070.00915.88
7.1.230.0090.00815.85
7.1.220.0090.00715.80
7.1.210.0060.00815.91
7.1.200.0100.00515.98
7.1.190.0110.00415.84
7.1.180.0100.00515.91
7.1.170.0090.00515.84
7.1.160.0060.01115.82
7.1.150.0040.01015.92
7.1.140.0080.00715.80
7.1.130.0070.00915.81
7.1.120.0090.00715.82
7.1.110.0070.00915.92
7.1.100.0080.00416.62
7.1.90.0070.00815.84
7.1.80.0120.00315.84
7.1.70.0060.00816.30
7.1.60.0070.00816.38
7.1.50.0060.00716.32
7.1.40.0080.00616.08
7.1.30.0040.01016.18
7.1.20.0080.00816.21
7.1.10.0050.00716.10
7.1.00.0030.00916.16
7.0.330.0100.01215.43
7.0.320.0130.00915.58
7.0.310.0230.00715.48
7.0.300.0110.00915.36
7.0.290.0130.00715.66
7.0.280.0100.00915.56
7.0.270.0110.00715.58
7.0.260.0170.00815.51
7.0.250.0140.00715.57
7.0.240.0130.00715.66
7.0.230.0080.01215.65
7.0.220.0180.00715.71
7.0.210.0150.00315.59
7.0.200.0100.00515.85
7.0.190.0120.00415.93
7.0.180.0070.00915.87
7.0.170.0070.01215.82
7.0.160.0110.00615.85
7.0.150.0100.00715.88
7.0.140.0090.00715.85
7.0.130.0080.00716.00
7.0.120.0100.00815.98
7.0.110.0100.00715.97
7.0.100.0090.00915.76
7.0.90.0060.01015.81
7.0.80.0090.00915.72
7.0.70.0150.00515.86
7.0.60.0110.01015.82
7.0.50.0100.00815.97
7.0.40.0110.00514.65
7.0.30.0100.00614.71
7.0.20.0140.00614.72
7.0.10.0090.00714.72
7.0.00.0090.00714.68
5.6.400.0080.00915.59
5.6.390.0160.00715.47
5.6.380.0090.01115.51
5.6.370.0070.00915.39
5.6.360.0130.00815.59
5.6.350.0100.01215.46
5.6.340.0080.01515.54
5.6.330.0160.00415.51
5.6.320.0160.00815.38
5.6.310.0090.01515.58
5.6.300.0120.02217.25
5.6.290.0080.02217.20
5.6.280.0100.02117.22
5.6.270.0130.01717.28
5.6.260.0110.02117.39
5.6.250.0110.01917.26
5.6.240.0110.02017.26
5.6.230.0100.03817.19
5.6.220.0120.02117.25
5.6.210.0100.02117.22
5.6.200.0120.02017.19
5.6.190.0090.02417.33
5.6.180.0120.01917.23
5.6.170.0080.02217.27
5.6.160.0110.02017.28
5.6.150.0090.02717.20
5.6.140.0120.02417.37
5.6.130.0070.02217.31
5.6.120.0120.01717.37
5.6.110.0130.01517.19
5.6.100.0100.01917.28
5.6.90.0110.01917.21
5.6.80.0120.01817.08
5.6.70.0130.01716.98
5.6.60.0090.02517.06
5.6.50.0130.01917.07
5.6.40.0100.02317.10
5.6.30.0130.02217.00
5.6.20.0130.01717.05
5.6.10.0100.01817.03
5.6.00.0100.01516.97

preferences:
43.04 ms | 401 KiB | 5 Q