diff options
author | Jack Lloyd <[email protected]> | 2018-10-05 19:23:14 -0400 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2018-10-05 19:23:14 -0400 |
commit | abc8e0a5a18052c158e2b109e6ac2fa8c51dce6a (patch) | |
tree | 823f797b9130c46e83b370d9663207577e2c1ca0 /src/lib/block | |
parent | 89e1c718af537ca504dac681f7a388202bc60cdc (diff) |
Add explicit AVX2 function annotations
Needed for single amalagamation file with AVX2 enabled.
Diffstat (limited to 'src/lib/block')
-rw-r--r-- | src/lib/block/serpent/serpent.cpp | 2 | ||||
-rw-r--r-- | src/lib/block/serpent/serpent_avx2/serpent_avx2.cpp | 6 |
2 files changed, 8 insertions, 0 deletions
diff --git a/src/lib/block/serpent/serpent.cpp b/src/lib/block/serpent/serpent.cpp index 7bdda0f9f..77cf9f32b 100644 --- a/src/lib/block/serpent/serpent.cpp +++ b/src/lib/block/serpent/serpent.cpp @@ -293,4 +293,6 @@ std::string Serpent::provider() const return "base"; } +#undef key_xor + } diff --git a/src/lib/block/serpent/serpent_avx2/serpent_avx2.cpp b/src/lib/block/serpent/serpent_avx2/serpent_avx2.cpp index 92ea909a8..3438440da 100644 --- a/src/lib/block/serpent/serpent_avx2/serpent_avx2.cpp +++ b/src/lib/block/serpent/serpent_avx2/serpent_avx2.cpp @@ -50,6 +50,7 @@ namespace Botan { B0 = B0.rotr<13>(); \ } while(0) +BOTAN_FUNC_ISA("avx2") void Serpent::avx2_encrypt_8(const uint8_t in[128], uint8_t out[128]) const { SIMD_8x32 B0 = SIMD_8x32::load_le(in); @@ -99,6 +100,7 @@ void Serpent::avx2_encrypt_8(const uint8_t in[128], uint8_t out[128]) const B3.store_le(out + 96); } +BOTAN_FUNC_ISA("avx2") void Serpent::avx2_decrypt_8(const uint8_t in[128], uint8_t out[128]) const { SIMD_8x32 B0 = SIMD_8x32::load_le(in); @@ -152,4 +154,8 @@ void Serpent::avx2_decrypt_8(const uint8_t in[128], uint8_t out[128]) const B3.store_le(out + 96); } +#undef key_xor +#undef transform +#undef i_transform + } |