Skip to content

Commit 0bec773

Browse files
author
Steven Noonan
committed
crypto_25519_donna: don't use sse2 on foreign architectures
Signed-off-by: Steven Noonan <[email protected]>
1 parent 943c26c commit 0bec773

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/common/crypto_25519_donna.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,14 +102,16 @@ static bool CheckSSE2Technology()
102102
return false;
103103
#elif defined( _M_X64 ) || defined (__x86_64__)
104104
return true;
105-
#else
105+
#elif defined( _M_IX86 ) || defined( __i386__ )
106106
static int result = -1;
107107
if ( result < 0 )
108108
{
109109
uint32 eax,ebx,edx,unused;
110110
result = cpuid(1,eax,ebx,unused,edx) && ( ( edx & 0x04000000 ) != 0 ) ? 1 : 0;
111111
}
112112
return result > 0;
113+
#else
114+
return false;
113115
#endif
114116
}
115117

0 commit comments

Comments
 (0)