You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2020/04/26 06:03:37 UTC

[GitHub] [arrow] emkornfield commented on a change in pull request #6954: ARROW-8440: [C++] Refine SIMD header files

emkornfield commented on a change in pull request #6954:
URL: https://github.com/apache/arrow/pull/6954#discussion_r415226340



##########
File path: cpp/src/arrow/util/hash_util.h
##########
@@ -27,39 +27,27 @@
 
 #include "arrow/util/logging.h"
 #include "arrow/util/macros.h"
-#include "arrow/util/neon_util.h"
-#include "arrow/util/sse_util.h"
+#include "arrow/util/simd.h"
 
-static inline uint32_t HW_crc32_u8(uint32_t crc, uint8_t v) {
-  DCHECK(false) << "Hardware CRC support is not enabled";
-  return 0;
-}
-
-static inline uint32_t HW_crc32_u16(uint32_t crc, uint16_t v) {
-  DCHECK(false) << "Hardware CRC support is not enabled";
-  return 0;
-}
-
-static inline uint32_t HW_crc32_u32(uint32_t crc, uint32_t v) {
-  DCHECK(false) << "Hardware CRC support is not enabled";
-  return 0;
-}
-
-static inline uint32_t HW_crc32_u64(uint32_t crc, uint64_t v) {
+#ifdef ARROW_HAVE_SSE4_2

Review comment:
       I'd be concerned about putting too much in SIMD directly.  If we expect these to be used in other places that don't depend on this header we should create a specific header targetted at hardware. digests/hashing.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org