X-Git-Url: https://git.distorted.org.uk/~mdw/catacomb/blobdiff_plain/c2603631178b688a6f8ce5eccd461e74718058d5..6a024d24d97cb5d42c0091571735475b849f59f4:/symm/chacha.c diff --git a/symm/chacha.c b/symm/chacha.c index 2dcb1253..71522003 100644 --- a/symm/chacha.c +++ b/symm/chacha.c @@ -78,6 +78,10 @@ extern core__functype chacha_core_x86ish_sse2; extern core__functype chacha_core_arm_neon; #endif +#if CPUFAM_ARM64 +extern core__functype chacha_core_arm64; +#endif + static core__functype *pick_core(void) { #if CPUFAM_X86 || CPUFAM_AMD64 @@ -88,6 +92,9 @@ static core__functype *pick_core(void) DISPATCH_PICK_COND(chacha_core, chacha_core_arm_neon, cpu_feature_p(CPUFEAT_ARM_NEON)); #endif +#if CPUFAM_ARM64 + DISPATCH_PICK_COND(chacha_core, chacha_core_arm64, 1); +#endif DISPATCH_PICK_FALLBACK(chacha_core, simple_core); } @@ -583,7 +590,7 @@ CHACHA_VARS(DEFGCIPHER) \ const gccipher xchacha##r = { \ "xchacha" #r, chacha_keysz, \ - CHACHA_NONCESZ, gxinit_##r \ + XCHACHA_NONCESZ, gxinit_##r \ }; CHACHA_VARS(DEFGXCIPHER)