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.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/crypto/sha256.cpp b/src/crypto/sha256.cpp
index 36ef6d9a1a..4c7bb6f20f 100644
--- a/src/crypto/sha256.cpp
+++ b/src/crypto/sha256.cpp
@@ -26,13 +26,11 @@
#endif
#if defined(__x86_64__) || defined(__amd64__) || defined(__i386__)
-#if defined(USE_ASM)
namespace sha256_sse4
{
void Transform(uint32_t* s, const unsigned char* chunk, size_t blocks);
}
#endif
-#endif
namespace sha256d64_sse41
{
@@ -574,7 +572,7 @@ bool SelfTest() {
}
#if !defined(DISABLE_OPTIMIZED_SHA256)
-#if defined(USE_ASM) && (defined(__x86_64__) || defined(__amd64__) || defined(__i386__))
+#if (defined(__x86_64__) || defined(__amd64__) || defined(__i386__))
/** Check whether the OS has enabled AVX registers. */
bool AVXEnabled()
{
@@ -597,7 +595,7 @@ std::string SHA256AutoDetect(sha256_implementation::UseImplementation use_implem
TransformD64_8way = nullptr;
#if !defined(DISABLE_OPTIMIZED_SHA256)
-#if defined(USE_ASM) && defined(HAVE_GETCPUID)
+#if defined(HAVE_GETCPUID)
bool have_sse4 = false;
bool have_xsave = false;
bool have_avx = false;
@@ -654,7 +652,7 @@ std::string SHA256AutoDetect(sha256_implementation::UseImplementation use_implem
ret += ",avx2(8way)";
}
#endif
-#endif // defined(USE_ASM) && defined(HAVE_GETCPUID)
+#endif // defined(HAVE_GETCPUID)
#if defined(ENABLE_ARM_SHANI)
bool have_arm_shani = false;