aboutsummaryrefslogtreecommitdiff
path: root/src/crypto/sha256.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/crypto/sha256.cpp')
-rw-r--r--src/crypto/sha256.cpp16
1 files changed, 4 insertions, 12 deletions
diff --git a/src/crypto/sha256.cpp b/src/crypto/sha256.cpp
index cde543e68c..196f81ea16 100644
--- a/src/crypto/sha256.cpp
+++ b/src/crypto/sha256.cpp
@@ -586,17 +586,9 @@ std::string SHA256AutoDetect()
bool have_sse4 = false;
bool have_xsave = false;
bool have_avx = false;
- bool have_avx2 = false;
- bool have_x86_shani = false;
- bool enabled_avx = false;
-
- (void)AVXEnabled;
- (void)have_sse4;
- (void)have_avx;
- (void)have_xsave;
- (void)have_avx2;
- (void)have_x86_shani;
- (void)enabled_avx;
+ [[maybe_unused]] bool have_avx2 = false;
+ [[maybe_unused]] bool have_x86_shani = false;
+ [[maybe_unused]] bool enabled_avx = false;
uint32_t eax, ebx, ecx, edx;
GetCPUID(1, 0, eax, ebx, ecx, edx);
@@ -641,7 +633,7 @@ std::string SHA256AutoDetect()
ret += ",avx2(8way)";
}
#endif
-#endif
+#endif // defined(USE_ASM) && defined(HAVE_GETCPUID)
#if defined(ENABLE_ARM_SHANI) && !defined(BUILD_BITCOIN_INTERNAL)
bool have_arm_shani = false;