3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Position { private $productId; private $count; private $createdAt; public function __construct(int $productId, int $count = 1) { $this->count = $count; $this->createdAt = new DateTimeImmutable('now'); } } $position = new Position(1); $secondPosition = new Position(1); var_dump($position == $secondPosition);

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.4.120.0050.00422.34
8.4.110.0140.00820.82
8.4.100.0090.00718.01
8.4.90.0070.01418.39
8.4.80.0130.00719.51
8.4.70.0150.00717.96
8.4.60.0100.01024.20
8.4.50.0100.01119.64
8.4.40.0120.00918.10
8.4.30.0090.00620.59
8.4.20.0100.01017.98
8.4.10.0000.00819.50
8.3.250.0100.00818.80
8.3.240.0130.00616.74
8.3.230.0120.00716.79
8.3.220.0140.00217.19
8.3.210.0110.00818.64
8.3.200.0050.00416.63
8.3.190.0050.00517.16
8.3.180.0120.00616.86
8.3.170.0000.01017.41
8.3.160.0040.01518.73
8.3.150.0070.01120.59
8.3.140.0030.00517.38
8.3.130.0030.00618.48
8.3.120.0070.01420.79
8.3.110.0080.00018.29
8.3.100.0060.00316.90
8.3.90.0100.01026.77
8.3.80.0060.00316.75
8.3.70.0030.01216.58
8.3.60.0040.01118.43
8.3.50.0090.00924.47
8.3.40.0000.01418.79
8.3.30.0120.00418.97
8.3.20.0070.00024.18
8.3.10.0000.00824.66
8.3.00.0060.00326.16
8.2.290.0100.00820.22
8.2.280.0100.00620.07
8.2.270.0140.00717.27
8.2.260.0070.00020.70
8.2.250.0040.00417.00
8.2.240.0030.00618.79
8.2.230.0030.00520.94
8.2.220.0090.00024.06
8.2.210.0160.00326.77
8.2.200.0060.00316.88
8.2.190.0040.01116.75
8.2.180.0150.00025.92
8.2.170.0100.01019.09
8.2.160.0140.00022.96
8.2.150.0050.00325.66
8.2.140.0060.00324.66
8.2.130.0070.00026.16
8.2.120.0040.00426.35
8.2.110.0030.00620.99
8.2.100.0120.00019.57
8.2.90.0060.00319.95
8.2.80.0060.00317.97
8.2.70.0050.00317.88
8.2.60.0000.00817.63
8.2.50.0050.00318.05
8.2.40.0050.00318.16
8.2.30.0040.00418.17
8.2.20.0040.00418.00
8.2.10.0040.00419.19
8.2.00.0040.00419.23
8.1.330.0120.00621.87
8.1.320.0130.01016.38
8.1.310.0160.00018.70
8.1.300.0040.00418.48
8.1.290.0030.00730.84
8.1.280.0170.00025.92
8.1.270.0030.00523.99
8.1.260.0040.01128.09
8.1.250.0000.00828.09
8.1.240.0070.00319.25
8.1.230.0040.00720.93
8.1.220.0000.00817.74
8.1.210.0030.00518.77
8.1.200.0030.00617.60
8.1.190.0000.00817.38
8.1.180.0040.00418.10
8.1.170.0030.00518.77
8.1.160.0070.00018.99
8.1.150.0040.00418.96
8.1.140.0080.00320.80
8.1.130.0070.00020.19
8.1.120.0040.00417.71
8.1.110.0050.00317.65
8.1.100.0040.00317.67
8.1.90.0000.01117.63
8.1.80.0040.00417.62
8.1.70.0070.00017.68
8.1.60.0050.00317.71
8.1.50.0000.00917.66
8.1.40.0080.00517.68
8.1.30.0040.00417.82
8.1.20.0080.00017.62
8.1.10.0050.00317.66
8.1.00.0050.01017.64
8.0.300.0080.00020.04
8.0.290.0040.00416.88
8.0.280.0000.00820.20
8.0.270.0020.00518.22
8.0.260.0000.00620.07
8.0.250.0030.00317.17
8.0.240.0000.00717.06
8.0.230.0040.00417.16
8.0.220.0000.00717.11
8.0.210.0040.00417.08
8.0.200.0030.00317.12
8.0.190.0040.00417.14
8.0.180.0040.00417.18
8.0.170.0000.00817.00
8.0.160.0070.00017.01
8.0.150.0000.00716.91
8.0.140.0000.00817.04
8.0.130.0000.00613.44
8.0.120.0030.00517.09
8.0.110.0000.00717.13
8.0.100.0040.00416.98
8.0.90.0070.00017.00
8.0.80.0100.00817.06
8.0.70.0000.00716.99
8.0.60.0040.00417.08
8.0.50.0040.00416.90
8.0.30.0040.02217.14
8.0.20.0060.01217.26
8.0.10.0050.00317.26
8.0.00.0170.00316.79
7.4.330.0020.00215.55
7.4.320.0000.00816.75
7.4.300.0070.00316.52
7.4.290.0000.00816.65
7.4.280.0060.00316.71
7.4.270.0030.00316.59
7.4.260.0050.00013.23
7.4.250.0030.00316.61
7.4.240.0000.00716.63
7.4.230.0070.00016.56
7.4.220.0020.00516.72
7.4.210.0060.00916.68
7.4.200.0000.00816.78
7.4.130.0110.00816.82
7.4.120.0130.00616.71
7.4.110.0120.00616.59
7.4.100.0110.00716.61
7.4.90.0070.01116.74
7.4.80.0120.00816.55
7.4.70.0120.00816.53
7.4.60.0150.00616.55
7.4.50.0080.01416.66
7.4.40.0150.00616.68
7.4.30.0120.00916.48
7.4.20.0170.00316.50
7.4.10.0150.00516.64
7.4.00.0110.00916.49
7.3.330.0070.00016.32
7.3.320.0030.00313.24
7.3.310.0000.00716.43
7.3.300.0040.00416.45
7.3.290.0070.00916.43
7.3.260.0100.01016.63
7.3.230.0090.00616.55
7.3.210.0130.00516.60
7.3.200.0110.00816.58
7.3.190.0100.01016.53
7.3.180.0090.00916.41
7.3.170.0110.00916.61
7.3.160.0090.01316.56
7.3.150.0180.00316.71
7.3.140.0120.00616.74
7.3.130.0120.00716.47
7.3.120.0080.01216.52
7.3.110.0100.00816.46
7.3.100.0130.00716.50
7.3.90.0090.00716.45
7.3.80.0070.01016.34
7.3.70.0120.00516.44
7.3.60.0080.01116.51
7.3.50.0120.00516.39
7.3.40.0100.01016.49
7.3.30.0060.01416.35
7.3.20.0090.01216.57
7.3.10.0180.00316.36
7.3.00.0150.00716.44
7.2.330.0150.00816.59
7.2.320.0110.00916.68
7.2.310.0150.00416.71
7.2.300.0180.00316.61
7.2.290.0110.01116.67
7.2.280.0080.01016.55
7.2.270.0130.00716.71
7.2.260.0050.01416.60
7.2.250.0110.01116.57
7.2.240.0090.01116.68
7.2.230.0130.00516.59
7.2.220.0110.00916.78
7.2.210.0080.01016.61
7.2.200.0100.01216.54
7.2.190.0120.00816.64
7.2.180.0120.00816.62
7.2.170.0150.00416.52
7.2.160.0110.01016.51
7.2.150.0180.00516.67
7.2.140.0100.01216.62
7.2.130.0120.01216.67
7.2.120.0290.00816.59
7.2.110.0120.01016.72
7.2.100.0180.00416.67
7.2.90.0090.01416.62
7.2.80.0110.01116.60
7.2.70.0070.01416.65
7.2.60.0110.01216.59
7.2.50.0160.00716.78
7.2.40.0210.01416.57
7.2.30.0150.00816.63
7.2.20.0110.01316.53
7.2.10.0120.00716.62
7.2.00.0140.00716.54

preferences:
30.75 ms | 403 KiB | 5 Q