mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 23:21:59 +00:00
Update bitops.h
This commit is contained in:
parent
18731c4beb
commit
c1039ed0f3
@ -26,7 +26,7 @@ inline uint32_t HI_32(uint64_t x) { return static_cast<uint32_t>(x >> 32); }
|
||||
return std::numeric_limits<unsigned long long>::digits - __builtin_clzll(value);
|
||||
}
|
||||
#else
|
||||
/// Stupid realization for non GCC-like compilers. Can use BSR from x86 instructions set.
|
||||
/// Stupid implementation for non GCC-like compilers. Can use BSR from x86 instructions set.
|
||||
template <typename T>
|
||||
inline unsigned GetValueBitCountImpl(T value) noexcept {
|
||||
unsigned result = 1; // result == 0 - impossible value, since value cannot be zero
|
||||
|
Loading…
Reference in New Issue
Block a user