diff options
author | Vitaly Chikunov <vt@altlinux.org> | 2020-02-10 08:43:38 +0300 |
---|---|---|
committer | Dmitry Belyavskiy <beldmit@users.noreply.github.com> | 2020-02-10 11:28:23 +0300 |
commit | 053ecb0a582e2dbfba5ddd6dc8dafb5698051ac4 (patch) | |
tree | 00bbae6e92ba2238479f386b104fe9bf454dc1ee | |
parent | 7e6ed644cf97385a95544fcc889e2eb16bcc93ed (diff) | |
download | gost-engine-053ecb0a582e2dbfba5ddd6dc8dafb5698051ac4.zip gost-engine-053ecb0a582e2dbfba5ddd6dc8dafb5698051ac4.tar.gz gost-engine-053ecb0a582e2dbfba5ddd6dc8dafb5698051ac4.tar.bz2 |
elbrus: Treat __e2k__ as __x86_64__ for Streebog
lcc emulates x86_64 SIMD intrinsics, so SSE2 code will work as is. Even
though in benchmarks it is slightly slower than regular implementation
-rw-r--r-- | gosthash2012.c | 2 | ||||
-rw-r--r-- | gosthash2012.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/gosthash2012.c b/gosthash2012.c index 5ec8ec7..60fa436 100644 --- a/gosthash2012.c +++ b/gosthash2012.c @@ -9,7 +9,7 @@ */ #include "gosthash2012.h" -#ifdef __x86_64__ +#if defined(__x86_64__) || defined(__e2k__) # ifdef _MSC_VER # include <intrin.h> # else diff --git a/gosthash2012.h b/gosthash2012.h index 8947ee6..99c9e3d 100644 --- a/gosthash2012.h +++ b/gosthash2012.h @@ -12,7 +12,7 @@ #ifdef __SSE2__ # define __GOST3411_HAS_SSE2__ -# if !defined(__x86_64__) +# if !defined(__x86_64__) && !defined(__e2k__) /* * x86-64 bit Linux and Windows ABIs provide malloc function that returns * 16-byte alignment memory buffers required by SSE load/store instructions. |