aboutsummaryrefslogtreecommitdiff
path: root/src/port/pg_bitutils_hwpopcnt.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/port/pg_bitutils_hwpopcnt.c')
-rw-r--r--src/port/pg_bitutils_hwpopcnt.c36
1 files changed, 0 insertions, 36 deletions
diff --git a/src/port/pg_bitutils_hwpopcnt.c b/src/port/pg_bitutils_hwpopcnt.c
deleted file mode 100644
index 516efd586dd..00000000000
--- a/src/port/pg_bitutils_hwpopcnt.c
+++ /dev/null
@@ -1,36 +0,0 @@
-/*-------------------------------------------------------------------------
- *
- * pg_bitutils_hwpopcnt.c
- * CPU-optimized implementation of pg_popcount variants
- *
- * This file must be compiled with a compiler-specific flag to enable the
- * POPCNT instruction.
- *
- * Portions Copyright (c) 2019, PostgreSQL Global Development Group
- *
- * IDENTIFICATION
- * src/port/pg_bitutils_hwpopcnt.c
- *
- *-------------------------------------------------------------------------
- */
-#include "postgres.h"
-
-#include "port/pg_bitutils.h"
-
-int
-pg_popcount32_hw(uint32 word)
-{
- return __builtin_popcount(word);
-}
-
-int
-pg_popcount64_hw(uint64 word)
-{
-#if defined(HAVE_LONG_INT_64)
- return __builtin_popcountl(word);
-#elif defined(HAVE_LONG_LONG_INT_64)
- return __builtin_popcountll(word);
-#else
-#error must have a working 64-bit integer datatype
-#endif
-}