summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2022-11-09 12:57:04 -0500
committerTavian Barnes <tavianator@tavianator.com>2022-11-09 12:57:33 -0500
commitccbff779918934d1f863bffd5b411926d39390d8 (patch)
tree5929bc1a0e8b10d514d89fdf0edf5b8e67141d4a
parentfc63f1b33fb438e8f7690db9bd84e3c69fe86b51 (diff)
downloadbfs-ccbff779918934d1f863bffd5b411926d39390d8.tar.xz
trie: Check __has_attribute(target_clones) before using it
-rw-r--r--src/trie.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/trie.c b/src/trie.c
index 24cc3a3..4bbdf13 100644
--- a/src/trie.c
+++ b/src/trie.c
@@ -103,7 +103,7 @@
#include <stdlib.h>
#include <string.h>
-#if __GNUC__ && (__i386__ || __x86_64__)
+#if __has_attribute(target_clones) && (__i386__ || __x86_64__)
# define TARGET_CLONES_POPCNT __attribute__((target_clones("popcnt", "default")))
#else
# define TARGET_CLONES_POPCNT