diff options
author | Jussi Kivilinna <jussi.kivilinna@iki.fi> | 2018-11-20 21:16:08 +0200 |
---|---|---|
committer | Jussi Kivilinna <jussi.kivilinna@iki.fi> | 2018-11-20 21:16:08 +0200 |
commit | 9d9c4fd18b445ff414d11678285d54af3afdb222 (patch) | |
tree | a2077fbc680917f68f0c310d75953c8b6c9bf3e9 /cipher/cipher-gcm-intel-pclmul.c | |
parent | b42de67f34871a2520cfe370af513f2aab6e4f75 (diff) | |
download | libgcrypt-9d9c4fd18b445ff414d11678285d54af3afdb222.tar.gz |
Add clang target pragma for mixed C/assembly x86-64 implementations
* cipher/cipher-gcm-intel-pclmul.c: Add target 'no-sse' attribute
pragma for clang.
* cipher/crc-intel-pclmul.c: Ditto.
* cipher/rijndael-aesni.c: Ditto.
* cipher/rijndael-ssse3-amd64.c: Ditto.
* cipher/sha1-intel-shaext.c: Ditto.
* cipher/sha256-intel-shaext.c: Ditto.
--
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>
Diffstat (limited to 'cipher/cipher-gcm-intel-pclmul.c')
-rw-r--r-- | cipher/cipher-gcm-intel-pclmul.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/cipher/cipher-gcm-intel-pclmul.c b/cipher/cipher-gcm-intel-pclmul.c index 0f26277a..60ae7aa9 100644 --- a/cipher/cipher-gcm-intel-pclmul.c +++ b/cipher/cipher-gcm-intel-pclmul.c @@ -37,6 +37,9 @@ /* Prevent compiler from issuing SSE instructions between asm blocks. */ # pragma GCC target("no-sse") #endif +#if __clang__ +# pragma clang attribute push (__attribute__((target("no-sse"))), apply_to = function) +#endif /* @@ -474,4 +477,8 @@ _gcry_ghash_intel_pclmul (gcry_cipher_hd_t c, byte *result, const byte *buf, return 0; } +#if __clang__ +# pragma clang attribute pop +#endif + #endif /* GCM_USE_INTEL_PCLMUL */ |