3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Testme { public static function foo(&$ref) { $ref = 1; } } class Invoker { public static function invoke($func_name) { $trace = debug_backtrace(); $args = $trace[1]['args']; call_user_func_array(array('Testme', $func_name), $args); } } $test = 2; $testRef = &$test; Invoker::invoke('foo', $testRef); var_dump($test);

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.0090.00616.50
8.3.50.0200.01022.04
8.3.40.0040.01118.71
8.3.30.0070.00719.09
8.3.20.0040.00420.30
8.3.10.0080.00023.66
8.3.00.0080.00820.82
8.2.180.0120.00318.29
8.2.170.0150.00022.96
8.2.160.0060.00920.52
8.2.150.0000.00824.18
8.2.140.0040.00424.66
8.2.130.0100.00326.16
8.2.120.0040.00422.05
8.2.110.0030.00622.15
8.2.100.0070.00417.72
8.2.90.0030.00619.22
8.2.80.0050.00317.97
8.2.70.0000.00817.63
8.2.60.0050.00318.05
8.2.50.0040.00418.07
8.2.40.0000.00818.28
8.2.30.0040.00418.10
8.2.20.0000.00817.73
8.2.10.0050.00317.80
8.2.00.0030.00517.74
8.1.280.0110.00425.92
8.1.270.0080.00022.19
8.1.260.0040.00426.35
8.1.250.0000.00828.09
8.1.240.0100.00623.83
8.1.230.0060.00618.99
8.1.220.0040.00417.74
8.1.210.0030.00518.77
8.1.200.0030.00617.35
8.1.190.0040.00417.29
8.1.180.0030.00618.10
8.1.170.0030.00618.71
8.1.160.0040.00422.00
8.1.150.0000.00718.64
8.1.140.0000.00817.45
8.1.130.0000.00717.82
8.1.120.0030.00317.39
8.1.110.0070.00017.45
8.1.100.0000.00717.38
8.1.90.0040.00417.39
8.1.80.0040.00417.38
8.1.70.0030.00317.42
8.1.60.0000.00917.53
8.1.50.0000.00717.39
8.1.40.0000.00817.53
8.1.30.0040.00417.57
8.1.20.0040.00417.48
8.1.10.0050.00217.46
8.1.00.0080.00417.52
8.0.300.0000.00718.77
8.0.290.0040.00417.18
8.0.280.0000.00718.31
8.0.270.0000.00717.09
8.0.260.0000.00616.88
8.0.250.0000.00717.03
8.0.240.0000.00716.89
8.0.230.0040.00416.93
8.0.220.0030.00316.90
8.0.210.0000.00716.95
8.0.200.0000.00617.01
8.0.190.0030.00417.02
8.0.180.0030.00516.88
8.0.170.0000.00816.96
8.0.160.0080.00016.98
8.0.150.0040.00416.93
8.0.140.0030.00516.93
8.0.130.0030.00313.38
8.0.120.0040.00416.96
8.0.110.0040.00416.94
8.0.100.0040.00416.82
8.0.90.0000.00716.79
8.0.80.0100.00616.92
8.0.70.0070.00016.90
8.0.60.0090.00016.75
8.0.50.0050.00316.98
8.0.30.0160.00617.20
8.0.20.0070.01217.42
8.0.10.0000.00716.87
8.0.00.0110.00616.80
7.4.330.0000.00615.00
7.4.320.0000.00616.62
7.4.300.0000.00616.52
7.4.290.0000.00716.56
7.4.280.0030.00316.35
7.4.270.0000.00616.52
7.4.260.0000.00816.50
7.4.250.0080.00016.54
7.4.240.0050.00216.60
7.4.230.0060.00316.37
7.4.220.0090.00916.68
7.4.210.0070.00916.60
7.4.200.0080.00016.61
7.4.190.0050.00216.40
7.4.160.0090.00616.56
7.4.150.0030.01417.40
7.4.140.0040.01317.86
7.4.130.0100.00616.69
7.4.120.0130.00416.63
7.4.110.0190.00016.64
7.4.100.0100.01016.47
7.4.90.0190.00716.41
7.4.80.0090.00919.39
7.4.70.0110.00516.50
7.4.60.0100.00716.68
7.4.50.0040.00416.39
7.4.40.0060.01322.77
7.4.30.0060.00916.46
7.4.00.0090.00614.52
7.3.330.0000.00513.45
7.3.320.0000.00613.27
7.3.310.0040.00416.24
7.3.300.0040.00416.34
7.3.290.0090.00916.41
7.3.280.0120.00516.43
7.3.270.0060.01017.40
7.3.260.0130.01016.31
7.3.250.0080.01016.43
7.3.240.0100.00716.43
7.3.230.0060.01216.45
7.3.210.0070.01016.39
7.3.200.0040.01319.39
7.3.190.0000.01716.50
7.3.180.0040.01216.37
7.3.170.0130.00316.41
7.3.160.0080.00816.49
7.3.120.0090.00614.87
7.2.330.0080.00816.73
7.2.320.0000.01816.46
7.2.310.0000.01716.53
7.2.300.0080.01216.35
7.2.290.0090.00616.52
7.1.100.0070.00718.20
7.1.70.0000.00717.24
7.1.60.0100.01419.29
7.1.50.0070.01816.96
7.1.00.0100.07022.44
7.0.200.0090.00616.74
7.0.140.0100.06721.96
7.0.60.0070.06019.93
7.0.50.0030.06317.96
7.0.40.0070.09020.20
7.0.30.0230.07720.19
7.0.20.0330.08320.10
7.0.10.0070.07320.07
7.0.00.0130.08020.12
5.6.280.0070.07321.05
5.6.210.0030.06020.52
5.6.200.0070.08318.16
5.6.190.0130.07720.53
5.6.180.0330.04720.66
5.6.170.0130.05720.54
5.6.160.0130.05320.55
5.6.150.0030.07318.12
5.6.140.0070.07718.14
5.6.130.0030.05318.18
5.6.120.0100.03721.15
5.6.110.0100.05720.89
5.6.100.0030.09020.98
5.6.90.0030.07321.08
5.6.80.0170.08020.44
5.5.350.4300.03020.39
5.5.340.0000.04017.98
5.5.330.0100.07320.43
5.5.320.0300.07720.51
5.5.310.0300.07320.34
5.5.300.0100.08017.92
5.5.290.0070.04717.94
5.5.280.0030.08720.88
5.5.270.0000.07320.96
5.5.260.0100.06320.76
5.5.250.0130.05320.59
5.5.240.0030.07320.29
5.4.450.1270.03719.55
5.4.440.0170.05319.57
5.4.430.0230.04319.32
5.4.420.0170.05319.51
5.4.410.0300.04019.42
5.4.400.0230.04318.97
5.4.390.0100.06019.12
5.4.380.0400.04318.81
5.4.370.0400.05318.75
5.4.360.0230.04718.85
5.4.350.0270.06318.59
5.4.340.0270.05718.47
5.4.320.0070.03612.50
5.4.310.0070.04012.50
5.4.300.0080.04012.50
5.4.290.0070.04112.50
5.4.280.0070.04912.39
5.4.270.0050.04412.39
5.4.260.0050.04012.39
5.4.250.0020.04112.39
5.4.240.0050.03812.39
5.4.230.0050.04012.39
5.4.220.0010.05112.38
5.4.210.0050.03612.38
5.4.200.0060.03712.39
5.4.190.0090.03312.38
5.4.180.0040.04012.39
5.4.170.0190.05112.38
5.4.160.0120.04612.36
5.4.150.0160.04312.36
5.4.140.0090.05112.05
5.4.130.0130.04712.04
5.4.120.0240.06511.99
5.4.110.0140.04211.99
5.4.100.0140.04311.98
5.4.90.0150.04211.99
5.4.80.0170.04111.99
5.4.70.0150.04111.98
5.4.60.0140.04311.99
5.4.50.0180.03911.99
5.4.40.0170.04011.97
5.4.30.0160.04411.97
5.4.20.0140.04311.96
5.4.10.0130.04311.97
5.4.00.0110.04511.46
5.3.290.0060.04312.80
5.3.280.0070.03612.71
5.3.270.0130.04812.73
5.3.260.0150.04412.72
5.3.250.0160.04412.72
5.3.240.0180.04312.72
5.3.230.0250.09812.71
5.3.220.0140.04712.68
5.3.210.0160.04412.68
5.3.200.0190.04512.68
5.3.190.0190.04512.68
5.3.180.0170.04412.67
5.3.170.0140.04712.67
5.3.160.0150.04512.68
5.3.150.0150.07412.68
5.3.140.0170.04212.66
5.3.130.0160.04712.66
5.3.120.0180.04212.66
5.3.110.0150.04612.66
5.3.100.0200.04512.12
5.3.90.0260.06412.10
5.3.80.0200.04012.09
5.3.70.0210.04412.09
5.3.60.0200.04212.07
5.3.50.0160.04712.02
5.3.40.0200.04312.02
5.3.30.0200.04011.99
5.3.20.0180.04211.77
5.3.10.0210.06911.73
5.3.00.0200.04911.71
5.2.170.0470.0979.22
5.2.160.0150.0419.22
5.2.150.0180.0339.22
5.2.140.0110.0389.22
5.2.130.0270.0809.18
5.2.120.0120.0349.18
5.2.110.0130.0369.19
5.2.100.0130.0349.18
5.2.90.0160.0339.18
5.2.80.0160.0379.17
5.2.70.0210.0389.17
5.2.60.0120.0409.13
5.2.50.0100.0409.10
5.2.40.0190.0359.08
5.2.30.0180.0429.05
5.2.20.0110.0409.05
5.2.10.0240.0608.95
5.2.00.0130.0348.80
5.1.60.0120.0298.09
5.1.50.0120.0318.09
5.1.40.0110.0308.07
5.1.30.0140.0318.42
5.1.20.0120.0388.45
5.1.10.0110.0328.17
5.1.00.0120.0348.16
5.0.50.0140.0316.64
5.0.40.0140.0296.50
5.0.30.0090.0356.32
5.0.20.0080.0236.28
5.0.10.0100.0226.26
5.0.00.0120.0336.25
4.4.90.0060.0214.78
4.4.80.0120.0194.76
4.4.70.0090.0184.75
4.4.60.0100.0234.75
4.4.50.0200.0384.77
4.4.40.0070.0304.71
4.4.30.0080.0184.76
4.4.20.0050.0234.84
4.4.10.0080.0194.85
4.4.00.0060.0304.76
4.3.110.0100.0174.67
4.3.100.0060.0194.66
4.3.90.0060.0194.64
4.3.80.0050.0314.59
4.3.70.0320.0554.63
4.3.60.0090.0204.62
4.3.50.0080.0164.63
4.3.40.0100.0244.54
4.3.30.0050.0213.30
4.3.20.0050.0183.30
4.3.10.0070.0163.26
4.3.00.0300.01015.63

preferences:
43.21 ms | 401 KiB | 5 Q