diff options
| author | mlugg <mlugg@mlugg.co.uk> | 2024-08-24 16:16:53 +0100 |
|---|---|---|
| committer | mlugg <mlugg@mlugg.co.uk> | 2024-08-27 00:44:35 +0100 |
| commit | 6808ce27bdca14d3876ac607c94f75ea054db7b8 (patch) | |
| tree | c30b229113d60243a1257fad597ec919c99e3dad /lib/std/sort | |
| parent | a3a737e9a68fae96519743a644209b4a30cf3b58 (diff) | |
| download | zig-6808ce27bdca14d3876ac607c94f75ea054db7b8.tar.gz zig-6808ce27bdca14d3876ac607c94f75ea054db7b8.zip | |
compiler,lib,test,langref: migrate `@setCold` to `@branchHint`
Diffstat (limited to 'lib/std/sort')
| -rw-r--r-- | lib/std/sort/pdq.zig | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/std/sort/pdq.zig b/lib/std/sort/pdq.zig index 61d78797c5..55bd17ae93 100644 --- a/lib/std/sort/pdq.zig +++ b/lib/std/sort/pdq.zig @@ -203,7 +203,7 @@ fn partitionEqual(a: usize, b: usize, pivot: usize, context: anytype) usize { /// /// returns `true` if the slice is sorted at the end. This function is `O(n)` worst-case. fn partialInsertionSort(a: usize, b: usize, context: anytype) bool { - @setCold(true); + @branchHint(.cold); // maximum number of adjacent out-of-order pairs that will get shifted const max_steps = 5; @@ -247,7 +247,7 @@ fn partialInsertionSort(a: usize, b: usize, context: anytype) bool { } fn breakPatterns(a: usize, b: usize, context: anytype) void { - @setCold(true); + @branchHint(.cold); const len = b - a; if (len < 8) return; |
