Skip to content

Commit fb4533b

Browse files
committed
Port the GCC target changes for aarch64 to aegis
Fixes #1313
1 parent b795a93 commit fb4533b

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

src/libsodium/crypto_aead/aegis128l/aegis128l_armcrypto.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,12 @@
2020
#ifdef __clang__
2121
#pragma clang attribute push(__attribute__((target("neon,crypto,aes"))), apply_to = function)
2222
#elif defined(__GNUC__)
23-
#pragma GCC target("neon,crypto,aes")
23+
#pragma GCC target("+simd+crypto")
2424
#endif
2525

26+
#ifndef __ARM_FEATURE_CRYPTO
27+
#define __ARM_FEATURE_CRYPTO 1
28+
#endif
2629
#ifndef __ARM_FEATURE_AES
2730
#define __ARM_FEATURE_AES 1
2831
#endif

src/libsodium/crypto_aead/aegis256/aegis256_armcrypto.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,12 @@
2020
#ifdef __clang__
2121
#pragma clang attribute push(__attribute__((target("neon,crypto,aes"))), apply_to = function)
2222
#elif defined(__GNUC__)
23-
#pragma GCC target("neon,crypto,aes")
23+
#pragma GCC target("+simd+crypto")
2424
#endif
2525

26+
#ifndef __ARM_FEATURE_CRYPTO
27+
#define __ARM_FEATURE_CRYPTO 1
28+
#endif
2629
#ifndef __ARM_FEATURE_AES
2730
#define __ARM_FEATURE_AES 1
2831
#endif

0 commit comments

Comments
 (0)