]> git.ipfire.org Git - thirdparty/vectorscan.git/commitdiff
ICC doesn't have a __POPCNT__ macro
authorMatthew Barr <matthew.barr@intel.com>
Wed, 29 Mar 2017 02:04:27 +0000 (13:04 +1100)
committerMatthew Barr <matthew.barr@intel.com>
Wed, 26 Apr 2017 05:18:26 +0000 (15:18 +1000)
src/util/popcount.h

index d882a67200fdec62ca8b97d041e2bb5051c52af8..15361380eba0431b515c7cac052322a35f142c59 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015-2016, Intel Corporation
+ * Copyright (c) 2015-2017, Intel Corporation
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions are met:
@@ -30,8 +30,8 @@
  * \brief Platform specific popcount functions
  */
 
-#ifndef POPCOUNT_H_075D843B4545B6
-#define POPCOUNT_H_075D843B4545B6
+#ifndef UTIL_POPCOUNT_H_
+#define UTIL_POPCOUNT_H_
 
 #include "ue2common.h"
 
@@ -40,6 +40,8 @@
 #define HAVE_POPCOUNT_INSTR
 #elif defined(_WIN32) && defined(__AVX__) // TODO: fix win preproc
 #define HAVE_POPCOUNT_INSTR
+#elif defined(__INTEL_COMPILER) && defined(__SSE4_2__)
+#define HAVE_POPCOUNT_INSTR
 #endif
 
 static really_inline
@@ -76,5 +78,5 @@ u32 popcount64(u64a x) {
 #endif
 }
 
-#endif /* POPCOUNT_H_075D843B4545B6 */
+#endif /* UTIL_POPCOUNT_H_ */