Linux: Fix build error under ARM64

This commit is contained in:
Mounir IDRASSI 2025-06-26 17:07:16 +09:00
parent 176d1c8bff
commit 84f7ec5250
No known key found for this signature in database
GPG key ID: D6AC14B0469F1B57
2 changed files with 8 additions and 5 deletions

View file

@ -21,6 +21,8 @@
#include "argon2.h"
#include "core.h"
#if defined(__AVX2__)
#include "blake2/blake2.h"
#include "blake2/blamka-round-opt.h"
@ -33,7 +35,6 @@
* @param with_xor Whether to XOR into the new block (1) or just overwrite (0)
* @pre all block pointers must be valid
*/
#if defined(__AVX2__)
static void fill_block(__m256i *state, const block *ref_block,
block *next_block, int with_xor) {
__m256i block_XY[ARGON2_HWORDS_IN_BLOCK];
@ -194,7 +195,7 @@ void fill_segment_avx2(const argon2_instance_t *instance,
#else
void fill_segment_avx2(const argon2_instance_t* instance,
argon2_position_t position) {
UNREFERENCED_PARAMETER(instance);
UNREFERENCED_PARAMETER(position);
(void)instance;
(void)position;
}
#endif

View file

@ -20,12 +20,12 @@
#include "argon2.h"
#include "core.h"
#if CRYPTOPP_BOOL_SSE2_INTRINSICS_AVAILABLE
#include "blake2/blake2.h"
#include "blake2/blamka-round-opt.h"
#include "Crypto/config.h"
#if CRYPTOPP_BOOL_SSE2_INTRINSICS_AVAILABLE
/*
* Function fills a new memory block and optionally XORs the old block over the new one.
* Memory must be initialized.
@ -198,5 +198,7 @@ void fill_segment_sse2(const argon2_instance_t *instance,
#else
void fill_segment_sse2(const argon2_instance_t* instance,
argon2_position_t position) {
(void)instance;
(void)position;
}
#endif