3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Super { public $child; function setChild(Child $child){ echo "setting child to super\n"; $this->child = $child; if($child->getSuper() !== $this) $child->setSuper($this); } function getChild(){ return $this->child; } } class Child { public $super; function setSuper(Super $super){ echo "setting super to child\n"; $this->super = $super; if($super->getChild() !== $this) $this->super->setChild($this); } function getSuper(){ return $this->super; } } $super = new Super; $child = new Child; $super->setChild($child); var_dump($super); $super = new Super; $child = new Child; $child->setSuper($super); var_dump($super);

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.01116.50
8.3.50.0100.00922.05
8.3.40.0070.00718.96
8.3.30.0090.00618.67
8.3.20.0070.00020.37
8.3.10.0000.00823.66
8.3.00.0000.00819.38
8.2.180.0200.00318.16
8.2.170.0100.01022.96
8.2.160.0110.00420.39
8.2.150.0000.00824.18
8.2.140.0110.00324.66
8.2.130.0040.00426.16
8.2.120.0090.00017.63
8.2.110.0090.00020.53
8.2.100.0040.00717.80
8.2.90.0030.00519.22
8.2.80.0050.00317.97
8.2.70.0030.00517.50
8.2.60.0050.00317.93
8.2.50.0040.00418.07
8.2.40.0040.00419.45
8.2.30.0040.00420.50
8.2.20.0040.00417.61
8.2.10.0040.00417.98
8.2.00.0040.00417.86
8.1.280.0150.00625.92
8.1.270.0070.00022.19
8.1.260.0050.00326.35
8.1.250.0030.00628.09
8.1.240.0060.00322.54
8.1.230.0060.00617.66
8.1.220.0080.00017.74
8.1.210.0030.00618.77
8.1.200.0030.00617.35
8.1.190.0040.00417.35
8.1.180.0040.00418.10
8.1.170.0000.00818.53
8.1.160.0040.00421.87
8.1.150.0050.00320.61
8.1.140.0040.00419.47
8.1.130.0040.00417.65
8.1.120.0020.00517.43
8.1.110.0040.00417.39
8.1.100.0040.00417.40
8.1.90.0050.00317.30
8.1.80.0030.00317.29
8.1.70.0000.00817.29
8.1.60.0040.00417.64
8.1.50.0000.00817.53
8.1.40.0040.00417.53
8.1.30.0000.00817.64
8.1.20.0040.00417.65
8.1.10.0050.00217.57
8.1.00.0080.00017.43
8.0.300.0000.00818.77
8.0.290.0080.00016.75
8.0.280.0030.00318.55
8.0.270.0000.00717.17
8.0.260.0000.00717.16
8.0.250.0000.00817.00
8.0.240.0030.00316.93
8.0.230.0030.00316.96
8.0.220.0030.00316.87
8.0.210.0100.00016.93
8.0.200.0000.01016.94
8.0.190.0050.00316.84
8.0.180.0070.00016.84
8.0.170.0030.00516.80
8.0.160.0000.00816.86
8.0.150.0060.00316.80
8.0.140.0000.00716.76
8.0.130.0040.00413.30
8.0.120.0030.00516.86
8.0.110.0080.00016.82
8.0.100.0040.00416.93
8.0.90.0040.00416.79
8.0.80.0070.01016.89
8.0.70.0070.00016.86
8.0.60.0040.00416.78
8.0.50.0070.00016.80
8.0.30.0140.00416.86
8.0.20.0140.00517.40
8.0.10.0000.00717.02
8.0.00.0080.00916.81
7.4.330.0050.00015.08
7.4.320.0030.00316.56
7.4.300.0030.00316.49
7.4.290.0040.00416.35
7.4.280.0070.00016.61
7.4.270.0000.00716.46
7.4.260.0030.00316.63
7.4.250.0030.00516.54
7.4.240.0030.00516.54
7.4.230.0040.00416.45
7.4.220.0140.00316.47
7.4.210.0100.00316.63
7.4.200.0050.00316.50
7.4.160.0120.01216.51
7.4.150.0120.00617.40
7.4.140.0120.00817.86
7.4.130.0100.00716.51
7.4.120.0100.00816.47
7.4.110.0110.00816.52
7.4.100.0070.01116.48
7.4.90.0140.01016.52
7.4.80.0150.00919.39
7.4.70.0030.01416.48
7.4.60.0100.00716.56
7.4.50.0030.00516.60
7.4.40.0130.00316.57
7.4.30.0060.01616.41
7.4.00.0030.01215.07
7.3.330.0030.00313.07
7.3.320.0030.00313.22
7.3.310.0040.00416.26
7.3.300.0040.00416.15
7.3.290.0050.01016.30
7.3.280.0090.01016.29
7.3.270.0070.01017.40
7.3.260.0090.00916.28
7.3.250.0140.00616.22
7.3.240.0100.00916.30
7.3.230.0150.00616.40
7.3.210.0150.00716.47
7.3.200.0130.00316.41
7.3.190.0170.00716.35
7.3.180.0080.00816.46
7.3.170.0140.00916.35
7.3.160.0060.01216.43
7.2.330.0090.01316.57
7.2.320.0060.01616.86
7.2.310.0070.01116.68
7.2.300.0110.00616.57
7.2.290.0110.00816.52
7.2.60.0040.01216.73
7.2.00.0060.00619.20
7.1.200.0040.01615.58
7.1.100.0050.00518.09
7.1.70.0040.00417.27
7.1.60.0090.01519.43
7.1.50.0100.01316.87
7.1.00.0070.07322.36
7.0.200.0330.00414.94
7.0.60.0230.04019.81
7.0.50.0070.05317.93
7.0.40.0070.08720.02
7.0.30.0170.06720.09
7.0.20.0270.05720.21
7.0.10.0070.07720.07
7.0.00.0130.07020.09
5.6.280.0000.08021.11
5.6.210.0070.08720.67
5.6.200.0130.08018.19
5.6.190.0030.09320.57
5.6.180.0270.04320.50
5.6.170.0170.05020.62
5.6.160.0070.08320.44
5.6.150.0130.04318.18
5.6.140.0100.05718.16
5.6.130.0070.07718.11
5.6.120.0100.04321.16
5.6.110.0030.09021.13
5.6.100.0070.07021.12
5.6.90.0100.08020.99
5.6.80.0030.07720.38
5.5.350.0370.06320.45
5.5.340.0000.04717.96
5.5.330.0030.04020.27
5.5.320.0200.05320.26
5.5.310.0230.06020.34
5.5.300.0130.07717.96
5.5.290.0100.04717.99
5.5.280.0100.05020.78
5.5.270.0070.05020.78
5.5.260.0100.06320.90
5.5.250.0030.04320.73
5.5.240.0170.07720.17
5.4.450.0230.07319.42
5.4.440.0230.05719.57
5.4.430.0170.05019.48
5.4.420.0230.05019.17
5.4.410.0330.03719.26
5.4.400.0100.04319.22
5.4.390.0270.06719.20
5.4.380.0330.03719.06
5.4.370.0200.07019.09
5.4.360.0200.07719.06
5.4.350.0270.06019.19
5.4.340.0270.05319.20
5.4.320.0200.05019.09
5.4.310.0170.08319.15
5.4.300.0270.03319.24
5.4.290.0200.03719.31
5.4.280.0230.03018.93
5.4.270.0230.07719.31
5.4.260.0170.04019.23
5.4.250.0200.03718.94
5.4.240.0300.06318.85
5.4.230.0230.05319.09
5.4.220.0300.06319.23
5.4.210.0200.07719.30
5.4.200.0300.04718.98
5.4.190.0270.05319.12
5.4.180.0200.06319.14
5.4.170.0230.05718.93
5.4.160.0330.04019.29
5.4.150.0230.06319.14
5.4.140.0400.04016.37
5.4.130.0300.03716.33
5.4.120.0200.05316.71
5.4.110.0170.04716.45
5.4.100.0330.04316.50
5.4.90.0200.06716.61

preferences:
82.99 ms | 401 KiB | 5 Q