3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { private static self $singleton; public function __construct() { if(!isset(self::$singleton)) { self::$singleton = $this; } return self::$singleton; } } $a = new A; $b = new A; $c = new A; var_dump($a); var_dump($b); var_dump($c);

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.0140.00623.98
8.4.110.0130.00718.97
8.4.100.0130.00617.79
8.4.90.0140.00619.43
8.4.80.0030.00517.83
8.4.70.0030.00517.71
8.4.60.0050.00321.24
8.4.50.0090.00724.13
8.4.40.0160.00017.84
8.4.30.0130.00718.61
8.4.20.0070.01317.63
8.4.10.0060.00321.86
8.3.250.0080.01018.91
8.3.240.0070.00217.23
8.3.230.0110.00816.47
8.3.220.0050.00317.11
8.3.210.0110.00316.73
8.3.200.0100.00616.63
8.3.190.0120.00819.16
8.3.180.0130.00518.42
8.3.170.0150.00417.16
8.3.160.0000.01416.47
8.3.150.0120.00617.16
8.3.140.0040.00420.92
8.3.130.0000.00818.42
8.3.120.0030.00518.94
8.3.110.0130.00720.94
8.3.100.0030.00618.59
8.3.90.0050.00226.77
8.3.80.0040.00818.31
8.3.70.0100.01016.73
8.3.60.0090.00616.36
8.3.50.0100.00718.30
8.3.40.0120.00320.17
8.3.30.0040.01118.75
8.3.20.0000.00724.18
8.3.10.0050.00324.66
8.3.00.0000.00826.16
8.2.290.0110.00820.20
8.2.280.0060.00318.59
8.2.270.0110.00716.61
8.2.260.0070.00720.94
8.2.250.0090.00016.64
8.2.240.0090.00017.13
8.2.230.0040.00422.58
8.2.220.0090.00024.06
8.2.210.0040.00426.77
8.2.200.0060.00318.16
8.2.190.0110.00816.75
8.2.180.0070.01125.92
8.2.170.0120.00318.97
8.2.160.0030.01322.96
8.2.150.0080.00025.66
8.2.140.0030.00524.66
8.2.130.0000.00726.16
8.2.120.0090.00021.13
8.2.110.0030.00620.52
8.2.100.0060.00617.72
8.2.90.0000.00817.63
8.2.80.0060.00318.84
8.2.70.0080.00317.63
8.2.60.0040.00417.80
8.2.50.0040.00418.07
8.2.40.0040.00418.22
8.2.30.0000.00718.08
8.2.20.0070.00019.26
8.2.10.0040.00418.06
8.2.00.0040.00419.30
8.1.330.0120.00822.07
8.1.320.0140.00416.46
8.1.310.0000.00818.58
8.1.300.0090.00017.88
8.1.290.0040.00430.84
8.1.280.0090.00625.92
8.1.270.0070.00024.66
8.1.260.0060.00326.35
8.1.250.0080.00028.09
8.1.240.0120.00619.09
8.1.230.0120.00022.66
8.1.220.0000.00817.74
8.1.210.0040.00418.77
8.1.200.0060.00317.35
8.1.190.0000.00817.35
8.1.180.0040.00418.10
8.1.170.0000.00818.55
8.1.160.0000.00719.03
8.1.150.0000.00718.65
8.1.140.0050.00317.48
8.1.130.0030.00518.80
8.1.120.0000.00817.53
8.1.110.0030.00517.38
8.1.100.0070.00017.50
8.1.90.0070.00017.37
8.1.80.0040.00417.35
8.1.70.0040.00417.43
8.1.60.0000.00817.62
8.1.50.0030.00517.54
8.1.40.0040.00417.44
8.1.30.0040.00417.64
8.1.20.0060.00317.66
8.1.10.0040.01317.54
8.1.00.0130.00417.52
8.0.300.0070.00019.65
8.0.290.0070.00016.63
8.0.280.0060.00618.49
8.0.270.0020.00516.88
8.0.260.0030.00318.42
8.0.250.0000.00716.93
8.0.240.0000.00816.80
8.0.230.0110.00316.96
8.0.220.0110.00416.90
8.0.210.0100.00516.77
8.0.200.0110.00416.83
8.0.190.0120.00216.97
8.0.180.0060.00916.76
8.0.170.0110.00416.99
8.0.160.0100.00516.93
8.0.150.0120.00216.84
8.0.140.0140.00016.88
8.0.130.0040.01216.81
8.0.120.0120.00416.77
8.0.110.0140.00016.86
8.0.100.0120.00316.79
8.0.90.0000.01516.89
8.0.80.0130.00216.92
8.0.70.0080.00816.83
8.0.60.0080.00816.88
8.0.50.0080.00816.89
8.0.30.0090.00516.75
8.0.20.0130.00216.99
8.0.10.0100.00417.00
7.4.330.0040.00015.55
7.4.320.0060.00016.44
7.4.300.0070.01016.60
7.4.290.0140.00216.52
7.4.280.0080.00816.41
7.4.270.0160.00016.51
7.4.260.0180.00016.50
7.4.250.0100.00716.59
7.4.240.0170.00016.50
7.4.230.0180.00016.49
7.4.220.0140.00016.49
7.4.210.0090.00516.55
7.4.200.0140.00016.40
7.4.190.0150.00016.62
7.4.180.0110.00416.63
7.4.160.0050.00916.52
7.4.150.0030.01116.54
7.4.140.0050.00916.31
7.4.130.0140.00016.37
7.4.120.0080.00516.47
7.4.110.0140.00016.51
7.4.100.0090.00616.52
7.4.90.0150.00016.42
7.4.80.0100.00516.51
7.4.70.0080.00716.37
7.4.60.0130.00316.35
7.4.50.0100.00316.46
7.4.40.0120.00016.38
7.4.30.0110.00316.55
7.4.20.0070.00716.48
7.4.10.0090.00616.54
7.4.00.0110.00316.41

preferences:
49.93 ms | 403 KiB | 5 Q