summaryrefslogtreecommitdiff
path: root/lib/bitops.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bitops.h')
-rw-r--r--lib/bitops.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/bitops.h b/lib/bitops.h
index a4c48a10..0beda2a3 100644
--- a/lib/bitops.h
+++ b/lib/bitops.h
@@ -28,6 +28,7 @@ u32 u32_log2(u32 v);
static inline u32 u32_hash(u32 v) { return v * 2902958171u; }
static inline u8 u32_popcount(u32 v) { return __builtin_popcount(v); }
+static inline u8 u64_popcount(u64 v) { return __builtin_popcountll(v); }
static inline int u32_clz(u32 v) { return __builtin_clz(v); }
static inline int u32_ctz(u32 v) { return __builtin_ctz(v); }