3v4l.org

run code in 300+ PHP versions simultaneously
<?php function foo() { $d = new DOMDocument; $c = $d->createElement('foo', 'bar'); $g = $d->createElement('fiz', 'buz'); $h = $d->createElement('red', 'xen'); $c->appendChild($g); $g->appendChild($h); return $h; } $x = foo(); while ($x) { var_dump($x->nodeValue); $x = $x->parentNode; }

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.0120.00918.55
8.3.50.0140.00521.99
8.3.40.0040.01118.54
8.3.30.0090.00518.84
8.3.20.0040.00420.24
8.3.10.0050.00323.79
8.3.00.0100.00019.08
8.2.180.0150.00318.18
8.2.170.0070.00722.96
8.2.160.0040.01120.39
8.2.150.0050.00524.18
8.2.140.0000.00824.66
8.2.130.0080.00026.16
8.2.120.0000.00819.54
8.2.110.0030.00722.27
8.2.100.0040.00720.52
8.2.90.0050.00318.03
8.2.80.0040.00419.39
8.2.70.0030.00617.66
8.2.60.0070.00018.03
8.2.50.0050.00318.10
8.2.40.0080.00019.34
8.2.30.0000.00719.13
8.2.20.0040.00417.82
8.2.10.0000.00717.89
8.2.00.0040.00417.70
8.1.280.0120.00625.92
8.1.270.0060.00318.83
8.1.260.0040.00426.35
8.1.250.0070.00028.09
8.1.240.0000.00824.01
8.1.230.0070.00419.01
8.1.220.0040.00417.74
8.1.210.0000.00818.77
8.1.200.0090.00017.48
8.1.190.0080.00017.34
8.1.180.0080.00018.10
8.1.170.0040.00420.84
8.1.160.0000.00918.96
8.1.150.0070.00418.91
8.1.140.0000.00717.33
8.1.130.0030.00317.83
8.1.120.0000.00717.50
8.1.110.0000.00717.38
8.1.100.0040.00417.37
8.1.90.0040.00317.48
8.1.80.0080.00017.38
8.1.70.0000.00717.43
8.1.60.0030.00617.71
8.1.50.0040.00417.51
8.1.40.0030.00517.53
8.1.30.0040.00417.71
8.1.20.0040.00417.57
8.1.10.0040.00417.64
8.1.00.0080.00017.57
8.0.300.0050.00219.68
8.0.290.0040.00416.75
8.0.280.0000.01018.29
8.0.270.0000.00717.24
8.0.260.0060.00017.07
8.0.250.0070.00016.95
8.0.240.0000.00817.00
8.0.230.0000.00717.03
8.0.220.0040.00416.91
8.0.210.0000.00716.84
8.0.200.0000.00817.02
8.0.190.0030.00317.00
8.0.180.0050.00217.02
8.0.170.0080.00016.91
8.0.160.0000.00716.89
8.0.150.0040.00416.86
8.0.140.0060.00316.81
8.0.130.0050.00013.33
8.0.120.0050.00316.85
8.0.110.0040.00416.89
8.0.100.0040.00416.99
8.0.90.0040.00416.98
8.0.80.0080.00917.02
8.0.70.0030.00516.76
8.0.60.0050.00216.87
8.0.50.0000.00716.68
8.0.30.0110.00716.93
8.0.20.0120.00617.40
8.0.10.0040.00416.95
8.0.00.0070.01116.65
7.4.330.0050.00015.15
7.4.320.0030.00316.40
7.4.300.0000.00616.71
7.4.290.0000.00616.59
7.4.280.0040.00416.65
7.4.270.0030.00316.54
7.4.260.0060.00316.54
7.4.250.0000.00816.46
7.4.240.0040.00316.54
7.4.230.0040.00416.48
7.4.220.0100.01416.67
7.4.210.0100.01016.46
7.4.200.0030.00316.34
7.4.160.0070.00716.45
7.4.150.0150.00917.40
7.4.140.0130.00517.86
7.4.130.0110.00916.68
7.4.120.0060.01316.38
7.4.110.0120.00616.53
7.4.100.0030.01416.51
7.4.90.0100.00716.52
7.4.80.0130.00619.39
7.4.70.0080.00816.62
7.4.60.0040.01216.50
7.4.50.0030.00516.54
7.4.40.0100.00616.64
7.4.30.0120.00416.43
7.4.00.0060.00614.80
7.3.330.0030.00313.19
7.3.320.0020.00213.22
7.3.310.0000.00716.22
7.3.300.0040.00416.36
7.3.290.0090.00616.31
7.3.280.0140.00616.34
7.3.270.0000.01817.40
7.3.260.0140.01016.69
7.3.250.0100.01316.42
7.3.240.0160.00316.39
7.3.230.0140.00516.50
7.3.210.0150.00316.28
7.3.200.0060.01219.39
7.3.190.0030.01316.64
7.3.180.0130.01016.15
7.3.170.0070.01316.64
7.3.160.0060.00916.17
7.2.330.0090.00916.57
7.2.320.0080.00816.44
7.2.310.0120.01216.77
7.2.300.0130.00416.54
7.2.290.0090.00916.74
7.2.00.0090.00419.42
7.1.100.0630.00315.80
7.1.70.0040.00717.27
7.1.60.0110.01119.22
7.1.50.0080.00317.05
7.1.00.0030.07722.28
7.0.200.0050.00216.59
7.0.140.0030.03322.05
7.0.60.0030.04020.04
7.0.50.0070.03717.91
7.0.40.0030.08720.14
7.0.30.0170.06020.18
7.0.20.0370.07320.19
7.0.10.0070.06720.10
7.0.00.0100.08020.06
5.6.280.0000.07721.08
5.6.210.0070.07720.57
5.6.200.0070.08018.20
5.6.190.0030.04320.48
5.6.180.0400.05020.52
5.6.170.0130.04320.53
5.6.160.0070.05720.47
5.6.150.0070.08018.29
5.6.140.0000.07718.22
5.6.130.0100.05318.28
5.6.120.0100.08321.00
5.6.110.0070.08320.86
5.6.100.0070.06021.10
5.6.90.0100.04020.95
5.6.80.0000.04320.39
5.5.350.0300.07320.44
5.5.340.0130.06018.02
5.5.330.0100.04320.43
5.5.320.0170.04320.35
5.5.310.0100.05020.25
5.5.300.0070.04717.98
5.5.290.0130.08018.04
5.5.280.0100.03720.80
5.5.270.0170.07020.76
5.5.260.0100.06320.80
5.5.250.0070.03720.71
5.5.240.0070.07320.29
5.4.450.0270.05719.23
5.4.440.0200.05719.30
5.4.430.0230.05019.57
5.4.420.0030.07019.51
5.4.410.0130.05319.30
5.4.400.0200.05319.23
5.4.390.0300.04019.19
5.4.380.0300.04318.63
5.4.370.0230.05018.61
5.4.360.0330.05018.77
5.4.350.0130.07018.79
5.4.340.0370.04718.54
5.4.320.0230.06318.61
5.4.310.0170.05718.50
5.4.300.0330.05318.59
5.4.290.0300.04718.78
5.4.280.0300.05318.62
5.4.270.0170.06018.46
5.4.260.0230.05718.79
5.4.250.0200.06718.63
5.4.240.0370.05018.80
5.4.230.0170.06318.57
5.4.220.0170.07718.74
5.4.210.0230.05318.68
5.4.200.0330.03716.53
5.4.190.0300.04318.69
5.4.180.0170.06018.63
5.4.170.0130.06318.61
5.4.160.0300.04318.48
5.4.150.0170.06018.45
5.4.140.0070.06316.45
5.4.130.0200.04716.32
5.4.120.0230.04316.34
5.4.110.0200.04716.22
5.4.100.0230.04716.33
5.4.90.0230.06716.25
5.4.80.0330.05316.32
5.4.70.0270.04016.31
5.4.60.0100.06016.27
5.4.50.0170.05716.16
5.4.40.0200.06016.22
5.4.30.0330.05016.18
5.4.20.0230.05016.15
5.4.10.0270.04316.29
5.4.00.0100.06015.75
5.3.290.0200.05314.96
5.3.280.0170.05714.78
5.3.270.0130.07014.64
5.3.260.0170.06014.65
5.3.250.0230.04714.78
5.3.240.0200.05314.65
5.3.230.0300.05014.70
5.3.220.0330.04714.73
5.3.210.0100.06314.55
5.3.200.0200.06014.66
5.3.190.0200.06014.55
5.3.180.0300.04314.59
5.3.170.0130.06714.69
5.3.160.0330.04714.84
5.3.150.0200.06014.56
5.3.140.0270.05314.84
5.3.130.0230.06714.60
5.3.120.0230.05714.72
5.3.110.0330.05714.67
5.3.100.0230.05314.23
5.3.90.0170.06014.07
5.3.80.0270.04014.04
5.3.70.0270.04014.12
5.3.60.0200.05014.17
5.3.50.0300.04014.11
5.3.40.0300.04014.23
5.3.30.0230.05713.89
5.3.20.0200.05313.72
5.3.10.0270.05313.79
5.3.00.0100.06013.63
5.2.170.0130.04711.13
5.2.160.0270.03311.43
5.2.150.0070.05311.25
5.2.140.0100.05011.16
5.2.130.0130.04311.23
5.2.120.0200.05011.25
5.2.110.0100.05311.10
5.2.100.0170.04011.08
5.2.90.0100.04711.24
5.2.80.0170.04311.23
5.2.70.0130.04311.13
5.2.60.0000.05711.11
5.2.50.0100.05311.12
5.2.40.0130.04711.05
5.2.30.0230.03311.02
5.2.20.0130.04011.09
5.2.10.0070.04310.80
5.2.00.0170.03710.69
5.1.60.0130.03310.17
5.1.50.0170.03010.07
5.1.40.0070.05010.15
5.1.30.0100.04010.42
5.1.20.0200.03010.50
5.1.10.0270.02310.05
5.1.00.0100.04010.16
5.0.50.0170.0278.58
5.0.40.0130.0308.50
5.0.30.0030.0538.47
5.0.20.0030.0338.20
5.0.10.0070.0338.16
5.0.00.0070.0408.26
4.4.90.0070.0236.02
4.4.80.0030.0275.90
4.4.70.0200.0105.86
4.4.60.0070.0236.00
4.4.50.0130.0176.00
4.4.40.0000.0435.99
4.4.30.0030.0305.94
4.4.20.0130.0136.05
4.4.10.0030.0235.98
4.4.00.0070.0335.99
4.3.110.0070.0235.83
4.3.100.0130.0135.87
4.3.90.0030.0235.80
4.3.80.0070.0375.83
4.3.70.0100.0175.92
4.3.60.0070.0205.80
4.3.50.0030.0275.80
4.3.40.0030.0405.75
4.3.30.0030.0234.64
4.3.20.0100.0174.55
4.3.10.0030.0234.51
4.3.00.0070.0237.00

preferences:
51.7 ms | 401 KiB | 5 Q