added AVX-512 support to SPECK cipher (#630)

This commit is contained in:
Logan oos Even
2021-02-08 15:27:29 +05:45
committed by GitHub
parent e31fc5f56a
commit aaca1424fd
4 changed files with 241 additions and 8 deletions
+18 -1
View File
@@ -39,7 +39,24 @@
#define SPECK_KEY_BYTES (256/8)
#if defined (__AVX2__) // AVX support -----------------------------------------------------------------------------
#if defined (__AVX512F__) // AVX512 support -----------------------------------------------------------------------
#include <immintrin.h>
#include <string.h> /* memcpy() */
#define u512 __m512i
#define SPECK_ALIGNED_CTX 64
typedef struct {
u512 rk[34];
u64 key[34];
u32 keysize;
} speck_context_t;
#elif defined (__AVX2__) // AVX2 support --------------------------------------------------------------------------
#include <immintrin.h>