3v4l.org

run code in 300+ PHP versions simultaneously
<?php class B { private $b; private $text; public function __construct($b) { $this->b = $b; } public function getText() { return $this->text; } public function setText($text) { $this->text = $text; } } class A { private $b; public function b() { return isset($b) ? $b : new B($this); } } $a = new A; $a->b()->setText('test'); echo $a->b()->getText();

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.0070.00716.38
8.3.50.0090.00918.10
8.3.40.0070.00718.90
8.3.30.0030.01018.75
8.3.20.0000.00720.33
8.3.10.0080.00020.47
8.3.00.0080.00020.65
8.2.180.0110.00718.30
8.2.170.0070.01422.96
8.2.160.0040.01120.35
8.2.150.0140.00025.66
8.2.140.0040.00424.66
8.2.130.0050.00319.23
8.2.120.0040.00426.35
8.2.110.0100.00622.20
8.2.100.0080.00417.93
8.2.90.0040.00419.09
8.2.80.0040.00417.97
8.2.70.0040.00417.63
8.2.60.0040.00418.04
8.2.50.0030.00618.09
8.2.40.0000.00720.23
8.2.30.0040.00419.32
8.2.20.0050.00317.70
8.2.10.0040.00418.05
8.2.00.0040.00418.09
8.1.280.0130.00725.92
8.1.270.0110.00423.87
8.1.260.0000.00828.09
8.1.250.0080.00028.09
8.1.240.0050.00522.61
8.1.230.0110.00017.66
8.1.220.0000.00817.74
8.1.210.0050.00318.77
8.1.200.0060.00317.23
8.1.190.0040.00417.23
8.1.180.0040.00418.10
8.1.170.0000.00818.51
8.1.160.0050.00222.58
8.1.150.0070.00018.93
8.1.140.0040.00419.55
8.1.130.0000.00717.57
8.1.120.0070.00017.30
8.1.110.0000.00717.33
8.1.100.0000.00717.41
8.1.90.0060.00317.45
8.1.80.0000.00817.29
8.1.70.0000.00717.41
8.1.60.0080.00017.47
8.1.50.0000.00817.45
8.1.40.0040.00417.51
8.1.30.0000.00817.55
8.1.20.0080.00017.50
8.1.10.0040.00417.54
8.1.00.0000.00817.46
8.0.300.0040.00418.77
8.0.290.0040.00416.75
8.0.280.0000.00718.36
8.0.270.0030.00317.16
8.0.260.0000.00617.27
8.0.250.0030.00316.93
8.0.240.0070.00016.91
8.0.230.0070.00016.78
8.0.220.0030.00316.70
8.0.210.0030.00316.74
8.0.200.0000.00716.80
8.0.190.0060.00316.79
8.0.180.0000.00816.89
8.0.170.0000.00716.77
8.0.160.0030.00316.72
8.0.150.0040.00416.66
8.0.140.0060.00516.68
8.0.130.0000.00613.29
8.0.120.0040.00416.68
8.0.110.0070.00016.71
8.0.100.0050.00216.73
8.0.90.0070.00016.71
8.0.80.0000.01716.76
8.0.70.0000.00716.71
8.0.60.0040.00416.71
8.0.50.0070.00016.89
8.0.30.0110.00917.21
8.0.20.0100.00817.40
8.0.10.0000.00816.82
8.0.00.0150.00916.92
7.4.330.0000.00516.79
7.4.320.0000.00616.55
7.4.300.0000.00616.48
7.4.290.0000.00616.64
7.4.280.0040.00416.50
7.4.270.0030.00316.52
7.4.260.0000.00716.57
7.4.250.0000.00716.53
7.4.240.0030.00316.62
7.4.230.0040.00416.35
7.4.220.0180.00716.47
7.4.210.0040.01416.69
7.4.200.0050.00216.66
7.4.160.0070.00716.39
7.4.150.0060.01217.40
7.4.140.0110.00717.86
7.4.130.0140.00416.59
7.4.120.0090.00816.58
7.4.110.0120.00616.19
7.4.100.0160.00916.50
7.4.90.0070.01116.27
7.4.80.0070.01019.39
7.4.70.0110.00716.66
7.4.60.0060.00916.58
7.4.50.0080.00816.46
7.4.40.0120.00616.45
7.4.30.0170.00016.44
7.4.00.0060.00914.85
7.3.330.0030.00313.11
7.3.320.0020.00313.08
7.3.310.0050.00216.14
7.3.300.0000.00716.23
7.3.290.0080.00716.27
7.3.280.0080.01216.24
7.3.270.0060.01217.40
7.3.260.0140.01016.44
7.3.250.0160.01416.29
7.3.240.0080.01016.32
7.3.230.0090.00916.39
7.3.210.0070.01016.37
7.3.200.0070.01019.39
7.3.190.0130.00616.37
7.3.180.0130.00816.24
7.3.170.0110.01116.41
7.3.160.0080.00816.40
7.2.330.0170.00716.60
7.2.320.0120.01216.69
7.2.310.0060.01216.59
7.2.300.0040.01416.74
7.2.290.0100.00616.59
7.2.60.0000.01116.98
7.2.00.0040.01119.46
7.1.200.0100.00015.68
7.1.100.0070.00718.16
7.1.70.0030.00316.87
7.1.60.0140.01119.19
7.1.00.0030.07722.42
7.0.200.0000.00816.47
7.0.60.0030.08321.59
7.0.50.0130.07717.84
7.0.40.0130.05020.04
7.0.30.0330.06320.09
7.0.20.0330.07720.22
7.0.10.0030.04720.16
7.0.00.0170.04720.02
5.6.280.0030.07320.90
5.6.210.0030.04320.76
5.6.200.0070.08018.29
5.6.190.0070.06020.48
5.6.180.0230.03720.54
5.6.170.0230.04720.50
5.6.160.0070.05020.49
5.6.150.0070.08318.23
5.6.140.0100.08018.15
5.6.130.0030.07718.15
5.6.120.0070.05021.13
5.6.110.0000.05021.14
5.6.100.0130.05320.99
5.6.90.0100.06320.97
5.6.80.0170.04020.54
5.5.350.0030.09720.41
5.5.340.0070.06718.09
5.5.330.0070.04320.47
5.5.320.0130.06020.32
5.5.310.0200.08720.27
5.5.300.0030.08317.98
5.5.290.0100.03717.97
5.5.280.0070.07020.80
5.5.270.0200.06720.88
5.5.260.0130.07720.98
5.5.250.0000.04320.55
5.5.240.0030.05020.24

preferences:
57.55 ms | 400 KiB | 5 Q