3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = array( [ "unix" => 1556547761, // notice the two duplicate unix values "random" => 4 ], [ "unix" => 1556547761, "random" => 2 ], [ "unix" => 1556547769, "random" => 5 ], [ "unix" => 1556547765, // this should be in the 3rd position "random" => 9 ] ); function cmpByUnix($a, $b) { return $a["unix"] - $b["unix"]; } usort($array, "cmpByUnix"); print_r($array);

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.00819.84
8.4.150.0030.00014.05
8.4.140.0130.00917.54
8.4.130.0140.00719.06
8.4.120.0090.01320.40
8.4.110.0100.00919.05
8.4.100.0140.00717.55
8.4.90.0050.00320.62
8.4.80.0050.00418.93
8.4.70.0080.00918.95
8.4.60.0150.00820.58
8.4.50.0100.01018.45
8.4.40.0030.01719.50
8.4.30.0160.00617.55
8.4.20.0070.00418.92
8.4.10.0030.00520.67
8.3.280.0110.00918.25
8.3.270.0090.00916.74
8.3.260.0080.00216.80
8.3.250.0120.00618.88
8.3.240.0090.01118.73
8.3.230.0080.00816.63
8.3.220.0110.00618.76
8.3.210.0110.00816.61
8.3.200.0060.00216.72
8.3.190.0070.01316.92
8.3.180.0140.00520.62
8.3.170.0150.00318.93
8.3.160.0140.00416.55
8.3.150.0060.01216.64
8.3.140.0080.00016.47
8.3.130.0080.00018.44
8.3.120.0030.00618.79
8.3.110.0030.00520.94
8.3.100.0070.00724.06
8.3.90.0170.00326.77
8.3.80.0030.00718.30
8.3.70.0150.00816.75
8.3.60.0060.01518.27
8.3.50.0120.00718.18
8.3.40.0040.01118.58
8.3.30.0120.00318.47
8.3.20.0040.00421.74
8.3.10.0000.00721.93
8.3.00.0070.00021.77
8.2.290.0080.00618.79
8.2.280.0110.00820.46
8.2.270.0100.00316.82
8.2.260.0040.00417.12
8.2.250.0000.00819.16
8.2.240.0030.00618.96
8.2.230.0080.00022.58
8.2.220.0040.00737.54
8.2.210.0110.00326.77
8.2.200.0040.00716.50
8.2.190.0070.00716.88
8.2.180.0070.01425.92
8.2.170.0100.00718.96
8.2.160.0060.00622.96
8.2.150.0000.00824.18
8.2.140.0080.00024.66
8.2.130.0070.00026.16
8.2.120.0000.00821.08
8.2.110.0080.00320.52
8.2.100.0060.00617.72
8.2.90.0050.00317.63
8.2.80.0000.00817.97
8.2.70.0060.00318.05
8.2.60.0000.00718.16
8.2.50.0080.00018.10
8.2.40.0040.00419.11
8.2.30.0040.00420.45
8.2.20.0040.00418.06
8.2.10.0000.00719.25
8.2.00.0070.00317.98
8.1.330.0140.00518.27
8.1.320.0120.00716.36
8.1.310.0110.00716.68
8.1.300.0050.00519.65
8.1.290.0040.00430.84
8.1.280.0110.00425.92
8.1.270.0000.00724.66
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0090.00022.02
8.1.230.0070.00420.91
8.1.220.0000.00817.74
8.1.210.0040.00418.77
8.1.200.0060.00317.35
8.1.190.0050.00317.23
8.1.180.0050.00518.10
8.1.170.0000.00818.65
8.1.160.0000.00818.73
8.1.150.0040.00418.88
8.1.140.0040.00418.74
8.1.130.0060.00320.16
8.1.120.0030.00317.41
8.1.110.0000.00717.43
8.1.100.0000.00817.35
8.1.90.0000.00717.32
8.1.80.0030.00517.43
8.1.70.0000.00717.38
8.1.60.0030.00617.59
8.1.50.0050.00317.48
8.1.40.0030.00517.45
8.1.30.0000.00817.59
8.1.20.0040.00417.56
8.1.10.0020.00517.44
8.1.00.0040.00417.48
8.0.300.0040.00418.77
8.0.290.0040.00416.75
8.0.280.0030.00318.38
8.0.270.0030.00316.80
8.0.260.0000.00618.39
8.0.250.0060.00316.98
8.0.240.0040.00416.99
8.0.230.0000.01016.98
8.0.220.0040.00416.95
8.0.210.0060.00316.86
8.0.200.0000.00716.86
8.0.190.0040.00416.81
8.0.180.0000.00816.85
8.0.170.0050.00316.85
8.0.160.0040.00416.75
8.0.150.0020.00516.68
8.0.140.0070.00016.78
8.0.130.0000.00613.27
8.0.120.0040.00416.80
8.0.110.0040.00416.81
8.0.100.0080.00016.66
8.0.90.0070.00016.88
8.0.80.0090.00616.87
8.0.70.0000.00716.86
8.0.60.0040.00416.73
8.0.50.0050.00216.80
8.0.30.0140.00417.00
8.0.20.0030.01717.25
8.0.10.0000.00816.73
8.0.00.0100.01116.70
7.4.330.0000.00516.57
7.4.320.0040.00416.45
7.4.300.0000.00716.39
7.4.290.0070.00016.34
7.4.280.0050.00216.37
7.4.270.0100.00016.47
7.4.260.0000.00716.57
7.4.250.0030.00316.40
7.4.240.0070.00016.55
7.4.230.0070.00016.57
7.4.220.0050.00316.65
7.4.210.0080.00816.52
7.4.200.0070.00016.24
7.4.160.0090.00916.41
7.4.140.0120.01217.86
7.4.130.0030.01416.55
7.4.120.0090.00916.38
7.4.110.0070.01016.43
7.4.100.0100.00716.58
7.4.90.0070.01016.54
7.4.80.0030.01619.39
7.4.70.0060.01116.51
7.4.60.0180.00616.21
7.4.50.0000.01116.35
7.4.40.0070.01016.30
7.4.10.0160.00014.77
7.4.00.0060.00914.84
7.3.330.0020.00213.25
7.3.320.0000.00613.23
7.3.310.0030.00316.32
7.3.300.0070.00016.16
7.3.290.0000.00716.23
7.3.280.0090.00916.21
7.3.260.0120.00716.39
7.3.240.0080.01116.33
7.3.230.0060.01316.65
7.3.210.0160.00816.52
7.3.200.0130.00316.29
7.3.190.0090.00616.38
7.3.180.0060.00916.32
7.3.170.0060.00916.33
7.3.160.0050.01016.57
7.3.120.0070.01114.66
7.3.110.0060.01214.81
7.3.100.0000.01514.66
7.3.90.0040.00814.85
7.3.80.0090.00914.63
7.3.70.0060.00614.80
7.3.60.0070.00714.88
7.3.50.0040.00714.64
7.3.40.0070.00714.68
7.3.30.0140.00514.73
7.3.20.0090.00416.49
7.3.10.0110.00416.57
7.3.00.0100.00316.63
7.2.330.0000.01716.66
7.2.320.0070.01116.73
7.2.310.0130.00316.38
7.2.300.0070.01016.41
7.2.290.0060.01316.60
7.2.250.0000.01515.02
7.2.240.0000.02014.88
7.2.230.0070.00714.91
7.2.220.0080.00815.22
7.2.210.0060.01215.04
7.2.200.0030.01014.60
7.2.190.0000.01314.94
7.2.180.0060.01115.14
7.2.170.0120.00214.90
7.2.160.0060.00514.77
7.2.150.0030.01316.84
7.2.140.0080.00516.74
7.2.130.0100.00616.91
7.2.120.0090.00516.68
7.2.110.0060.00916.89
7.2.100.0100.00516.93
7.2.90.0060.00816.90
7.2.80.0080.00616.99
7.2.70.0090.01016.73
7.2.60.0130.00616.86
7.2.50.0060.01116.75
7.2.40.0080.00716.83
7.2.30.0110.01016.87
7.2.20.0100.00616.81
7.2.10.0050.01116.75
7.2.00.0050.01016.71
7.1.330.0080.00815.73
7.1.320.0100.00315.75
7.1.310.0080.00615.75
7.1.300.0030.01315.71
7.1.290.0070.00715.81
7.1.280.0130.00315.80
7.1.270.0030.00815.78
7.1.260.0060.00815.62
7.1.250.0040.00615.89
7.1.240.0070.00415.56
7.1.230.0110.00715.66
7.1.220.0090.00615.71
7.1.210.0030.00715.74
7.1.200.0090.00615.93
7.1.190.0030.01416.02
7.1.180.0030.01015.75
7.1.170.0080.00715.80
7.1.160.0090.00015.66
7.1.150.0030.01515.66
7.1.140.0030.01315.73
7.1.130.0090.00915.55
7.1.120.0030.00915.50
7.1.110.0060.00315.58
7.1.100.0040.00815.68
7.1.90.0090.00515.89
7.1.80.0090.00015.57
7.1.70.0030.01015.89
7.1.60.0100.00315.61
7.1.50.0040.00415.82
7.1.40.0030.01315.69
7.1.30.0000.01315.60
7.1.20.0040.00815.92
7.1.10.0030.00915.77
7.1.00.0100.00315.69

preferences:
34.83 ms | 403 KiB | 5 Q