Skip to content

Commit 29fb3c4

Browse files
committed
[chore](function) Use uppercase literal suffixes in the top-K priority generators
1 parent 52176aa commit 29fb3c4

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

‎be/src/exprs/aggregate/aggregate_function_topk.h‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -92,9 +92,9 @@ inline uint32_t next_topk_priority_seed() {
9292
std::random_device device;
9393
return static_cast<uint32_t>(device());
9494
}();
95-
uint32_t z = base + counter.fetch_add(1, std::memory_order_relaxed) * 0x9E3779B9u;
96-
z = (z ^ (z >> 16)) * 0x21F0AAADu;
97-
z = (z ^ (z >> 15)) * 0x735A2D97u;
95+
uint32_t z = base + counter.fetch_add(1, std::memory_order_relaxed) * 0x9E3779B9U;
96+
z = (z ^ (z >> 16)) * 0x21F0AAADU;
97+
z = (z ^ (z >> 15)) * 0x735A2D97U;
9898
return z ^ (z >> 15);
9999
}
100100

@@ -448,9 +448,9 @@ class AggregateFunctionTopK final
448448
/// splitmix32. The priorities only have to be independent enough to keep the treap balanced;
449449
/// a per-state sequence keeps the shape reproducible for the same insertion order.
450450
static uint32_t next_priority(State& state) {
451-
uint32_t z = (state.rng += 0x9E3779B9u);
452-
z = (z ^ (z >> 16)) * 0x21F0AAADu;
453-
z = (z ^ (z >> 15)) * 0x735A2D97u;
451+
uint32_t z = (state.rng += 0x9E3779B9U);
452+
z = (z ^ (z >> 16)) * 0x21F0AAADU;
453+
z = (z ^ (z >> 15)) * 0x735A2D97U;
454454
return z ^ (z >> 15);
455455
}
456456

0 commit comments

Comments
 (0)