3v4l.org

run code in 300+ PHP versions simultaneously
<?php function string(string $string): string { return $string; } $string = string('string'); echo $string;

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.0030.01718.18
8.3.50.0070.00716.22
8.3.40.0090.00918.79
8.3.30.0100.01018.67
8.3.20.0040.00421.60
8.3.10.0080.00023.57
8.3.00.0070.00020.81
8.2.180.0120.00616.38
8.2.170.0030.01222.96
8.2.160.0140.00020.11
8.2.150.0000.00824.18
8.2.140.0080.00024.66
8.2.130.0080.00026.16
8.2.120.0040.00718.90
8.2.110.0110.00021.12
8.2.100.0040.00819.44
8.2.90.0080.00019.20
8.2.80.0040.00418.05
8.2.70.0050.00317.80
8.2.60.0040.00418.16
8.2.50.0030.00618.10
8.2.40.0000.00819.47
8.2.30.0000.00719.23
8.2.20.0000.00718.05
8.2.10.0000.00719.17
8.2.00.0050.00219.21
8.1.280.0070.01525.92
8.1.270.0080.00018.83
8.1.260.0030.00626.35
8.1.250.0040.01128.09
8.1.240.0090.00023.91
8.1.230.0000.01122.80
8.1.220.0040.00417.74
8.1.210.0070.00318.77
8.1.200.0030.00617.23
8.1.190.0000.00817.23
8.1.180.0040.00418.10
8.1.170.0040.00418.59
8.1.160.0000.00818.82
8.1.150.0040.00418.69
8.1.140.0030.00320.61
8.1.130.0030.00320.25
8.1.120.0070.00017.37
8.1.110.0040.00417.44
8.1.100.0000.00917.40
8.1.90.0000.00817.43
8.1.80.0040.00417.31
8.1.70.0000.00717.39
8.1.60.0070.00017.54
8.1.50.0030.00517.39
8.1.40.0030.00517.47
8.1.30.0000.00717.58
8.1.20.0000.00817.55
8.1.10.0070.00017.57
8.1.00.0000.00717.52
8.0.300.0040.00419.64
8.0.290.0000.00816.63
8.0.280.0070.00018.48
8.0.270.0000.00717.25
8.0.260.0060.00018.43
8.0.250.0030.00316.90
8.0.240.0030.00316.88
8.0.230.0030.00316.88
8.0.220.0000.00716.83
8.0.210.0070.00016.78
8.0.200.0000.00716.75
8.0.190.0080.00016.77
8.0.180.0040.00416.89
8.0.170.0040.00416.84
8.0.160.0030.00316.68
8.0.150.0030.00316.77
8.0.140.0030.00316.83
8.0.130.0000.00513.24
8.0.120.0030.00516.77
8.0.110.0040.00416.74
8.0.100.0000.00716.82
8.0.90.0040.00416.89
8.0.80.0130.00816.77
8.0.70.0040.00416.82
8.0.60.0000.00716.82
8.0.50.0040.00416.78
8.0.30.0110.00817.11
8.0.20.0110.00817.40
8.0.10.0030.00616.96
8.0.00.0100.00816.85
7.4.330.0030.00315.55
7.4.320.0060.00016.52
7.4.300.0030.00316.59
7.4.290.0030.00316.39
7.4.280.0080.00016.56
7.4.270.0040.00416.61
7.4.260.0030.00316.57
7.4.250.0000.00716.52
7.4.240.0030.00316.59
7.4.230.0000.00716.62
7.4.220.0040.00416.71
7.4.210.0060.00716.54
7.4.200.0030.00316.57
7.4.160.0080.01016.58
7.4.140.0080.01017.86
7.4.130.0130.00316.70
7.4.120.0070.01316.63
7.4.110.0130.00716.46
7.4.100.0100.01316.65
7.4.90.0030.01416.40
7.4.80.0140.00919.39
7.4.70.0070.01016.60
7.4.60.0090.00716.55
7.4.50.0000.01216.39
7.4.40.0130.00616.31
7.4.00.0060.00914.64
7.3.330.0000.00613.29
7.3.320.0030.00313.15
7.3.310.0000.00916.30
7.3.300.0060.00016.27
7.3.290.0040.00416.24
7.3.280.0070.00916.23
7.3.260.0070.01016.50
7.3.240.0100.00716.38
7.3.230.0110.00516.30
7.3.210.0060.00916.35
7.3.200.0120.00316.29
7.3.190.0090.00916.61
7.3.180.0130.00316.44
7.3.170.0130.00616.36
7.3.160.0160.00616.59
7.3.10.0610.00514.70
7.3.00.0700.00614.68
7.2.330.0080.00816.35
7.2.320.0100.00716.38
7.2.310.0140.01416.68
7.2.300.0160.00616.59
7.2.290.0110.00516.66
7.2.130.0550.00814.86
7.2.120.0620.00614.88
7.2.110.0720.00414.99
7.2.100.0680.00714.90
7.2.90.0640.00815.03
7.2.80.0540.00914.95
7.2.70.0600.00814.91
7.2.60.0650.00614.92
7.2.50.0620.00815.02
7.2.40.0710.00814.95
7.2.30.0680.00715.01
7.2.20.0600.00614.87
7.2.10.0630.00814.88
7.2.00.0700.00514.95
7.1.250.0600.00913.73

preferences:
65.44 ms | 400 KiB | 5 Q