3v4l.org

run code in 300+ PHP versions simultaneously
<?php foreach (['Etc/GMT+12', 'Etc/GMT-10'] as $timezone) { $dTZ = new DateTimeZone($timezone); // Create a DateTime using the DateTimeZone object // This will display both formatted and unix timestamp as expected $dT = new DateTime('2013-12-13 18:49:00', $dTZ); echo $dT->format('Y-m-d H:i:s T'), PHP_EOL; echo $dT->getTimestamp(), PHP_EOL; // Create a DateTime using only a string representation // This will display the formatted date/time as expected, // but with the incorrect timezone // The value returned by getTimestamp() for format('U') will // be off by 2*offset $dT2 = new DateTime($dT->format('Y-m-d H:i:s T')); echo $dT2->format('Y-m-d H:i:s T'), PHP_EOL; echo $dT2->getTimestamp(), PHP_EOL, PHP_EOL; }

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.01516.88
8.3.50.0160.00621.28
8.3.40.0040.01118.83
8.3.30.0070.00718.82
8.3.20.0140.00420.23
8.3.10.0080.00023.61
8.3.00.0040.00422.39
8.2.180.0120.00916.88
8.2.170.0100.00722.96
8.2.160.0100.00320.36
8.2.150.0050.00324.18
8.2.140.0030.00524.66
8.2.130.0040.00426.16
8.2.120.0050.00220.90
8.2.110.0030.00620.53
8.2.100.0060.00617.91
8.2.90.0000.00919.76
8.2.80.0040.00419.48
8.2.70.0060.00317.88
8.2.60.0000.00818.16
8.2.50.0030.00618.07
8.2.40.0080.00018.16
8.2.30.0000.00818.25
8.2.20.0030.00517.95
8.2.10.0040.00418.15
8.2.00.0030.00617.98
8.1.280.0110.00725.92
8.1.270.0090.00020.38
8.1.260.0060.00326.35
8.1.250.0030.00528.09
8.1.240.0030.00623.73
8.1.230.0070.00422.08
8.1.220.0040.00417.78
8.1.210.0000.00918.91
8.1.200.0000.01017.47
8.1.190.0060.00317.25
8.1.180.0060.00318.10
8.1.170.0060.00318.75
8.1.160.0000.00818.79
8.1.150.0000.00918.91
8.1.140.0060.00317.42
8.1.130.0040.00417.72
8.1.120.0070.00017.66
8.1.110.0050.00217.62
8.1.100.0070.00017.57
8.1.90.0040.00417.63
8.1.80.0000.00817.65
8.1.70.0030.00317.48
8.1.60.0040.00417.69
8.1.50.0040.00417.50
8.1.40.0000.00817.63
8.1.30.0050.00317.72
8.1.20.0000.00817.56
8.1.10.0040.00417.71
8.1.00.0030.00517.64
8.0.300.0000.00820.04
8.0.290.0000.00816.88
8.0.280.0030.00318.55
8.0.270.0000.00817.36
8.0.260.0030.00317.22
8.0.250.0000.00717.14
8.0.240.0000.00717.08
8.0.230.0000.00717.07
8.0.220.0000.00717.05
8.0.210.0000.00717.12
8.0.200.0000.00616.98
8.0.190.0000.00817.13
8.0.180.0030.00516.94
8.0.170.0030.00617.05
8.0.160.0030.00317.15
8.0.150.0080.00017.02
8.0.140.0030.00516.97
8.0.130.0000.00613.48
8.0.120.0040.00416.93
8.0.110.0040.00416.98
8.0.100.0000.00817.09
8.0.90.0040.00416.93
8.0.80.0190.00317.09
8.0.70.0000.00816.98
8.0.60.0000.00717.12
8.0.50.0000.00716.93
8.0.30.0090.00717.28
8.0.20.0120.01117.40
8.0.10.0000.00717.12
8.0.00.0150.00316.78
7.4.330.0060.00015.08
7.4.320.0030.00316.68
7.4.300.0000.00716.57
7.4.290.0070.00016.65
7.4.280.0110.00016.64
7.4.270.0030.00316.63
7.4.260.0000.01016.45
7.4.250.0040.00416.61
7.4.240.0030.00516.62
7.4.230.0000.00716.59
7.4.220.0090.00916.73
7.4.210.0070.00716.77
7.4.200.0070.00016.80
7.4.160.0150.00916.72
7.4.150.0120.00617.40
7.4.140.0130.00617.86
7.4.130.0070.01016.71
7.4.120.0110.00816.59
7.4.110.0140.00916.81
7.4.100.0080.01516.59
7.4.90.0120.00616.54
7.4.80.0150.00619.39
7.4.70.0050.01416.62
7.4.60.0030.01316.65
7.4.50.0030.00616.56
7.4.40.0090.00616.66
7.4.30.0190.00516.50
7.4.00.0070.01015.23
7.3.330.0050.00513.35
7.3.320.0030.00313.27
7.3.310.0000.00716.46
7.3.300.0000.00716.30
7.3.290.0060.00916.45
7.3.280.0050.01116.46
7.3.270.0090.01617.40
7.3.260.0140.00716.63
7.3.250.0120.00816.56
7.3.240.0110.00516.60
7.3.230.0130.00616.46
7.3.210.0130.00316.59
7.3.200.0110.00719.39
7.3.190.0050.01116.42
7.3.180.0110.00616.39
7.3.170.0040.01516.49
7.3.160.0110.00916.45
7.2.330.0070.01016.56
7.2.320.0070.01316.93
7.2.310.0120.00616.82
7.2.300.0130.01016.68
7.2.290.0110.00716.74
7.2.60.0040.00817.23
7.2.00.0030.00919.65
7.1.200.0030.01015.76
7.1.100.0030.01118.42
7.1.70.0570.00415.40
7.1.60.0360.01115.68
7.1.50.0270.01815.28
7.1.40.0610.01614.94
7.1.30.0360.01414.94
7.1.20.0390.00314.97
7.1.10.0410.01514.94
7.1.00.0440.01115.15
7.0.200.0470.00314.94
7.0.190.0330.01015.06
7.0.180.0780.00914.94
7.0.170.0350.00614.94
7.0.160.0350.00414.94
7.0.150.2230.01014.94
7.0.140.0780.00014.94
7.0.130.0430.00314.94
7.0.120.0340.00714.94
7.0.110.0390.00414.94
7.0.100.0420.00014.94
7.0.90.0200.00914.94
7.0.80.0330.00914.94
7.0.70.0320.00314.94
7.0.60.0280.00814.94
7.0.50.0380.00314.94
7.0.40.0110.00714.94
7.0.30.0150.01014.94
7.0.20.0060.00614.94
7.0.10.0060.00614.94
7.0.00.0050.00714.94
5.6.300.0170.05720.82
5.6.290.0120.04120.84
5.6.280.0300.03620.88
5.6.270.0180.08320.87
5.6.260.0140.03820.86
5.6.250.0140.06321.03
5.6.240.0070.08020.98
5.6.230.0140.03820.95
5.6.220.0030.04720.95
5.6.210.0070.04821.01
5.6.200.0140.03920.98
5.6.190.0160.03921.02
5.6.180.0100.04221.04
5.6.170.0030.05221.02
5.6.160.0160.03520.97
5.6.150.0070.08721.01
5.6.140.0070.04620.85
5.6.130.0070.04420.98
5.6.120.0100.07120.86
5.6.110.0030.06220.91
5.6.100.0100.08920.97
5.6.90.0170.03520.84
5.6.80.0100.07220.36
5.6.70.0130.07920.11
5.6.60.0000.05820.18
5.6.50.0070.04420.41
5.6.40.0070.04020.38
5.6.30.0040.07120.35
5.6.20.0160.05520.21
5.6.10.0130.07020.20
5.6.00.0150.04220.33
5.5.380.0030.04417.62
5.5.370.0130.03517.44
5.5.360.0130.03917.45
5.5.350.0070.04617.54
5.5.340.0100.03617.74
5.5.330.0030.04218.03
5.5.320.0070.04118.07
5.5.310.0070.04217.94
5.5.300.0030.04317.74
5.5.290.0100.03918.06
5.5.280.0100.04018.02
5.5.270.0000.05818.02
5.5.260.0130.04517.93
5.5.250.0040.04617.84
5.5.240.0030.04017.41
5.5.230.0160.04617.21
5.5.220.0130.05717.25
5.5.210.0000.04617.45
5.5.200.0030.05817.09
5.5.190.0100.03517.38
5.5.180.0070.04317.17
5.5.160.0090.03917.39
5.5.150.0030.04117.37
5.5.140.0040.04417.38
5.5.130.0100.03917.46
5.5.120.0070.03917.21
5.5.110.0040.03917.02
5.5.100.0100.03417.22
5.5.90.0130.03817.27
5.5.80.0070.03617.29
5.5.70.0000.05517.21
5.5.60.0060.03717.31
5.5.50.0040.03916.98
5.5.40.0030.07517.18
5.5.30.0070.03617.10
5.5.20.0070.04217.10
5.5.10.0030.04517.35
5.5.00.0040.04617.34
5.4.450.0100.05519.31
5.4.440.0100.08019.15
5.4.430.0100.07719.43
5.4.420.0070.04019.23
5.4.410.0060.04219.11
5.4.400.0000.04619.06
5.4.390.0070.03919.14
5.4.380.0070.04619.07
5.4.370.0140.05919.14
5.4.360.0000.05918.91
5.4.350.0070.03718.83
5.4.340.0040.06718.98
5.4.320.0030.04419.02
5.4.310.0100.03719.13
5.4.300.0070.03818.89
5.4.290.0070.03819.04
5.4.280.0070.04118.82
5.4.270.0070.04118.85
5.4.260.0060.03719.08
5.4.250.0040.03918.93
5.4.240.0170.05119.13
5.4.230.0070.03619.00
5.4.220.0070.04019.06
5.4.210.0040.03918.97
5.4.200.0000.05919.04
5.4.190.0090.03319.05
5.4.180.0090.04019.13
5.4.170.0070.03619.05
5.4.160.0100.03718.96
5.4.150.0030.04119.04
5.4.140.0040.03916.65
5.4.130.0030.03616.39
5.4.120.0070.03416.44
5.4.110.0120.02916.67
5.4.100.0040.03916.66
5.4.90.0060.03816.40
5.4.80.0090.03516.62
5.4.70.0060.03916.61
5.4.60.0070.03416.55
5.4.50.0030.04116.47
5.4.40.0030.03816.61
5.4.30.0030.03816.31
5.4.20.0170.04416.61
5.4.10.0090.04016.55
5.4.00.0060.03515.77
5.3.290.0030.04214.94
5.3.280.0000.04614.94
5.3.270.0030.05114.94
5.3.260.0100.04014.94
5.3.250.0100.03314.94
5.3.240.0000.04114.94
5.3.230.0000.04614.94
5.3.220.0100.03114.94
5.3.210.0030.04514.94
5.3.200.0110.03914.94
5.3.190.0000.04614.94
5.3.180.0000.04214.94
5.3.170.0070.03414.94
5.3.160.0090.03514.94
5.3.150.0060.04114.94
5.3.140.0000.04214.94
5.3.130.0130.04514.94
5.3.120.0040.04414.94
5.3.110.0100.05514.94
5.3.100.0000.07614.94
5.3.90.0040.06714.94
5.3.80.0000.04314.94
5.3.70.0000.04314.94
5.3.60.0000.05414.94
5.3.50.0090.04314.94
5.3.40.0070.04614.94
5.3.30.0070.07714.94
5.3.20.0170.05414.94
5.3.10.0030.04214.94
5.3.00.0130.03314.94
5.2.170.0100.03314.94
5.2.160.0090.05114.94
5.2.150.0030.04014.94
5.2.140.0030.03414.94
5.2.130.0100.05614.94
5.2.120.0000.07114.94
5.2.110.0060.02814.94
5.2.100.0150.02414.94
5.2.90.0030.03114.94
5.2.80.0100.02914.94
5.2.70.0150.02314.94
5.2.60.0000.03414.94
5.2.50.0090.02814.94
5.2.40.0030.03314.94
5.2.30.0060.05114.94
5.2.20.0000.04514.94
5.2.10.0060.02614.94
5.2.00.0070.03714.94
5.1.60.0120.05214.94
5.1.50.0060.02614.94
5.1.40.0040.03214.94
5.1.30.0100.05714.94
5.1.20.0030.03014.94
5.1.10.0030.03114.94
5.1.00.0000.03014.94
5.0.50.0000.02314.94
5.0.40.0030.01914.94
5.0.30.0060.03314.94
5.0.20.0030.02014.94
5.0.10.0090.01514.94
5.0.00.0030.03014.94
4.4.90.0070.01314.94
4.4.80.0030.01714.94
4.4.70.0030.03414.94
4.4.60.0070.01814.94
4.4.50.0090.02414.94
4.4.40.0060.02214.94
4.4.30.0090.02214.94
4.4.20.0070.01114.94
4.4.10.0070.01114.94
4.4.00.0040.02614.94
4.3.110.0030.01714.94
4.3.100.0030.01614.94
4.3.90.0090.01514.94
4.3.80.0040.02514.94
4.3.70.0090.00914.94
4.3.60.0000.01914.94
4.3.50.0030.01714.94
4.3.40.0030.02414.94
4.3.30.0030.02414.94
4.3.20.0060.01314.94
4.3.10.0030.02214.94
4.3.00.0030.02614.94

preferences:
67.58 ms | 401 KiB | 5 Q