3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Something { public function action() { return 'Hello, World!'; } } $callable1 = [Something::class, 'action']; $callable2 = 'Something::action'; $callable3 = ['SomethingContainerName', 'action']; var_dump(is_callable($callable1)); var_dump(is_callable($callable2)); var_dump(is_callable($callable3)); function test(callable $callable) { return is_callable($callable); } var_dump(test($callable1)); var_dump(test($callable2)); var_dump(test($callable3));

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.0140.00416.50
8.3.50.0110.00821.11
8.3.40.0090.01218.88
8.3.30.0110.00318.86
8.3.20.0070.00020.16
8.3.10.0000.00823.61
8.3.00.0040.00419.67
8.2.180.0100.01016.50
8.2.170.0110.01122.96
8.2.160.0200.00020.33
8.2.150.0050.00324.18
8.2.140.0110.00424.66
8.2.130.0110.00026.16
8.2.120.0080.00017.63
8.2.110.0100.00021.00
8.2.100.0090.00317.78
8.2.90.0040.00417.50
8.2.80.0000.00918.78
8.2.70.0040.00417.63
8.2.60.0040.00417.63
8.2.50.0060.00317.63
8.2.40.0000.00821.06
8.2.30.0000.00718.06
8.2.20.0040.00417.73
8.2.10.0000.00818.02
8.2.00.0040.00417.99
8.1.280.0090.00625.92
8.1.270.0150.00420.33
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0150.00320.63
8.1.230.0080.00320.88
8.1.220.0000.00817.74
8.1.210.0000.00818.77
8.1.200.0090.00317.34
8.1.190.0040.00417.35
8.1.180.0040.00418.10
8.1.170.0040.00418.97
8.1.160.0050.00218.86
8.1.150.0030.00518.80
8.1.140.0120.00017.43
8.1.130.0030.00317.61
8.1.120.0000.00717.39
8.1.110.0040.00417.43
8.1.100.0000.00817.36
8.1.90.0040.00417.41
8.1.80.0040.00417.40
8.1.70.0040.00417.31
8.1.60.0040.00717.62
8.1.50.0060.00617.43
8.1.40.0000.00717.53
8.1.30.0000.00817.55
8.1.20.0070.00017.55
8.1.10.0040.00417.54
8.1.00.0050.00317.37
8.0.300.0040.00420.09
8.0.290.0050.00316.75
8.0.280.0030.00318.25
8.0.270.0000.00717.15
8.0.260.0040.00417.11
8.0.250.0040.00416.98
8.0.240.0070.00017.01
8.0.230.0000.00716.93
8.0.220.0030.00316.92
8.0.210.0000.00816.89
8.0.200.0040.00416.88
8.0.190.0040.00416.82
8.0.180.0080.00016.80
8.0.170.0030.00616.80
8.0.160.0020.00516.88
8.0.150.0040.00416.88
8.0.140.0030.00716.90
8.0.130.0000.00513.34
8.0.120.0040.00416.77
8.0.110.0050.00216.90
8.0.100.0070.00016.84
8.0.90.0070.00016.90
8.0.80.0060.01016.94
8.0.70.0030.00516.82
8.0.60.0040.00416.79
8.0.50.0050.00216.82
8.0.30.0070.01416.95
8.0.20.0100.00817.40
8.0.10.0000.00717.02
8.0.00.0060.01217.03
7.4.330.0000.00515.08
7.4.320.0000.00716.47
7.4.300.0060.00016.58
7.4.290.0030.00316.57
7.4.280.0000.00716.49
7.4.270.0030.00316.40
7.4.260.0000.00716.57
7.4.250.0080.00016.45
7.4.240.0030.00516.61
7.4.230.0030.00316.52
7.4.220.0100.00716.43
7.4.210.0070.00716.64
7.4.200.0030.00316.40
7.4.160.0120.00616.64
7.4.150.0110.00817.40
7.4.140.0100.01017.86
7.4.130.0120.00616.55
7.4.120.0100.01016.48
7.4.110.0000.01816.35
7.4.100.0170.00316.59
7.4.90.0070.01016.47
7.4.80.0170.00019.39
7.4.70.0150.00616.48
7.4.60.0090.00616.58
7.4.50.0040.00416.51
7.4.40.0150.00816.39
7.4.30.0090.00916.51
7.4.00.0000.01715.18
7.3.330.0000.00713.39
7.3.320.0050.00013.39
7.3.310.0000.00716.22
7.3.300.0060.00016.34
7.3.290.0030.00316.36
7.3.280.0100.00716.30
7.3.270.0120.00617.40
7.3.260.0110.01116.38
7.3.250.0110.00916.45
7.3.240.0160.00316.36
7.3.230.0070.01116.39
7.3.210.0080.00816.19
7.3.200.0140.00316.57
7.3.190.0100.01016.46
7.3.180.0080.00816.51
7.3.170.0130.00416.53
7.3.160.0070.01016.40
7.3.10.0110.00716.33
7.3.00.0150.00416.61
7.2.330.0180.00016.61
7.2.320.0130.00916.68
7.2.310.0120.00616.60
7.2.300.0080.00816.51
7.2.290.0080.00916.62
7.2.130.0060.00816.51
7.2.120.0090.00416.70
7.2.110.0000.01016.46
7.2.100.0070.01016.84
7.2.90.0070.01016.71
7.2.80.0070.01116.64
7.2.70.0090.00616.60
7.2.60.0050.00916.72
7.2.50.0000.01516.74
7.2.40.0120.00616.77
7.2.30.0040.01116.90
7.2.20.0070.00716.79
7.2.10.0000.01216.80
7.2.00.0080.00517.94
7.1.250.0080.00415.61
7.1.200.0030.00615.78
7.1.100.0060.00618.27
7.1.70.0000.01116.84
7.1.60.0180.00720.03
7.1.50.0100.01417.04
7.1.00.0000.08022.40
7.0.200.0040.00416.72
7.0.60.0000.04319.86
7.0.50.0030.04717.88
7.0.40.0100.06320.18
7.0.30.0330.07720.06
7.0.20.0300.06020.24
7.0.10.0000.09320.25
7.0.00.0130.08320.20
5.6.280.0000.07321.12
5.6.210.0100.07720.71
5.6.200.0030.06318.29
5.6.190.0070.08320.41
5.6.180.0370.04320.42
5.6.170.0270.06320.40
5.6.160.0070.08320.43
5.6.150.0070.08018.23
5.6.140.0030.08718.25
5.6.130.0000.04318.10
5.6.120.0070.07320.99
5.6.110.0000.08721.05
5.6.100.0100.08021.09
5.6.90.0100.08021.04
5.6.80.0100.03720.41
5.5.350.0200.05720.40
5.5.340.0170.07317.96
5.5.330.0070.08320.19
5.5.320.0200.08020.38
5.5.310.0230.08020.26
5.5.300.0070.08717.97
5.5.290.0170.04017.94
5.5.280.0070.04020.88
5.5.270.0070.07720.88
5.5.260.0000.05020.88
5.5.250.0030.07020.77
5.5.240.0000.07720.28
5.4.450.0100.06319.61
5.4.440.0170.06319.59
5.4.430.0070.06719.58
5.4.420.0300.04319.29
5.4.410.0130.05719.19
5.4.400.0100.06319.31
5.4.390.0230.06319.09
5.4.380.0130.05719.12
5.4.370.0230.05719.14
5.4.360.0270.05719.28
5.4.350.0200.05019.15
5.4.340.0200.05319.12
5.4.320.0200.05318.81
5.4.310.0170.05019.32
5.4.300.0270.04319.14
5.4.290.0230.04719.26
5.4.280.0200.05018.84
5.4.270.0070.06319.20
5.4.260.0070.05719.26
5.4.250.0170.05718.95
5.4.240.0200.05319.25
5.4.230.0130.05318.95
5.4.220.0200.05319.14
5.4.210.0270.04319.12
5.4.200.0270.04019.03
5.4.190.0170.05019.02
5.4.180.0200.05018.80
5.4.170.0300.04019.29
5.4.160.0230.05018.79
5.4.150.0200.06019.28
5.4.140.0130.07016.38
5.4.130.0130.05016.62
5.4.120.0200.04716.34
5.4.110.0200.04716.64
5.4.100.0170.05316.57
5.4.90.0130.04716.64
5.4.80.0130.05016.66
5.4.70.0170.03716.41
5.4.60.0230.07316.43
5.4.50.0330.06316.22
5.4.40.0230.05316.56
5.4.30.0170.04316.55
5.4.20.0170.03316.22
5.4.10.0370.04716.34

preferences:
55.87 ms | 401 KiB | 5 Q