diff options
author | Keith Bostic <keith.bostic@mongodb.com> | 2016-09-08 02:46:05 -0400 |
---|---|---|
committer | Michael Cahill <michael.cahill@mongodb.com> | 2016-09-08 16:46:05 +1000 |
commit | 881a37eea1668d47c5d5fb38001a2850ca117495 (patch) | |
tree | 898db838171a0920fc0b29ac900ecdcf7ec6ee6a /build_posix | |
parent | 5f07ab685f2b1e978cfda354dd52a5fc52f8f8ab (diff) | |
download | mongo-881a37eea1668d47c5d5fb38001a2850ca117495.tar.gz |
WT-2873 Refactor CRC32 code (#3000)
* Add --enable-crc32-hardware configuration option (configured on by default), which allows CRC32 hardware support to be turned off.
* Move the CRC32 implementation in software from the x86-specific code to software/checksum.c, leave the x86-specific code in x86/crc32-x86.c.
* Move the pointer to the checksum function from a file static to the WT_PROCESS.cksum field, change the __wt_cksum_init() function to set that field.
* WT-2882 Create CRC32 Hardware implementation for ARM8
* Change "cksum" to "checksum" everywhere (hopefully) no semantic changes.
Diffstat (limited to 'build_posix')
-rw-r--r-- | build_posix/aclocal/options.m4 | 13 | ||||
-rw-r--r-- | build_posix/configure.ac.in | 4 |
2 files changed, 17 insertions, 0 deletions
diff --git a/build_posix/aclocal/options.m4 b/build_posix/aclocal/options.m4 index 5f9b8748df2..1f6a1690279 100644 --- a/build_posix/aclocal/options.m4 +++ b/build_posix/aclocal/options.m4 @@ -47,6 +47,19 @@ AM_CONDITIONAL([HAVE_BUILTIN_EXTENSION_ZLIB], [test "$wt_cv_with_builtin_extension_zlib" = "yes"]) AC_MSG_RESULT($with_builtins) +AH_TEMPLATE( + HAVE_CRC32_HARDWARE, [Define to 1 to configure CRC32 hardware support.]) +AC_MSG_CHECKING(if --enable-crc32-hardware option specified) +AC_ARG_ENABLE(crc32-hardware, + AC_HELP_STRING([--enable-crc32-hardware], + [Enable CRC32 hardware support.]), r=$enableval, r=yes) +case "$r" in +no) wt_cv_enable_crc32_hardware=no;; +*) AC_DEFINE(HAVE_CRC32_HARDWARE) + wt_cv_enable_crc32_hardware=yes;; +esac +AC_MSG_RESULT($wt_cv_enable_crc32_hardware) + AH_TEMPLATE(HAVE_DIAGNOSTIC, [Define to 1 for diagnostic tests.]) AC_MSG_CHECKING(if --enable-diagnostic option specified) AC_ARG_ENABLE(diagnostic, diff --git a/build_posix/configure.ac.in b/build_posix/configure.ac.in index 00aa0bc9f95..cbd9e4e4123 100644 --- a/build_posix/configure.ac.in +++ b/build_posix/configure.ac.in @@ -65,6 +65,10 @@ AS_CASE([$host_cpu], [s390x*], [wt_cv_zseries="yes"], [wt_cv_zseries="no"]) AM_CONDITIONAL([ZSERIES_HOST], [test "$wt_cv_zseries" = "yes"]) +AS_CASE([$host_cpu], + [aarch64*], [wt_cv_arm64="yes"], + [wt_cv_arm64="no"]) +AM_CONDITIONAL([ARM64_HOST], [test "$wt_cv_arm64" = "yes"]) # This is a workaround as part of WT-2459. Currently, clang (v3.7) does not # support compiling the ASM code we have to perform the CRC checks on PowerPC. |