3v4l.org

run code in 300+ PHP versions simultaneously
<?php $tz = new DateTimeZone('Europe/Amsterdam'); $now = new DateTime('2015-10-01', $tz); $then = new DateTime('2015-01-01', $tz); $diff = $now->diff($then); print_r($diff); $now = new DateTime('2015-09-01', $tz); $then = new DateTime('2015-01-01', $tz); $diff = $now->diff($then); print_r($diff); $now = new DateTime('2015-11-01', $tz); $then = new DateTime('2015-01-01', $tz); $diff = $now->diff($then); print_r($diff);

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.0.110.0000.00817.07
8.0.100.0000.00816.90
8.0.90.0000.00817.13
8.0.80.0110.00317.06
8.0.70.0050.00317.00
8.0.60.0000.00717.02
8.0.50.0020.00516.98
8.0.30.0110.00917.24
8.0.20.0150.00617.40
8.0.10.0000.00717.02
8.0.00.0090.00916.81
7.4.240.0020.00516.58
7.4.230.0030.00316.74
7.4.220.0110.00616.61
7.4.210.0050.01016.70
7.4.200.0030.00316.54
7.4.160.0130.01016.55
7.4.150.0160.00417.40
7.4.140.0150.01017.86
7.4.130.0110.00816.59
7.4.120.0100.00816.72
7.4.110.0050.01216.60
7.4.100.0150.00616.69
7.4.90.0060.01216.75
7.4.80.0170.00019.39
7.4.70.0060.01216.41
7.4.60.0100.00716.59
7.4.50.0040.00416.37
7.4.40.0060.01216.52
7.4.30.0140.01016.42
7.4.00.0070.01115.09
7.3.300.0000.00716.31
7.3.290.0110.00416.25
7.3.280.0070.01116.26
7.3.270.0070.01117.40
7.3.260.0150.00416.61
7.3.250.0100.00716.70
7.3.240.0090.00916.20
7.3.230.0080.00816.46
7.3.210.0070.01016.53
7.3.200.0060.01016.38
7.3.190.0030.01316.55
7.3.180.0070.01016.63
7.3.170.0060.01016.45
7.3.160.0130.00716.37
7.3.10.0120.00816.66
7.3.00.0130.00916.87
7.2.330.0060.01316.81
7.2.320.0120.01216.66
7.2.310.0120.00916.44
7.2.300.0060.00916.79
7.2.290.0100.00716.90
7.2.130.0190.00216.96
7.2.120.0040.01516.49
7.2.110.0030.01016.80
7.2.100.0040.01116.94
7.2.90.0120.00316.80
7.2.80.0150.00616.51
7.2.70.0030.00916.89
7.2.60.0080.00816.88
7.2.50.0000.02016.95
7.2.40.0080.00416.83
7.2.30.0060.01016.80
7.2.20.0090.00616.58
7.2.10.0070.01016.92
7.2.00.0070.00818.02
7.1.250.0170.00415.79
7.1.240.0070.00715.87
7.1.230.0110.00415.75
7.1.220.0130.00415.52
7.1.210.0060.01315.91
7.1.200.0110.00715.83
7.1.190.0060.00615.92
7.1.180.0140.00715.87
7.1.170.0090.00915.59
7.1.160.0120.00615.55
7.1.150.0030.01315.70
7.1.140.0000.01715.96
7.1.130.0040.01115.68
7.1.120.0130.00215.63
7.1.110.0060.00715.80
7.1.100.0090.00517.10
7.1.90.0030.01315.90
7.1.80.0100.00716.01
7.1.70.0030.00616.37
7.1.60.0070.00717.53
7.1.50.0060.01516.47
7.1.40.0100.00715.84
7.1.30.0040.01115.91
7.1.20.0090.00616.02
7.1.10.0000.01515.84
7.1.00.0030.04519.01
7.0.330.0110.00415.41
7.0.320.0140.00415.30
7.0.310.0030.01015.46
7.0.300.0090.00615.38
7.0.290.0070.01015.53
7.0.280.0070.01015.52
7.0.270.0070.01015.52
7.0.260.0090.01115.32
7.0.250.0080.00815.71
7.0.240.0120.00315.45
7.0.230.0090.00915.39
7.0.220.0000.01515.19
7.0.210.0000.01415.50
7.0.200.0230.00814.99
7.0.190.0110.00415.45
7.0.180.0090.00615.55
7.0.170.0070.01115.55
7.0.160.0060.00915.65
7.0.150.0090.00615.27
7.0.140.0040.01215.61
7.0.130.0110.00415.39
7.0.120.0140.00315.35
7.0.110.0100.00615.50
7.0.100.0040.00815.52
7.0.90.0070.00715.61
7.0.80.0110.00315.23
7.0.70.0130.00315.38
7.0.60.0050.04817.63
7.0.50.0090.02216.57
7.0.40.0160.02316.75
7.0.30.0130.03516.65
7.0.20.0230.03816.79
7.0.10.0160.03516.97
7.0.00.0070.04916.85
5.6.380.0040.00914.27
5.6.370.0040.00714.52
5.6.360.0040.00814.26
5.6.350.0030.01514.13
5.6.340.0070.00714.40
5.6.330.0080.00814.17
5.6.320.0000.01614.09
5.6.310.0100.00714.39
5.6.300.0060.01214.30
5.6.290.0040.01414.48
5.6.280.0090.03417.82
5.6.270.0030.00614.66
5.6.260.0060.00914.44
5.6.250.0060.00914.63
5.6.240.0090.00614.46
5.6.230.0060.00314.22
5.6.220.0040.01414.20
5.6.210.0130.04017.67
5.6.200.0060.03516.08
5.6.190.0090.04117.39
5.6.180.0160.04117.44
5.6.170.0220.04317.27
5.6.160.0050.02517.14
5.6.150.0080.04516.20
5.6.140.0070.04616.23
5.6.130.0110.02716.25
5.6.120.0120.03717.79
5.6.110.0070.03717.71
5.6.100.0140.04017.52
5.6.90.0050.02617.68
5.6.80.0070.04517.45
5.6.70.1750.02317.31
5.6.60.0090.00614.20
5.6.50.0060.01014.20
5.6.40.0040.01214.28
5.6.30.0100.00714.50
5.6.20.0070.00714.00
5.6.10.0120.00314.49
5.6.00.0060.00914.55
5.5.380.0110.00310.95
5.5.370.0050.00511.04
5.5.360.0070.00310.98
5.5.350.0050.02515.71
5.5.340.0020.03014.63
5.5.330.0030.04315.62
5.5.320.0260.04015.73
5.5.310.0150.02815.69
5.5.300.0070.01814.58
5.5.290.0000.02714.51
5.5.280.0050.02316.05
5.5.270.0050.02916.04
5.5.260.0050.04915.92
5.5.250.0040.02215.77
5.5.240.2020.02215.70
5.5.230.0110.00410.89
5.5.220.0000.00710.94
5.5.210.0060.00611.13
5.5.200.0090.00311.02
5.5.190.0070.00711.27
5.5.180.0000.00610.93
5.5.170.0000.00711.20
5.5.160.0000.01011.27
5.5.150.0090.00311.31
5.5.140.0030.01010.84
5.5.130.0090.00310.91
5.5.120.0040.00710.85
5.5.110.0030.00711.27
5.5.100.0070.00010.96
5.5.90.0000.01011.04
5.5.80.0080.00311.17
5.5.70.0030.00911.19
5.5.60.0030.00311.10
5.5.50.0030.01211.06
5.5.40.0070.00710.91
5.5.30.0080.00411.19
5.5.20.0000.01211.00
5.5.10.0070.00711.06
5.5.00.0060.00610.89
5.4.450.0130.03715.38
5.4.440.0320.04015.04
5.4.430.0170.04015.32
5.4.420.0300.03415.22
5.4.410.0170.04015.04
5.4.400.0200.03214.80
5.4.390.0150.03814.99
5.4.380.0120.03415.06
5.4.370.0200.03015.04
5.4.360.0230.02815.19
5.4.350.0120.03815.03
5.4.340.0150.04314.98
5.4.330.0060.00310.86
5.4.320.0170.03115.02
5.4.310.0180.02814.86
5.4.300.0150.03014.93
5.4.290.0270.03214.98
5.4.280.0170.03715.11
5.4.270.0160.02914.89
5.4.260.0180.02614.89
5.4.250.0200.02214.94
5.4.240.0120.03015.04
5.4.230.0120.03515.14
5.4.220.0110.03015.04
5.4.210.0110.03015.12
5.4.200.0350.02514.89
5.4.190.0270.03715.12
5.4.180.0520.03615.14
5.4.170.0460.04214.94
5.4.160.0460.03015.10
5.4.150.0530.02614.99
5.4.140.0160.03013.65
5.4.130.0170.03013.68
5.4.120.0220.02313.77
5.4.110.0210.02513.72
5.4.100.0110.03313.63
5.4.90.0170.03613.73
5.4.80.0180.03013.57
5.4.70.0120.03613.51
5.4.60.0150.04313.49
5.4.50.0050.02313.69
5.4.40.0070.02713.62
5.4.30.0030.03613.53
5.4.20.0120.02213.44
5.4.10.0040.00810.85
5.4.00.0030.01010.73

preferences:
39.77 ms | 401 KiB | 5 Q