3v4l.org

run code in 300+ PHP versions simultaneously
<?php function returnVariable(){ $foo = 1; try{ return &$foo; } finally { $foo++; debug_zval_dump($foo); } } function returnVariablePlusZero(){ $foo = 1; try{ return $foo + 0; } finally { $foo++; } } var_dump(returnVariable(), returnVariablePlusZero());

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)
5.4.350.0130.05019.06
5.4.340.0230.08012.03
5.4.320.0120.04912.52
5.4.310.0090.05512.52
5.4.300.0050.04512.52
5.4.290.0220.09412.52
5.4.280.0050.05112.41
5.4.270.0100.05712.41
5.4.260.0130.06312.41
5.4.250.0110.04612.41
5.4.240.0230.07512.41
5.4.230.0150.07812.40
5.4.220.0120.06412.40
5.4.210.0080.03912.40
5.4.200.0150.05312.40
5.4.190.0100.09212.40
5.4.180.0070.05012.40
5.4.170.0090.04512.40
5.4.160.0070.04812.40
5.4.150.0070.05712.40
5.4.140.0100.05612.09
5.4.130.0120.05312.07
5.4.120.0200.10312.04
5.4.110.0110.05412.03
5.4.100.0110.05912.04
5.4.90.0080.03912.03
5.4.80.0100.04312.03
5.4.70.0100.05212.03
5.4.60.0100.04212.02
5.4.50.0110.04312.03
5.4.40.0120.04012.01
5.4.30.0110.03512.02
5.4.20.0080.05012.00
5.4.10.0060.04112.01
5.4.00.0090.05811.50
5.3.290.0120.05212.80
5.3.280.0200.06612.71
5.3.270.0090.06812.72
5.3.260.0150.06512.71
5.3.250.0070.04212.71
5.3.240.0150.05712.72
5.3.230.0180.06312.71
5.3.220.0080.05612.68
5.3.210.0110.04412.68
5.3.200.0070.04512.68
5.3.190.0070.04412.68
5.3.180.0070.04712.68
5.3.170.0120.04912.67
5.3.160.0140.04412.67
5.3.150.0190.08112.67
5.3.140.0110.04312.66
5.3.130.0090.04612.65
5.3.120.0130.03812.66
5.3.110.0240.11212.66
5.3.100.0210.11412.12
5.3.90.0270.06812.11
5.3.80.0100.07912.09
5.3.70.0200.07212.09
5.3.60.0050.03912.08
5.3.50.0080.03812.02
5.3.40.0100.04012.02
5.3.30.0050.03711.98
5.3.20.0030.03911.77
5.3.10.0060.03611.74
5.3.00.0090.03911.72
5.2.170.0170.0739.21
5.2.160.0100.0539.21
5.2.150.0070.0419.21
5.2.140.0070.0419.21
5.2.130.0100.0349.18
5.2.120.0060.0379.18
5.2.110.0090.0359.18
5.2.100.0030.0439.18
5.2.90.0110.0369.19
5.2.80.0070.0419.17
5.2.70.0080.0399.17
5.2.60.0080.0409.13
5.2.50.0070.0409.09
5.2.40.0070.0369.07
5.2.30.0090.0419.05
5.2.20.0100.0439.04
5.2.10.0100.0418.95
5.2.00.0040.0388.80
5.1.60.0080.0248.09
5.1.50.0090.0308.08
5.1.40.0060.0268.07
5.1.30.0040.0318.42
5.1.20.0040.0308.44
5.1.10.0050.0308.16
5.1.00.0060.0318.16
5.0.50.0120.0276.64
5.0.40.0040.0246.50
5.0.30.0020.0346.31
5.0.20.0060.0216.29
5.0.10.0020.0266.25
5.0.00.0050.0316.24
4.4.90.0040.0164.78
4.4.80.0040.0164.76
4.4.70.0120.0284.75
4.4.60.0040.0214.76
4.4.50.0040.0184.77
4.4.40.0020.0374.71
4.4.30.0020.0204.76
4.4.20.0040.0164.85
4.4.10.0000.0234.85
4.4.00.0050.0294.76
4.3.110.0070.0214.67
4.3.100.0040.0184.66
4.3.90.0060.0144.63
4.3.80.0020.0294.58
4.3.70.0130.0304.63
4.3.60.0070.0254.63
4.3.50.0050.0204.63
4.3.40.0120.0754.54
4.3.30.0070.0153.30
4.3.20.0050.0163.27
4.3.10.0090.0213.24
4.3.00.0030.0236.86

preferences:
143.91 ms | 1394 KiB | 7 Q