3v4l.org

run code in 300+ PHP versions simultaneously
<?php $date_teste = date('Y-m-d', strtotime('last day of last month')); var_dump($date_teste); $date_teste = new DateTime('last day of last month'); var_dump($date_teste);

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.140.0070.01116.69
8.3.130.0000.00818.39
8.3.120.0130.00620.75
8.3.110.0140.00922.03
8.3.100.0040.00416.67
8.3.90.0140.00418.72
8.3.80.0040.00818.43
8.3.70.0070.01118.15
8.3.60.0100.00618.55
8.3.50.0070.00717.08
8.3.40.0120.00318.84
8.3.30.0060.00918.50
8.3.20.0000.00819.20
8.3.10.0040.00423.66
8.3.00.0070.00020.61
8.2.250.0050.00316.67
8.2.240.0080.00017.26
8.2.230.0080.00022.58
8.2.220.0060.00324.06
8.2.210.0080.00026.77
8.2.200.0030.00618.41
8.2.190.0140.00316.75
8.2.180.0070.01118.55
8.2.170.0160.00022.96
8.2.160.0100.00322.20
8.2.150.0070.00024.18
8.2.140.0050.00324.66
8.2.130.0080.00019.66
8.2.120.0040.00426.35
8.2.110.0090.00022.41
8.2.100.0090.00317.97
8.2.90.0030.00622.34
8.2.80.0040.00418.05
8.2.70.0110.00458.90
8.2.60.0100.00758.96
8.2.50.0070.00758.92
8.2.40.0100.00559.32
8.2.30.0040.00959.36
8.2.20.0080.00658.90
8.2.10.0090.00558.88
8.2.00.0090.00458.82
8.1.300.0040.00418.81
8.1.290.0030.00618.88
8.1.280.0130.00725.92
8.1.270.0080.00022.17
8.1.260.0050.00326.35
8.1.250.0040.00428.09
8.1.240.0110.00022.10
8.1.230.0080.00322.84
8.1.220.0030.00517.91
8.1.210.0050.00318.85
8.1.200.0060.00858.71
8.1.190.0100.00458.73
8.1.180.0080.00658.92
8.1.170.0080.00659.16
8.1.160.0070.00659.18
8.1.150.0070.00659.16
8.1.140.0040.01060.24
8.1.130.0110.00258.74
8.1.120.0090.00458.76
8.1.110.0100.00458.79
8.1.100.0070.00658.73
8.1.90.0070.00658.75
8.1.80.0070.00635.25
8.1.70.0080.00538.17
8.1.60.0080.00638.21
8.1.50.0110.00438.18
8.1.40.0090.00638.19
8.1.30.0110.00538.31
8.1.20.0110.00338.25
8.1.10.0090.00538.19
8.1.00.0100.00438.21
8.0.300.0070.00020.00
8.0.290.0110.00358.51
8.0.280.0100.00459.03
8.0.270.0110.00358.52
8.0.260.0080.00658.57
8.0.250.0090.00558.61
8.0.240.0100.00358.61
8.0.230.0080.00558.61
8.0.220.0120.00458.58
8.0.210.0090.00441.94
8.0.200.0100.00437.82
8.0.190.0090.00437.83
8.0.180.0110.00237.80
8.0.170.0100.00337.82
8.0.160.0100.00337.83
8.0.150.0080.00537.70
8.0.140.0090.00437.75
8.0.130.0060.00427.69
8.0.120.0100.00337.79
8.0.110.0070.00637.79
8.0.100.0090.00537.73
8.0.90.0080.00637.83
8.0.80.0120.00434.85
8.0.70.0090.00437.81
8.0.60.0090.00437.83
8.0.50.0080.00637.80
8.0.30.0090.00732.68
8.0.20.0130.00434.90
8.0.10.0110.00337.89
8.0.00.0080.00632.66
7.4.330.0090.00634.87
7.4.320.0100.00358.41
7.4.300.0080.00537.54
7.4.290.0060.00737.56
7.4.280.0090.00537.54
7.4.270.0100.00437.51
7.4.260.0110.00337.50
7.4.250.0060.00637.58
7.4.240.0090.00537.54
7.4.230.0080.00537.57
7.4.220.0090.00437.50
7.4.210.0110.00432.34
7.4.200.0090.00437.54
7.4.190.0090.00541.77
7.4.180.0090.00541.71
7.4.160.0080.00832.32
7.4.150.0110.00437.49
7.4.140.0100.00628.54
7.4.130.0070.00734.49
7.4.120.0100.00728.02
7.4.110.0100.00534.45
7.4.100.0100.00634.49
7.4.90.0100.00534.49
7.4.80.0110.00434.86
7.4.70.0100.00534.47
7.4.60.0080.00534.47
7.4.50.0070.00734.42
7.4.40.0110.00434.41
7.4.30.0080.00537.44
7.4.20.0100.00437.46
7.4.10.0080.00734.25
7.4.00.0080.00631.87
7.3.330.0090.00536.72
7.3.320.0110.00436.73
7.3.310.0110.00337.34
7.3.300.0080.00537.33
7.3.290.0100.00337.27
7.3.280.0110.00634.30
7.3.270.0130.00337.37
7.3.260.0110.00628.96
7.3.250.0120.00537.36
7.3.240.0100.00628.97
7.3.230.0100.00634.37
7.3.220.0110.00637.33
7.3.210.0120.00634.36
7.3.200.0090.00834.38
7.3.190.0100.00734.38
7.3.180.0110.00534.32
7.3.170.0110.00734.32
7.3.160.0110.00534.32
7.3.150.0120.00437.35
7.3.140.0130.00437.36
7.3.130.0120.00534.19
7.3.120.0110.00434.17
7.3.110.0100.00734.16
7.3.100.0100.00634.05
7.3.90.0090.00634.22
7.3.80.0120.00434.06
7.3.70.0110.00534.13
7.3.60.0100.00634.13
7.3.50.0110.00531.74
7.3.40.0100.00531.78
7.3.30.0100.00731.71
7.3.20.0120.00532.43
7.3.10.0100.00730.61
7.3.00.0100.00730.58
7.2.340.0120.00537.43
7.2.330.0130.00634.50
7.2.320.0110.00834.45
7.2.310.0130.00534.47
7.2.300.0090.00834.47
7.2.290.0100.00734.48
7.2.280.0160.00237.49
7.2.270.0140.00437.45
7.2.260.0120.00534.27
7.2.250.0120.00534.32
7.2.240.0120.00534.26
7.2.230.0090.00734.26
7.2.220.0120.00534.24
7.2.210.0120.00634.25
7.2.200.0140.00534.26
7.2.190.0100.00734.30
7.2.180.0100.00731.90
7.2.170.0100.00631.93
7.2.160.0120.00631.90
7.2.150.0110.00632.56
7.2.140.0110.00632.62
7.2.130.0100.00730.88
7.2.120.0130.00430.78
7.2.110.0110.00629.24
7.2.100.0100.00929.20
7.2.90.0120.00729.27
7.2.80.0150.00529.20
7.2.70.0170.00529.24
7.2.60.0150.00629.22
7.2.50.0140.00529.26
7.2.40.0110.00829.29
7.2.30.0180.00429.28
7.2.20.0160.00529.26
7.2.10.0130.00729.25
7.2.00.0130.00529.29
7.1.330.0120.00434.46
7.1.320.0110.00534.49
7.1.310.0100.00634.47
7.1.300.0110.00534.49
7.1.290.0110.00534.45
7.1.280.0110.00631.88
7.1.270.0120.00531.81
7.1.260.0100.00631.88
7.1.250.0110.00730.07
7.1.240.0110.00731.84
7.1.230.0120.00529.91
7.1.220.0140.00529.93
7.1.210.0150.00429.89
7.1.200.0140.00629.93
7.1.190.0190.00729.92
7.1.180.0130.00629.88
7.1.170.0150.00629.84
7.1.160.0140.00729.91
7.1.150.0150.00729.92
7.1.140.0140.00429.91
7.1.130.0150.00729.92
7.1.120.0150.00429.88
7.1.110.0130.00529.90
7.1.100.0150.00429.83
7.1.90.0140.00529.91
7.1.80.0170.00429.92
7.1.70.0120.00629.78
7.1.60.0180.00431.94
7.1.50.0140.00731.88
7.1.40.0140.00531.83
7.1.30.0160.00631.87
7.1.20.0170.00731.91
7.1.10.0140.00629.77
7.1.00.0160.00429.83
7.0.330.0120.00633.87
7.0.320.0130.00337.16
7.0.310.0150.00237.23
7.0.300.0110.00637.24
7.0.290.0120.00537.30
7.0.280.0130.00437.25
7.0.270.0180.00337.26
7.0.260.0130.00337.19
7.0.250.0120.00437.26
7.0.240.0130.00437.31
7.0.230.0110.00537.33
7.0.220.0130.00337.30
7.0.210.0100.00637.27
7.0.200.0130.00437.35
7.0.190.0130.00437.29
7.0.180.0130.00337.24
7.0.170.0120.00537.35
7.0.160.0120.00437.19
7.0.150.0130.00437.21
7.0.140.0110.00537.24
7.0.130.0090.00737.26
7.0.120.0100.00737.37
7.0.110.0120.00437.31
7.0.100.0120.00537.24
7.0.90.0130.00537.20
7.0.80.0110.00637.30
7.0.70.0120.00537.26
7.0.60.0150.00237.29
7.0.50.0130.00637.25
7.0.40.0120.00537.31
7.0.30.0110.00637.27
7.0.20.0110.00537.27
7.0.10.0110.00537.29
7.0.00.0100.00737.27
5.6.400.0110.00633.92
5.6.390.0110.00633.92
5.6.380.0110.00531.40
5.6.370.0110.00637.11
5.6.360.0110.00537.12
5.6.350.0110.00537.16
5.6.340.0120.00537.12
5.6.330.0090.00837.12
5.6.320.0110.00537.12
5.6.310.0110.00537.12
5.6.300.0120.00437.10
5.6.290.0120.00437.09
5.6.280.0120.00437.11
5.6.270.0120.00537.14
5.6.260.0110.00537.10
5.6.250.0120.00537.05
5.6.240.0120.00637.05
5.6.230.0100.00837.15
5.6.220.0100.00737.14
5.6.210.0120.00437.13
5.6.200.0100.00737.14
5.6.190.0100.00637.13
5.6.180.0130.00337.07
5.6.170.0130.00437.21
5.6.160.0100.00637.13
5.6.150.0120.00537.06
5.6.140.0110.00537.17
5.6.130.0130.00537.14
5.6.120.0100.00537.12
5.6.110.0130.00337.16
5.6.100.0100.00637.09
5.6.90.0120.00537.13
5.6.80.0100.00537.13
5.6.70.0130.00337.18
5.6.60.0130.00337.16
5.6.50.0090.00637.07
5.6.40.0100.00637.06
5.6.30.0090.00737.05
5.6.20.0090.00637.02
5.6.10.0090.00736.98
5.6.00.0100.00637.02

preferences:
19.42 ms | 403 KiB | 5 Q