rijndael-ssse3: move assembly functions to separate source-file
authorJussi Kivilinna <jussi.kivilinna@iki.fi>
Wed, 4 Jan 2017 17:16:26 +0000 (19:16 +0200)
committerJussi Kivilinna <jussi.kivilinna@iki.fi>
Fri, 6 Jan 2017 10:48:21 +0000 (12:48 +0200)
commit54c57bc49edb5c00e9ed8103cc4837bb72c5e863
tree97954d09f0c27028f68cfd3afde829e3968709b7
parentc59a8ce51ceb9a80169c44ef86a67e95cf8528c3
rijndael-ssse3: move assembly functions to separate source-file

* cipher/Makefile.am: Add 'rinjdael-ssse3-amd64-asm.S'.
* cipher/rinjdael-ssse3-amd64-asm.S: Moved assembly functions
here ...
* cipher/rinjdael-ssse3-amd64.c: ... from this file.
(_gcry_aes_ssse3_enc_preload, _gcry_aes_ssse3_dec_preload)
(_gcry_aes_ssse3_shedule_core, _gcry_aes_ssse3_encrypt_core)
(_gcry_aes_ssse3_decrypt_core): New.
(vpaes_ssse3_prepare_enc, vpaes_ssse3_prepare_dec)
(_gcry_aes_ssse3_do_setkey, _gcry_aes_ssse3_prepare_decryption)
(do_vpaes_ssse3_enc, do_vpaes_ssse3_dec): Update to use external
assembly functions; remove 'aes_const_ptr' variable usage.
(_gcry_aes_ssse3_encrypt, _gcry_aes_ssse3_decrypt)
(_gcry_aes_ssse3_cfb_enc, _gcry_aes_ssse3_cbc_enc)
(_gcry_aes_ssse3_ctr_enc, _gcry_aes_ssse3_cfb_dec)
(_gcry_aes_ssse3_cbc_dec, ssse3_ocb_enc, ssse3_ocb_dec)
(_gcry_aes_ssse3_ocb_auth): Remove 'aes_const_ptr' variable usage.
* configure.ac: Add 'rinjdael-ssse3-amd64-asm.lo'.
--

After this change, libgcrypt can be compiled with -flto optimization
enabled on x86-64.

GnuPG-bug-id: 2882
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>
cipher/Makefile.am
cipher/rijndael-ssse3-amd64-asm.S [new file with mode: 0644]
cipher/rijndael-ssse3-amd64.c
configure.ac