3v4l.org

run code in 500+ PHP versions simultaneously
<?php $sortMe = [100, 1, 10, 1000]; function cmp($a, $b) { static $example = [1, 1000, 100, 10]; return array_search($a, $example) - array_search($b, $example); } uasort($sortMe, 'cmp'); var_export($sortMe);

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.70.0080.00616.63
8.5.60.0110.00716.62
8.5.50.0120.00518.32
8.5.30.0070.01019.69
8.5.20.0120.00619.50
8.5.10.0120.00520.09
8.5.00.0120.00919.93
8.4.210.0150.00619.54
8.4.180.0110.01119.43
8.4.170.0140.00921.82
8.4.160.0110.01122.05
8.4.150.0070.00516.83
8.4.140.0090.01117.46
8.4.130.0080.01119.06
8.4.120.0140.00717.61
8.4.110.0060.00319.63
8.4.100.0090.01017.84
8.4.90.0060.00420.29
8.4.80.0090.00718.74
8.4.70.0050.00318.05
8.4.60.0070.00418.92
8.4.50.0050.00418.65
8.4.40.0140.00719.61
8.4.30.0100.00620.46
8.4.20.0090.00925.73
8.4.10.0060.00323.82
8.3.300.0120.00918.36
8.3.290.0100.01020.86
8.3.280.0110.01018.23
8.3.270.0110.00816.61
8.3.260.0070.00316.55
8.3.250.0100.00916.50
8.3.240.0090.00918.91
8.3.230.0100.00916.47
8.3.220.0070.00119.11
8.3.210.0110.00418.42
8.3.200.0060.00316.43
8.3.190.0080.00517.22
8.3.180.0080.00717.23
8.3.170.0030.00618.87
8.3.160.0120.00617.04
8.3.150.0120.00618.83
8.3.140.0050.00316.58
8.3.130.0080.00016.62
8.3.120.0080.00820.55
8.3.110.0060.00316.35
8.3.100.0080.00024.06
8.3.90.0090.00626.77
8.3.80.0070.00316.50
8.3.70.0060.00918.55
8.3.60.0110.00718.43
8.3.50.0090.01316.41
8.3.40.0100.00320.29
8.3.30.0090.00618.34
8.3.20.0040.00424.18
8.3.10.0050.00324.66
8.3.00.0060.00326.16
8.2.300.0170.00622.18
8.2.290.0070.00816.46
8.2.280.0100.00718.49
8.2.270.0110.00817.19
8.2.260.0080.00018.93
8.2.250.0050.00317.41
8.2.240.0080.00017.09
8.2.230.0040.00420.94
8.2.220.0060.01337.54
8.2.210.0090.00926.77
8.2.200.0060.00318.04
8.2.190.0100.01016.58
8.2.180.0070.00718.43
8.2.170.0040.01118.91
8.2.160.0070.00722.96
8.2.150.0070.00025.66
8.2.140.0060.00324.66
8.2.130.0000.00826.16
8.2.120.0040.00421.06
8.2.110.0060.00320.30
8.2.100.0090.00317.84
8.2.90.0090.00019.63
8.2.80.0030.00519.22
8.2.70.0040.00417.61
8.2.60.0040.00418.04
8.2.50.0040.00418.07
8.2.40.0120.00018.22
8.2.30.0040.00417.94
8.2.20.0040.00419.25
8.2.10.0060.00717.64
8.2.00.0120.00417.67
8.1.340.0100.01219.50
8.1.330.0110.00715.84
8.1.320.0070.01215.90
8.1.310.0040.00416.78
8.1.300.0140.00416.04
8.1.290.0060.00318.88
8.1.280.0170.00325.92
8.1.270.0070.00724.66
8.1.260.0110.00326.35
8.1.250.0040.00428.09
8.1.240.0110.00021.97
8.1.230.0070.00421.03
8.1.220.0000.00917.74
8.1.210.0000.00818.87
8.1.200.0000.00917.35
8.1.190.0080.00017.23
8.1.180.0060.00318.10
8.1.170.0070.00018.96
8.1.160.0000.00818.89
8.1.150.0000.00718.67
8.1.140.0100.00617.41
8.1.130.0110.00317.40
8.1.120.0130.00317.51
8.1.110.0130.00517.46
8.1.100.0140.00317.40
8.1.90.0120.00517.43
8.1.80.0130.00517.41
8.1.70.0140.00417.45
8.1.60.0110.00817.54
8.1.50.0120.00817.47
8.1.40.0120.00717.54
8.1.30.0170.00417.58
8.1.20.0130.00617.59
8.1.10.0150.00617.46
8.1.00.0140.00717.45
8.0.300.0070.00019.95
8.0.290.0040.00416.75
8.0.280.0030.00618.35
8.0.270.0100.00316.75
8.0.260.0060.00816.76
8.0.250.0100.00416.86
8.0.240.0110.00416.86
8.0.230.0080.00716.83
8.0.220.0100.00516.74
8.0.210.0100.00616.78
8.0.200.0140.00216.81
8.0.190.0080.00816.81
8.0.180.0140.00216.84
8.0.170.0090.00816.87
8.0.160.0100.00616.81
8.0.150.0100.00416.74
8.0.140.0130.00416.76
8.0.130.0130.00316.76
8.0.120.0120.00516.77
8.0.110.0080.00816.80
8.0.100.0100.00516.81
8.0.90.0090.00716.78
8.0.80.0110.00416.79
8.0.70.0130.00216.76
8.0.60.0120.00316.80
8.0.50.0100.00516.75
8.0.30.0060.00616.79
8.0.20.0050.00617.22
8.0.10.0080.00317.29
7.0.130.0050.00516.82

preferences:
70.92 ms | 1124 KiB | 5 Q