3v4l.org

run code in 300+ PHP versions simultaneously
<?php class f { function f(&$e, &$u, $f=false) { } } function getNew() { $a = func_get_args(); $c = array_shift($a); var_dump($a); foreach ($a as $k => &$value) $a[$k] = $value; //return call_user_func_array(array('f', 'f'), $c); $r = new ReflectionClass($c); return $r->newInstanceArgs($a); } $e = new stdClass; $u = new stdClass; var_dump(getNew('f', $e, $u));

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.0110.00416.75
8.3.50.0100.00817.32
8.3.40.0070.00718.80
8.3.30.0070.00718.89
8.3.20.0000.00818.77
8.3.10.0090.00618.52
8.3.00.0050.00319.26
8.2.180.0140.00716.75
8.2.170.0040.01122.96
8.2.160.0090.00920.39
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0000.00726.16
8.2.120.0080.00020.61
8.2.110.0030.00720.99
8.2.100.0080.00318.03
8.2.90.0060.00319.42
8.2.80.0020.00519.38
8.2.70.0090.00017.50
8.2.60.0000.00818.16
8.2.50.0030.00618.07
8.2.40.0040.00418.22
8.2.30.0000.00718.03
8.2.20.0040.00417.80
8.2.10.0040.00417.73
8.2.00.0040.00417.88
8.1.280.0100.00325.92
8.1.270.0050.00324.66
8.1.260.0090.00026.35
8.1.250.0040.00428.09
8.1.240.0070.00322.55
8.1.230.0080.00420.96
8.1.220.0000.00817.74
8.1.210.0000.00820.87
8.1.200.0040.00417.23
8.1.190.0000.00717.53
8.1.180.0050.00318.10
8.1.170.0090.00018.90
8.1.160.0070.00018.91
8.1.150.0020.00518.56
8.1.140.0050.00317.48
8.1.130.0000.00717.84
8.1.120.0040.00417.50
8.1.110.0000.00717.36
8.1.100.0000.00717.52
8.1.90.0020.00517.49
8.1.80.0040.00417.36
8.1.70.0030.00317.36
8.1.60.0000.00817.62
8.1.50.0050.00317.47
8.1.40.0000.00817.43
8.1.30.0000.00717.55
8.1.20.0040.00417.63
8.1.10.0000.00917.62
8.1.00.0000.00717.41
8.0.300.0040.00419.89
8.0.290.0000.00816.75
8.0.280.0070.00018.34
8.0.270.0040.00417.16
8.0.260.0070.00016.95
8.0.250.0000.00717.02
8.0.240.0040.00416.93
8.0.230.0030.00317.05
8.0.220.0030.00316.99
8.0.210.0070.00017.00
8.0.200.0060.00017.09
8.0.190.0000.00717.09
8.0.180.0040.00417.00
8.0.170.0090.00016.86
8.0.160.0030.00317.00
8.0.150.0030.00616.85
8.0.140.0080.00016.98
8.0.130.0030.00313.41
8.0.120.0050.00316.85
8.0.110.0040.00416.86
8.0.100.0040.00416.92
8.0.90.0070.00016.95
8.0.80.0070.00816.97
8.0.70.0070.00016.93
8.0.60.0000.00716.84
8.0.50.0040.00416.93
8.0.30.0100.01017.23
8.0.20.0170.02517.04
8.0.10.0040.00417.06
8.0.00.0090.01116.82
7.4.330.0050.00013.01
7.4.320.0000.00616.60
7.4.300.0030.00316.60
7.4.290.0000.00716.66
7.4.280.0030.00516.54
7.4.270.0000.00716.57
7.4.260.0030.00313.15
7.4.250.0040.00416.49
7.4.240.0040.00416.59
7.4.230.0030.00516.61
7.4.220.0150.00916.50
7.4.210.0100.00616.60
7.4.200.0030.00516.71
7.4.190.0000.00816.76
7.4.160.0030.01316.55
7.4.150.0160.00316.52
7.4.140.0100.00816.51
7.4.130.0130.00416.66
7.4.120.0110.00616.53
7.4.110.0090.00916.58
7.4.100.0140.00716.44
7.4.90.0100.01316.59
7.4.80.0060.01119.39
7.4.70.0110.00716.48
7.4.60.0060.01016.50
7.4.50.0070.00516.54
7.4.40.0000.01516.45
7.4.30.0060.01316.34
7.4.00.0070.01015.10
7.3.330.0000.00713.45
7.3.320.0000.00613.28
7.3.310.0030.00316.34
7.3.300.0070.00016.36
7.3.290.0130.00316.46
7.3.280.0100.00916.45
7.3.270.0150.00416.53
7.3.260.0070.01016.39
7.3.250.0140.00516.50
7.3.240.0130.00416.54
7.3.230.0100.00616.63
7.3.210.0080.00816.44
7.3.200.0030.01416.41
7.3.190.0130.01016.50
7.3.180.0130.00316.52
7.3.170.0160.00016.55
7.3.160.0070.01516.64
7.3.120.0090.00914.78
7.3.10.0080.00816.75
7.3.00.0030.01016.89
7.2.330.0030.01916.74
7.2.320.0080.01516.78
7.2.310.0070.01416.57
7.2.300.0080.00816.75
7.2.290.0070.00716.74
7.2.130.0110.00316.79
7.2.120.0120.00016.61
7.2.110.0130.00016.98
7.2.100.0070.00716.88
7.2.90.0080.00416.96
7.2.80.0110.00416.66
7.2.70.0040.00816.92
7.2.60.0040.00716.84
7.2.50.0040.00817.00
7.2.40.0040.01116.95
7.2.30.0060.01017.04
7.2.20.0030.00916.96
7.2.10.0030.00716.99
7.2.00.0050.00917.92
7.1.250.0000.01215.73
7.1.200.0000.01415.88
7.1.100.0080.00818.14
7.1.70.0000.01717.01
7.1.60.0190.00619.40
7.1.50.0040.01216.89
7.1.00.0000.07722.34
7.0.200.0250.01414.63
7.0.140.0000.07321.91
7.0.120.0030.07322.18
7.0.60.0030.04019.94
7.0.50.0070.08317.89
7.0.40.0070.08720.11
7.0.30.0330.06720.27
7.0.20.0370.04720.09
7.0.10.0200.09020.15
7.0.00.0100.05020.33
5.6.280.0000.10021.00
5.6.210.0170.05720.65
5.6.200.0070.06718.19
5.6.190.0070.09020.55
5.6.180.0300.08320.36
5.6.170.0270.05720.54
5.6.160.0070.03720.39
5.6.150.0100.07318.14
5.6.140.0070.07718.15
5.6.130.0170.07718.18
5.6.120.0030.04020.98
5.6.110.0130.07321.20
5.6.100.0130.07721.05
5.6.90.0100.08721.14
5.6.80.0070.05020.40
5.6.70.0200.08320.37
5.5.350.0400.06720.44
5.5.340.0100.07318.07
5.5.330.0030.05720.35
5.5.320.0200.04020.41
5.5.310.0330.07320.28
5.5.300.0030.05017.98
5.5.290.0030.04017.99
5.5.280.0100.08320.65
5.5.270.0030.07720.87
5.5.260.0130.06320.79
5.5.250.0070.03720.77
5.5.240.0130.07320.37
5.4.450.0170.07719.57
5.4.440.0100.06719.57
5.4.430.0000.04719.20
5.4.420.0100.05019.18
5.4.410.0070.03719.14
5.4.400.0070.07019.16
5.4.390.0100.07318.98
5.4.380.0170.06719.25
5.4.370.0170.03719.25
5.4.360.0030.05018.85
5.4.350.0130.07019.18
5.4.340.0030.05319.14
5.4.320.0100.06718.86
5.4.310.0100.04319.20
5.4.300.0100.04718.99
5.4.290.0130.06318.84
5.4.280.0030.08318.87
5.4.270.0030.08019.14
5.4.260.0130.06719.00
5.4.250.0030.06019.15
5.4.240.0130.07319.13
5.4.230.0100.04018.95
5.4.220.0070.08019.14
5.4.210.0030.08018.84
5.4.200.0030.08719.15
5.4.190.0030.07719.14
5.4.180.0100.04719.25
5.4.170.0070.04719.15
5.4.160.0100.07019.20
5.4.150.0170.06719.08
5.4.140.0000.05316.61
5.4.130.0030.04016.39
5.4.120.0130.06316.45
5.4.110.0070.04016.44
5.4.100.0030.07016.33
5.4.90.0100.07316.52
5.4.80.0030.07316.49
5.4.70.0100.07316.51
5.4.60.0000.07716.42
5.4.50.0030.05016.34
5.4.40.0070.06316.36
5.4.30.0130.05716.46
5.4.20.0070.03316.27
5.4.10.0100.03016.46
5.4.00.0030.03715.84
5.3.290.0000.06714.70
5.3.280.0070.07014.76
5.3.270.0030.06314.69
5.3.260.0100.06314.62
5.3.250.0070.07314.50
5.3.240.0030.04014.63
5.3.230.0100.03314.63
5.3.220.0070.06314.73
5.3.210.0070.08014.63
5.3.200.0000.07014.73
5.3.190.0070.07714.61
5.3.180.0030.08014.59
5.3.170.0100.07014.49
5.3.160.0000.05314.61
5.3.150.0100.06314.57
5.3.140.0070.06014.47
5.3.130.0100.08014.56
5.3.120.0030.08014.59
5.3.110.0070.03714.61
5.3.100.0070.04014.09
5.3.90.0030.03714.03
5.3.80.0000.04014.07
5.3.70.0130.03314.06
5.3.60.0000.04014.09
5.3.50.0070.03314.11
5.3.40.0030.03713.97
5.3.30.0100.02713.93
5.3.20.0000.03713.70
5.3.10.0000.03713.55
5.3.00.0000.04313.70
5.2.170.0000.03011.31
5.2.160.0000.03011.30
5.2.150.0070.02711.15
5.2.140.0000.03011.31
5.2.130.0000.03011.08
5.2.120.0000.03011.12
5.2.110.0030.02711.15
5.2.100.0000.03011.11
5.2.90.0030.02711.13
5.2.80.0000.03011.11
5.2.70.0000.03011.07
5.2.60.0030.02711.02
5.2.50.0000.03011.11
5.2.40.0000.03010.95
5.2.30.0000.03011.05
5.2.20.0000.03011.11
5.2.10.0030.02710.82
5.2.00.0000.03010.78
5.1.60.0070.0209.96
5.1.50.0030.02310.05
5.1.40.0000.02710.00
5.1.30.0000.02710.38
5.1.20.0030.03010.43
5.1.10.0030.02310.23
5.1.00.0030.02310.14
5.0.50.0000.0208.61
5.0.40.0000.0208.48
5.0.30.0000.0308.20
5.0.20.0000.0208.12
5.0.10.0000.0208.11
5.0.00.0030.0278.08
4.4.90.0000.0178.03
4.4.80.0000.0178.03
4.4.70.0000.0178.03
4.4.60.0000.0178.03
4.4.50.0000.0178.03
4.4.40.0000.0278.03
4.4.30.0030.0138.03
4.4.20.0000.0178.03
4.4.10.0000.0178.03
4.4.00.0000.0238.03
4.3.110.0000.0138.03
4.3.100.0000.0138.03
4.3.90.0000.0138.03
4.3.80.0030.0208.03
4.3.70.0000.0138.03
4.3.60.0000.0178.03
4.3.50.0000.0138.03
4.3.40.0000.0278.03
4.3.30.0000.0178.03
4.3.20.0000.0208.03
4.3.10.0000.0178.03
4.3.00.0000.0138.03

preferences:
61.43 ms | 401 KiB | 5 Q