3v4l.org

run code in 300+ PHP versions simultaneously
<?php function foo(&$obj) { return $obj; } $o = new StdClass; // No errors foo($o); call_user_func('foo', $o); call_user_func('foo', [$o]); $a[] = $o; $a[] = $o; $a[] = $o; // Warning: Parameter 1 to foo() expected to be a reference, value given in call_user_func('foo', array_slice($a, 0, 1));

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.90.0070.00026.77
8.3.80.0030.00618.43
8.3.70.0110.00416.73
8.3.60.0100.01016.75
8.3.50.0110.01121.27
8.3.40.0030.01318.83
8.3.30.0170.00318.79
8.3.20.0070.00021.86
8.3.10.0040.00420.65
8.3.00.0040.00423.57
8.2.210.0000.00826.77
8.2.200.0030.00618.54
8.2.190.0060.01216.75
8.2.180.0120.00325.92
8.2.170.0110.00419.13
8.2.160.0140.00022.96
8.2.150.0070.00025.66
8.2.140.0050.00224.66
8.2.130.0080.00026.16
8.2.120.0060.00819.96
8.2.110.0060.00322.16
8.2.100.0110.00018.04
8.2.90.0120.00017.84
8.2.80.0030.00617.97
8.2.70.0100.00017.63
8.2.60.0050.00317.63
8.2.50.0000.00817.75
8.2.40.0040.00419.60
8.2.30.0000.00719.32
8.2.20.0040.00418.00
8.2.10.0000.00818.11
8.2.00.0030.00617.81
8.1.290.0040.00718.88
8.1.280.0170.00325.92
8.1.270.0120.00022.10
8.1.260.0050.00326.35
8.1.250.0070.00028.09
8.1.240.0060.00322.14
8.1.230.0040.00722.73
8.1.220.0000.00817.74
8.1.210.0040.00418.77
8.1.200.0030.00617.35
8.1.190.0040.00417.22
8.1.180.0000.01118.10
8.1.170.0000.00719.01
8.1.160.0070.00022.18
8.1.150.0040.00418.81
8.1.140.0030.00619.71
8.1.130.0030.00317.71
8.1.120.0000.00717.49
8.1.110.0060.00317.36
8.1.100.0000.00717.50
8.1.90.0040.00417.49
8.1.80.0000.00817.35
8.1.70.0000.00717.45
8.1.60.0040.00417.47
8.1.50.0030.00517.54
8.1.40.0020.00517.48
8.1.30.0000.00917.59
8.1.20.0080.00017.61
8.1.10.0030.00617.59
8.1.00.0050.00317.58
8.0.300.0000.00721.94
8.0.290.0000.00816.75
8.0.280.0030.00318.48
8.0.270.0000.00716.89
8.0.260.0030.00317.38
8.0.250.0070.00017.06
8.0.240.0060.00017.06
8.0.230.0030.00616.99
8.0.220.0070.00017.01
8.0.210.0070.00017.00
8.0.200.0060.00017.00
8.0.190.0050.00317.00
8.0.180.0040.00417.04
8.0.170.0040.00416.96
8.0.160.0060.00316.95
8.0.150.0020.00516.91
8.0.140.0030.00316.90
8.0.130.0000.00613.33
8.0.120.0040.00416.94
8.0.110.0040.00416.98
8.0.100.0050.00317.05
8.0.90.0070.00016.95
8.0.80.0040.01116.95
8.0.70.0040.00516.91
8.0.60.0040.00416.91
8.0.50.0000.00716.93
8.0.30.0120.00717.33
8.0.20.0110.00917.40
8.0.10.0070.00017.06
8.0.00.0070.01116.84
7.4.330.0050.00015.08
7.4.320.0050.00216.61
7.4.300.0030.00316.52
7.4.290.0060.00016.40
7.4.280.0030.00716.50
7.4.270.0000.00616.50
7.4.260.0040.00416.35
7.4.250.0030.00316.55
7.4.240.0010.00616.56
7.4.230.0040.00416.63
7.4.220.0070.01316.52
7.4.210.0050.00816.53
7.4.200.0040.00416.61
7.4.160.0050.01116.41
7.4.150.0100.00717.40
7.4.140.0130.00417.86
7.4.130.0080.00916.50
7.4.120.0100.00816.51
7.4.110.0060.01016.60
7.4.100.0210.00316.46
7.4.90.0090.00916.59
7.4.80.0100.00719.39
7.4.70.0110.01116.56
7.4.60.0060.00916.48
7.4.50.0000.00916.41
7.4.40.0080.00816.55
7.4.30.0060.01216.66
7.4.00.0040.00714.97
7.3.330.0000.00513.43
7.3.320.0000.00513.22
7.3.310.0030.00316.21
7.3.300.0030.00316.41
7.3.290.0070.00716.33
7.3.280.0080.01016.35
7.3.270.0110.00617.40
7.3.260.0130.00516.64
7.3.250.0090.01016.36
7.3.240.0050.01216.48
7.3.230.0060.01116.55
7.3.210.0110.00516.43
7.3.200.0120.00916.46
7.3.190.0160.00016.61
7.3.180.0070.01116.42
7.3.170.0110.00916.41
7.3.160.0120.00816.30
7.3.10.0090.00516.41
7.3.00.0040.01116.75
7.2.330.0080.00916.39
7.2.320.0070.01016.38
7.2.310.0090.00916.52
7.2.300.0090.00916.80
7.2.290.0130.00316.45
7.2.130.0060.00917.01
7.2.120.0060.01216.94
7.2.110.0030.01316.94
7.2.100.0000.01216.75
7.2.90.0030.00716.83
7.2.80.0030.00716.83
7.2.70.0070.00716.93
7.2.60.0090.00716.80
7.2.50.0000.01416.52
7.2.40.0040.00816.86
7.2.30.0030.00916.90
7.2.20.0130.00316.96
7.2.10.0070.01116.94
7.2.00.0070.00716.88
7.1.250.0100.00315.82
7.1.200.0030.00315.64
7.1.70.0030.00516.98
7.1.60.0060.00617.21
7.1.50.0070.00416.91
7.1.00.0030.07722.44
7.0.200.0310.00314.86
7.0.110.0100.06020.25
7.0.100.0100.05720.24
7.0.90.0030.06720.19
7.0.80.0130.05720.34
7.0.70.0200.06720.40
7.0.60.0100.07720.24
7.0.50.0200.05020.29
7.0.40.0230.06720.26
7.0.30.0130.05720.25
7.0.20.0000.07020.34
7.0.10.0070.06720.24
7.0.00.0100.06320.35
5.6.260.0070.06020.97
5.6.250.0100.06021.05
5.6.240.0100.06020.91
5.6.230.0230.05020.87
5.6.220.0130.05721.00
5.6.210.0100.06020.97
5.6.200.0130.06020.75
5.6.190.0100.05721.07
5.6.180.0070.06021.07
5.6.170.0230.04720.87
5.6.160.0070.06321.02
5.6.150.0030.07020.75
5.6.140.0030.06320.80
5.6.130.0200.06021.04
5.6.120.0100.07021.04
5.6.110.0170.05321.02
5.6.100.0170.07020.84
5.6.90.0200.06320.82
5.6.80.0100.05720.14
5.6.70.0070.05720.42
5.6.60.0030.06320.38
5.6.50.0130.05020.45
5.6.40.0070.06020.11
5.6.30.0100.05320.22
5.6.20.0100.05720.38
5.6.10.0130.05320.19
5.6.00.0200.05020.18

preferences:
29.66 ms | 401 KiB | 5 Q