Skip to content

Commit 1f00b3b

Browse files
committed
fix(aws-lc): disable AVX512 to reduce binary size by 600k
After replacing aws-gcm with aws-lc AES-GCM implementation, we noticed the binary size increased by 600k. This is mostly due to the AVX512 functions taking a ridiculous amount of space. 0000000002662240 0000000000339921 t aws_lc_0_32_3_aes_gcm_decrypt_avx512 0000000002322304 0000000000339925 t aws_lc_0_32_3_aes_gcm_encrypt_avx512 This commit disables AVX512 support in AWS-LC as we didn't measure any performance penalty. Signed-off-by: Riccardo Mancini <[email protected]>
1 parent b1a1e7b commit 1f00b3b

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

.cargo/config.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,6 @@ git-fetch-with-cli = true
99

1010
[env]
1111
AWS_LC_SYS_NO_JITTER_ENTROPY = "1"
12+
# disable AVX512 as it adds 600k of binary size
13+
# this was only used for MMDS token generation
14+
AWS_LC_SYS_CFLAGS = "-DMY_ASSEMBLER_IS_TOO_OLD_FOR_512AVX"

0 commit comments

Comments
 (0)