3v4l.org

run code in 300+ PHP versions simultaneously
<?php class CustomDOMDocument extends DOMDocument { public function getErrors() { return 42; } } function waa() { $doc = new CustomDOMDocument; $doc->loadHtml('<p>Test123</p>'); $xpath = new DOMXPath($doc); return $xpath; } $doc = new CustomDOMDocument; $doc->loadHtml('<p>Test123</p>'); $xpath = new DOMXPath($doc); var_dump(get_class($xpath->document)); $xpath = new DOMXPath(new CustomDOMDocument); var_dump(get_class($xpath->document)); $xpath = waa(); var_dump(get_class($xpath->document));

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.0100.01018.80
8.3.50.0150.00622.24
8.3.40.0130.00318.92
8.3.30.0140.00419.09
8.3.20.0020.00522.15
8.3.10.0120.00320.65
8.3.00.0040.00423.73
8.2.180.0070.00717.00
8.2.170.0100.01022.96
8.2.160.0030.01019.76
8.2.150.0080.00024.18
8.2.140.0060.00324.66
8.2.130.0050.00226.16
8.2.120.0040.00421.55
8.2.110.0070.01122.66
8.2.100.0030.00917.78
8.2.90.0000.00822.74
8.2.80.0080.00017.97
8.2.70.0000.00918.04
8.2.60.0050.00318.18
8.2.50.0000.00718.28
8.2.40.0000.00820.84
8.2.30.0040.00419.49
8.2.20.0000.00818.32
8.2.10.0000.00718.41
8.2.00.0030.00618.03
8.1.280.0150.00625.92
8.1.270.0090.00024.66
8.1.260.0000.00826.35
8.1.250.0050.00328.09
8.1.240.0100.00022.63
8.1.230.0040.00721.07
8.1.220.0040.00417.91
8.1.210.0030.00619.07
8.1.200.0080.00017.60
8.1.190.0000.00817.24
8.1.180.0000.00818.10
8.1.170.0040.00418.88
8.1.160.0050.00322.44
8.1.150.0000.00719.18
8.1.140.0020.00519.83
8.1.130.0000.00717.93
8.1.120.0000.00717.79
8.1.110.0040.00417.71
8.1.100.0000.00717.75
8.1.90.0040.00417.73
8.1.80.0040.00317.63
8.1.70.0040.00417.61
8.1.60.0030.00517.92
8.1.50.0000.00817.71
8.1.40.0000.00817.82
8.1.30.0060.00318.07
8.1.20.0050.00318.04
8.1.10.0040.00417.94
8.1.00.0000.00817.89
8.0.300.0000.00720.19
8.0.290.0090.00017.13
8.0.280.0030.00318.70
8.0.270.0030.00317.52
8.0.260.0000.00717.67
8.0.250.0070.00417.27
8.0.240.0000.00717.23
8.0.230.0030.00317.21
8.0.220.0000.00917.22
8.0.210.0000.00717.22
8.0.200.0070.00017.21
8.0.190.0080.00017.15
8.0.180.0070.00017.00
8.0.170.0040.00417.14
8.0.160.0060.00617.02
8.0.150.0040.00417.20
8.0.140.0030.00317.01
8.0.130.0000.00813.52
8.0.120.0040.00417.01
8.0.110.0030.00617.01
8.0.100.0040.00417.07
8.0.90.0040.00417.13
8.0.80.0150.00717.12
8.0.70.0090.00016.95
8.0.60.0000.00717.27
8.0.50.0040.00417.18
8.0.30.0020.01617.50
8.0.20.0100.01017.43
8.0.10.0000.00817.25
8.0.00.0090.00916.92
7.4.330.0000.00615.21
7.4.320.0000.00616.77
7.4.300.0000.00716.99
7.4.290.0040.00416.97
7.4.280.0000.00716.78
7.4.270.0000.00716.99
7.4.260.0030.00316.80
7.4.250.0030.00316.89
7.4.240.0030.00316.95
7.4.230.0000.00717.00
7.4.220.0110.01116.80
7.4.210.0150.00316.94
7.4.200.0000.00716.90
7.4.160.0030.01216.62
7.4.150.0150.00917.40
7.4.140.0090.00917.86
7.4.130.0100.01016.90
7.4.120.0080.01016.91
7.4.110.0070.01416.93
7.4.100.0090.00916.69
7.4.90.0030.01416.69
7.4.80.0110.01119.39
7.4.70.0100.00716.70
7.4.60.0030.01216.96
7.4.50.0100.00316.67
7.4.40.0000.01616.80
7.4.30.0120.00816.66
7.4.00.0050.01115.22
7.3.330.0030.00313.50
7.3.320.0030.00513.58
7.3.310.0030.00316.55
7.3.300.0030.00316.61
7.3.290.0070.01016.58
7.3.280.0080.01016.59
7.3.270.0070.01017.40
7.3.260.0140.00316.86
7.3.250.0120.00616.77
7.3.240.0130.00816.71
7.3.230.0150.00316.63
7.3.210.0150.00616.67
7.3.200.0120.00616.60
7.3.190.0180.00616.68
7.3.180.0100.00716.52
7.3.170.0030.01416.72
7.3.160.0100.00716.82
7.3.120.0040.01214.75
7.3.110.0000.01814.57
7.3.100.0090.00915.29
7.3.90.0060.00914.85
7.3.80.0000.01715.20
7.3.70.0090.00514.95
7.3.60.0030.00514.72
7.3.50.0030.01015.02
7.3.40.0120.00314.78
7.3.30.0030.00914.82
7.3.20.0070.01016.77
7.3.10.0060.00916.71
7.3.00.0060.00316.63
7.2.330.0070.01116.92
7.2.320.0130.00317.08
7.2.310.0000.01717.07
7.2.300.0090.00917.00
7.2.290.0060.01016.88
7.2.250.0150.00014.98
7.2.240.0070.01314.93
7.2.230.0120.00315.29
7.2.220.0040.01415.06
7.2.210.0100.00614.81
7.2.200.0000.01215.08
7.2.190.0080.00815.12
7.2.180.0040.00714.98
7.2.170.0060.01214.98
7.2.160.0030.01215.00
7.2.150.0090.00617.21
7.2.140.0070.00716.73
7.2.130.0030.00717.11
7.2.120.0060.00917.05
7.2.110.0090.00616.97
7.2.100.0090.00617.00
7.2.90.0040.01116.79
7.2.80.0070.00717.07
7.2.70.0030.00617.11
7.2.60.0200.00316.96
7.2.50.0120.00916.80
7.2.40.0100.00616.93
7.2.30.0000.01216.79
7.2.20.0120.00016.68
7.2.10.0030.01017.00
7.2.00.0070.00918.38
7.1.330.0060.00915.81
7.1.320.0000.01115.80
7.1.310.0070.01015.95
7.1.300.0040.01115.98
7.1.290.0090.00915.96
7.1.280.0000.01315.68
7.1.270.0040.01415.80
7.1.260.0060.00916.00
7.1.250.0030.01015.93
7.1.240.0080.00415.99
7.1.230.0100.00316.03
7.1.220.0030.01016.03
7.1.210.0070.00715.73
7.1.200.0050.00916.11
7.1.190.0000.00916.05
7.1.180.0060.01015.87
7.1.170.0120.00615.96
7.1.160.0070.01015.75
7.1.150.0030.01015.82
7.1.140.0040.00715.74
7.1.130.0070.00715.98
7.1.120.0060.00615.88
7.1.110.0030.01115.84
7.1.100.0070.00315.89
7.1.90.0000.01415.83
7.1.80.0030.00616.05
7.1.70.0050.00716.52
7.1.60.0020.01216.60
7.1.50.0000.01315.93
7.1.40.0040.01115.75
7.1.30.0070.00715.83
7.1.20.0100.00715.77
7.1.10.0120.00316.07
7.1.00.0100.03719.28
7.0.330.0030.00915.56
7.0.320.0000.01215.54
7.0.310.0070.00715.77
7.0.300.0040.01115.59
7.0.290.0060.00915.63
7.0.280.0030.00915.50
7.0.270.0060.01015.43
7.0.260.0080.00815.56
7.0.250.0000.01315.84
7.0.240.0000.01415.65
7.0.230.0000.01215.46
7.0.220.0030.01015.65
7.0.210.0110.00015.45
7.0.200.0070.00416.30
7.0.190.0060.00615.51
7.0.180.0060.00915.68
7.0.170.0080.00515.61
7.0.160.0030.00715.49
7.0.150.0040.00715.44
7.0.140.0070.00415.54
7.0.130.0080.00415.62
7.0.120.0070.00715.63
7.0.110.0030.03717.99
7.0.100.0080.03018.08
7.0.90.0100.02818.00
7.0.80.0110.03218.06
7.0.70.0130.03118.07
7.0.60.0130.03018.05
7.0.50.0200.03418.05
7.0.40.0160.03317.13
7.0.30.0200.03217.01
7.0.20.0230.02817.09
7.0.10.0190.02916.87
7.0.00.0220.02717.05
5.6.400.0000.00914.59
5.6.390.0040.01214.71
5.6.380.0030.00714.10
5.6.370.0090.00314.58
5.6.360.0130.00614.10
5.6.350.0090.00314.53
5.6.340.0060.00614.24
5.6.330.0040.01214.60
5.6.320.0080.00414.43
5.6.310.0080.00814.45
5.6.300.0040.00414.43
5.6.290.0070.00714.32
5.6.280.0060.00614.59
5.6.270.0040.01114.51
5.6.260.0100.02717.83
5.6.250.0100.03217.72
5.6.240.0100.03117.72
5.6.230.0120.03117.76
5.6.220.0100.03317.74
5.6.210.0130.02717.63
5.6.200.0110.03017.70
5.6.190.0050.03517.70
5.6.180.0050.03717.84
5.6.170.0090.03017.78
5.6.160.0120.03017.87
5.6.150.0050.03817.71
5.6.140.0080.03617.76
5.6.130.0110.02817.76
5.6.120.0070.03317.77
5.6.110.0070.03117.91
5.6.100.0120.03017.72
5.6.90.0100.03217.91
5.6.80.0100.03117.32
5.6.70.0060.03317.53
5.6.60.0070.03217.30
5.6.50.0050.03117.46
5.6.40.0080.03817.51
5.6.30.0050.03817.29
5.6.20.0030.04017.37
5.6.10.0080.03117.60
5.6.00.0050.03217.56

preferences:
98 ms | 401 KiB | 5 Q