3v4l.org

run code in 300+ PHP versions simultaneously
<?php function hello(int $n, ?bool $m = false): string { $m = $m ? 'true' : 'false'; return "The number {$n} is called {$m}"; } $a = [1, 2, 3, 4, 5]; $c = array_map('hello', $a, array_fill(0,2,true)); print_r($c);

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.5.00.0130.00919.97
8.4.150.0100.00316.88
8.4.140.0110.01017.47
8.4.130.0060.00317.91
8.4.120.0140.00624.17
8.4.110.0110.00918.67
8.4.100.0030.00617.77
8.4.90.0040.00618.80
8.4.80.0080.00822.48
8.4.70.0090.00717.71
8.4.60.0130.00718.59
8.4.50.0120.00919.67
8.4.40.0060.01317.80
8.4.30.0090.01020.67
8.4.20.0140.00717.71
8.4.10.0060.00317.69
8.3.280.0030.00014.05
8.3.270.0150.00716.36
8.3.260.0120.00616.64
8.3.250.0070.00316.53
8.3.240.0120.00716.79
8.3.230.0070.00416.80
8.3.220.0100.00717.19
8.3.210.0110.00616.33
8.3.200.0030.00616.39
8.3.190.0110.00717.13
8.3.180.0130.00616.34
8.3.170.0040.01418.88
8.3.160.0070.01118.12
8.3.150.0090.00920.57
8.3.140.0070.00716.48
8.3.130.0100.01018.16
8.3.120.0030.00618.59
8.3.110.0110.00020.94
8.3.100.0040.01216.38
8.3.90.0140.00026.77
8.3.80.0090.00016.50
8.3.70.0090.00616.63
8.3.60.0160.00616.63
8.3.50.0090.00917.97
8.3.40.0100.00720.23
8.3.30.0150.00318.81
8.3.20.0040.00424.18
8.3.10.0040.00424.66
8.3.00.0080.00026.16
8.2.290.0100.00820.25
8.2.280.0020.00619.05
8.2.270.0120.00619.12
8.2.260.0060.00920.08
8.2.250.0000.00816.51
8.2.240.0130.00319.17
8.2.230.0040.00422.58
8.2.220.0050.00524.06
8.2.210.0140.00026.77
8.2.200.0070.00418.07
8.2.190.0140.00316.63
8.2.180.0150.00425.92
8.2.170.0110.00318.71
8.2.160.0070.01022.96
8.2.150.0080.00025.66
8.2.140.0080.00024.66
8.2.130.0070.00026.16
8.2.120.0080.00019.66
8.2.110.0030.00722.25
8.2.100.0090.00317.72
8.2.90.0000.00818.03
8.2.80.0050.00319.16
8.2.70.0000.00817.63
8.2.60.0070.00317.63
8.2.50.0030.00517.55
8.2.40.0040.00417.63
8.2.30.0050.00318.04
8.2.20.0040.00420.49
8.2.10.0040.00417.80
8.2.00.0100.00019.38
8.1.330.0110.00720.22
8.1.320.0100.00616.13
8.1.310.0030.00518.57
8.1.300.0030.00718.34
8.1.290.0030.00630.84
8.1.280.0090.00625.92
8.1.270.0080.00023.99
8.1.260.0090.00626.35
8.1.250.0050.00228.09
8.1.240.0090.00023.87
8.1.230.0060.00622.76
8.1.220.0040.00417.76
8.1.210.0040.00418.77
8.1.200.0060.00317.35
8.1.190.0040.00417.23
8.1.180.0090.00018.10
8.1.170.0040.00417.62
8.1.160.0030.00618.79
8.1.150.0070.00018.51
8.1.140.0000.00717.38
8.1.130.0030.00318.73
8.1.120.0040.00417.39
8.1.110.0000.00717.35
8.1.100.0040.00417.39
8.1.90.0070.00017.38
8.1.80.0030.00917.28
8.1.70.0040.00417.38
8.1.60.0040.00417.41
8.1.50.0030.00617.43
8.1.40.0000.00717.45
8.1.30.0080.00017.59
8.1.20.0040.00417.60
8.1.10.0050.00317.59
8.1.00.0000.00717.46
8.0.300.0050.00220.08
8.0.290.0080.00016.63
8.0.280.0080.00020.18
8.0.270.0040.00416.69
8.0.260.0000.00618.45
8.0.250.0030.00316.98
8.0.240.0030.00316.89
8.0.230.0000.00716.91
8.0.220.0000.00716.92
8.0.210.0000.00816.89
8.0.200.0000.00616.96
8.0.190.0040.00417.00
8.0.180.0050.00216.89
8.0.170.0000.00916.88
8.0.160.0000.00816.85
8.0.150.0040.00416.79
8.0.140.0070.00016.83
8.0.130.0000.00716.81
8.0.120.0000.00716.88
8.0.110.0000.00716.93
8.0.100.0040.00416.86
8.0.90.0030.00316.71
8.0.80.0000.00716.89
8.0.70.0000.00716.80
8.0.60.0040.00416.71
8.0.50.0040.00416.79
8.0.30.0030.00316.86
8.0.20.0000.00716.99
8.0.10.0000.00716.96
7.4.330.0050.00015.55
7.4.320.0030.00316.46
7.4.300.0060.00016.39
7.4.290.0000.00816.49
7.4.280.0040.00416.58
7.4.270.0040.00416.40
7.4.260.0030.00316.55
7.4.250.0070.00016.40
7.4.240.0030.00316.40
7.4.230.0020.00516.28
7.4.220.0070.00016.39
7.4.210.0000.00616.40
7.4.200.0030.00316.41
7.4.190.0070.00016.49
7.4.180.0030.00316.54
7.4.160.0000.00716.49
7.4.150.0070.00016.40
7.4.140.0030.00316.30
7.4.130.0050.00216.36
7.4.120.0000.00716.38
7.4.110.0030.00316.25
7.4.100.0060.00016.52
7.4.90.0030.00316.46
7.4.80.0030.00316.39
7.4.70.0040.00416.34
7.4.60.0000.00716.39
7.4.50.0000.00716.29
7.4.40.0030.00516.32
7.4.30.0030.00316.27
7.4.20.0060.00016.27
7.4.10.0030.00316.30
7.4.00.0050.00316.41

preferences:
30.15 ms | 403 KiB | 5 Q