]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
The compilation of ISAL compress in the current code depends on the macro HAVE_NASM_X... 59206/head
authorYao guotao <yaoguot@gmail.com>
Mon, 11 Dec 2023 09:55:22 +0000 (17:55 +0800)
committerYao guotao <guotao6@staff.sina.com>
Wed, 14 Aug 2024 03:26:45 +0000 (11:26 +0800)
fix: https://tracker.ceph.com/issues/63780

Signed-off-by: Yao guotao <yaoguot@gmail.com>
src/compressor/zlib/ZlibCompressor.cc
src/include/config-h.in.cmake

index f37edc70a0f70986e1852f51a6d0050d99b9f326..b25eef488a3059eaab795e44228eac7ed86b735e 100644 (file)
@@ -63,6 +63,14 @@ QatAccel ZlibCompressor::qat_accel;
 ZlibCompressor::ZlibCompressor(CephContext *cct, bool isal)
   : Compressor(COMP_ALG_ZLIB, "zlib"), isal_enabled(isal), cct(cct)
 {
+
+#if !(__x86_64__ && defined(HAVE_NASM_X64_AVX2)) || defined(__aarch64__)
+  if (isal_enabled) {
+    derr << "WARN: ISA-L enabled (compressor_zlib_isal=true) but not supported"
+         << dendl;
+  }
+#endif
+
 #ifdef HAVE_QATZIP
   if (cct->_conf->qat_compressor_enabled && qat_accel.init("zlib"))
     qat_enabled = true;
index c983eff3963709b55747b296e0d6bc7aa4c7677f..91c64da5b838c79dc81c3b97e68f14eb57ee9372 100644 (file)
 /* we have a recent nasm and are x86_64 */
 #cmakedefine HAVE_NASM_X64
 
+/* nasm can also build the isa-l:avx2 */
+#cmakedefine HAVE_NASM_X64_AVX2
+
 /* nasm can also build the isa-l:avx512 */
 #cmakedefine HAVE_NASM_X64_AVX512