3v4l.org

run code in 300+ PHP versions simultaneously
<?php phpversion() >= "7.0.0" or die(); class FooBar { private $x; public function __construct() { var_dump($this); echo "Let's remove a property!", PHP_EOL; unset($this->x); var_dump($this); echo "Let's add a property!", PHP_EOL; $this->x = 2; var_dump($this); echo "Where did the private come from?", PHP_EOL; } } $foobar = new Foobar;

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)
7.3.10.0050.00516.56
7.3.00.0080.00316.59
7.2.130.0000.00916.80
7.2.120.0050.00816.90
7.2.110.0050.00816.89
7.2.100.0040.00716.92
7.2.90.0090.00516.91
7.2.80.0050.00716.91
7.2.70.0030.00716.98
7.2.60.0070.00517.09
7.2.50.0050.00816.98
7.2.40.0030.00817.07
7.2.30.0050.00816.78
7.2.20.0030.00716.80
7.2.10.0050.00716.94
7.2.00.0030.00916.88
7.1.250.0050.00515.70
7.1.70.0000.01017.22
7.1.60.0070.00316.90
7.1.50.0110.01416.80
7.1.00.0100.06322.28
7.0.200.0030.01316.53
7.0.70.0100.07719.86
7.0.60.0100.08019.93
7.0.50.0130.08720.36
7.0.40.0070.07320.18
7.0.30.0030.08320.04
7.0.20.0130.08020.09
7.0.10.0100.07720.07
7.0.00.0000.09720.12
5.6.280.0100.06721.09
5.6.220.0130.06020.49
5.6.210.0030.08320.64
5.6.200.0130.08020.97
5.6.190.0030.06021.02
5.6.180.0200.07321.04
5.6.170.0130.07021.05
5.6.160.0100.08720.96
5.6.150.0100.08021.09
5.6.140.0070.08021.09
5.6.130.0100.08321.04
5.6.120.0170.08021.17
5.6.110.0130.03721.07
5.6.100.0130.08021.15
5.6.90.0030.06021.15
5.6.80.0130.06720.32
5.6.70.0100.06320.32
5.6.60.0030.08320.43
5.6.50.0230.06320.41
5.6.40.0100.06020.31
5.6.30.0130.05020.42
5.6.20.0070.06020.50
5.6.10.0030.06720.30
5.6.00.0000.06320.36
5.5.360.0070.05320.41
5.5.350.0070.06020.40
5.5.340.0070.08320.82
5.5.330.0170.08020.76
5.5.320.0130.08020.78
5.5.310.0030.07020.88
5.5.300.0000.05020.87
5.5.290.0070.09720.90
5.5.280.0100.08020.82
5.5.270.0070.05720.90
5.5.260.0000.04720.83
5.5.250.0030.06020.59
5.5.240.0170.06720.22
5.5.230.0070.08320.21
5.5.220.0100.07020.26
5.5.210.0230.06020.20
5.5.200.0030.05720.22
5.5.190.0030.08320.08
5.5.180.0070.07320.11
5.5.160.0100.07720.21
5.5.150.0130.07720.26
5.5.140.0130.07720.17
5.5.130.0100.07720.26
5.5.120.0000.04720.11
5.5.110.0070.07720.18
5.5.100.0070.06320.14
5.5.90.0170.07020.16
5.5.80.0170.06719.97
5.5.70.0070.05719.94
5.5.60.0030.05720.11
5.5.50.0070.05720.09
5.5.40.0130.08020.14
5.5.30.0000.08020.05
5.5.20.0030.07320.13
5.5.10.0130.08020.05
5.5.00.0100.07720.02
5.4.450.0130.04719.56
5.4.440.0100.07319.55
5.4.430.0000.04719.48
5.4.420.0070.05019.41
5.4.410.0100.06719.43
5.4.400.0100.05019.14
5.4.390.0070.07719.13
5.4.380.0100.05318.85
5.4.370.0030.08719.03
5.4.360.0070.08019.23
5.4.350.0030.08019.05
5.4.340.0100.07319.21
5.4.320.0130.05718.91
5.4.310.0100.07019.12
5.4.300.0070.07319.12
5.4.290.0100.07719.04
5.4.280.0070.05719.04
5.4.270.0030.04319.05
5.4.260.0100.07319.04
5.4.250.0100.06719.04
5.4.240.0100.07319.21
5.4.230.0100.06319.15
5.4.220.0200.06318.87
5.4.210.0030.06319.15
5.4.200.0030.08019.12
5.4.190.0100.06719.20
5.4.180.0130.05018.89
5.4.170.0070.08018.94
5.4.160.0000.07018.93
5.4.150.0070.07719.02
5.4.140.0130.07016.33
5.4.130.0030.07716.24
5.4.120.0130.07016.49
5.4.110.0070.05316.35
5.4.100.0000.06716.36
5.4.90.0130.06716.29
5.4.80.0030.07316.48
5.4.70.0000.08016.30
5.4.60.0130.06316.44
5.4.50.0070.07316.25
5.4.40.0130.06016.46
5.4.30.0030.04316.31
5.4.20.0100.06716.47
5.4.10.0030.07016.47
5.4.00.0130.06315.90
5.3.290.0070.07714.77
5.3.280.0130.04714.64
5.3.270.0130.04014.60
5.3.260.0130.07014.62
5.3.250.0070.08014.73
5.3.240.0030.08314.57
5.3.230.0100.06314.73
5.3.220.0070.08014.52
5.3.210.0130.07314.50
5.3.200.0200.05014.54
5.3.190.0130.06714.67
5.3.180.0000.07714.59
5.3.170.0230.06014.65
5.3.160.0070.08014.58
5.3.150.0070.07314.62
5.3.140.0070.07314.67
5.3.130.0000.04314.61
5.3.120.0030.08014.51
5.3.110.0130.05714.61
5.3.100.0000.08313.93
5.3.90.0070.07314.03
5.3.80.0070.07714.08
5.3.70.0130.06713.91
5.3.60.0070.07314.09
5.3.50.0070.07714.04
5.3.40.0100.07013.83
5.3.30.0070.06713.83
5.3.20.0130.06013.69
5.3.10.0030.07013.64
5.3.00.0070.07313.69
5.2.170.0030.07012.24
5.2.160.0030.05712.24
5.2.150.0030.06712.24
5.2.140.0000.06012.24
5.2.130.0130.05012.24
5.2.120.0070.04712.24
5.2.110.0100.05712.24
5.2.100.0000.06712.24
5.2.90.0070.05312.24
5.2.80.0030.06312.24
5.2.70.0070.06712.24
5.2.60.0230.04712.24
5.2.50.0000.05012.24
5.2.40.0000.04712.24
5.2.30.0030.06712.24
5.2.20.0100.06012.24
5.2.10.0030.04712.24
5.2.00.0030.03712.24
5.1.60.0030.05712.24
5.1.50.0030.05712.24
5.1.40.0070.03312.24
5.1.30.0030.05712.24
5.1.20.0030.06012.24
5.1.10.0070.04712.24
5.1.00.0030.04312.24
5.0.50.0030.04712.24
5.0.40.0000.03312.24
5.0.30.0000.04312.24
5.0.20.0030.04712.24
5.0.10.0000.04312.24
5.0.00.0070.05312.24
4.4.90.0030.02712.24
4.4.80.0000.03712.24
4.4.70.0030.03312.24
4.4.60.0000.03712.24
4.4.50.0000.03312.24
4.4.40.0000.06012.24
4.4.30.0030.03012.24
4.4.20.0030.03712.24
4.4.10.0030.01712.24
4.4.00.0000.04712.24
4.3.110.0000.02312.24
4.3.100.0070.01712.24
4.3.90.0030.03312.24
4.3.80.0000.05312.24
4.3.70.0000.03712.24
4.3.60.0030.03312.24
4.3.50.0030.03312.24
4.3.40.0070.04712.24
4.3.30.0070.03312.24
4.3.20.0000.04012.24
4.3.10.0030.03312.24
4.3.00.0070.03012.24

preferences:
46.66 ms | 400 KiB | 5 Q