diff --git a/.CMake/alg_support.cmake b/.CMake/alg_support.cmake index 86199b895c..bc10aaff51 100644 --- a/.CMake/alg_support.cmake +++ b/.CMake/alg_support.cmake @@ -432,6 +432,7 @@ if(OQS_MINIMAL_BUILD) # Case 3, platform specific string(REPLACE "_aesni" "" _var_base ${_var}) string(REPLACE "_avx2" "" _var_base ${_var_base}) + string(REPLACE "_avx" "" _var_base ${_var_base}) if(${_var}_AVAILABLE) if(${_var_base}X STREQUAL ${default_kem_switch}X OR ${_var_base}X STREQUAL ${default_sig_switch}X) diff --git a/.CMake/compiler_opts.cmake b/.CMake/compiler_opts.cmake index c31e2d0291..66ea448616 100644 --- a/.CMake/compiler_opts.cmake +++ b/.CMake/compiler_opts.cmake @@ -16,8 +16,6 @@ if(CMAKE_C_COMPILER_ID MATCHES "Clang") option(OQS_USE_CPU_EXTENSIONS "Enable compile and run-time support for CPU extensions such as AVX2, SSE, etc." ON) if(OQS_USE_CPU_EXTENSIONS) include(${CMAKE_CURRENT_LIST_DIR}/gcc_clang_intrinsics.cmake) - # to allow McEliece AVX code to compile with clang9: - add_compile_options(-Wno-language-extension-token) endif() if(OQS_DEBUG_BUILD) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index ed96b647b4..a2ffd4a364 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -77,10 +77,6 @@ if(OQS_USE_OPENSSL) target_link_libraries(oqs PUBLIC ${OPENSSL_CRYPTO_LIBRARY}) target_include_directories(oqs PUBLIC ${OPENSSL_INCLUDE_DIR}) endif() -if (CMAKE_SYSTEM_NAME MATCHES "Linux" AND OQS_USE_AVX2_INSTRUCTIONS AND OQS_ENABLE_KEM_CLASSIC_MCELIECE) - # hack to enable McEliece' AVX symbols to link on Linux -target_link_options(oqs PRIVATE -Wl,-Bsymbolic) -endif() set_target_properties(oqs PROPERTIES diff --git a/src/kem/classic_mceliece/CMakeLists.txt b/src/kem/classic_mceliece/CMakeLists.txt index 1b8f58d590..74aaf03897 100644 --- a/src/kem/classic_mceliece/CMakeLists.txt +++ b/src/kem/classic_mceliece/CMakeLists.txt @@ -17,6 +17,7 @@ if(OQS_ENABLE_KEM_classic_mceliece_348864_avx) target_include_directories(classic_mceliece_348864_avx PRIVATE ${CMAKE_CURRENT_LIST_DIR}/pqclean_mceliece348864_avx) target_include_directories(classic_mceliece_348864_avx PRIVATE ${PROJECT_SOURCE_DIR}/src/common/pqclean_shims) target_compile_options(classic_mceliece_348864_avx PRIVATE -mavx2 -mpopcnt) + target_compile_options(classic_mceliece_348864_avx PRIVATE -Wno-language-extension-token) set(_CLASSIC_MCELIECE_OBJS ${_CLASSIC_MCELIECE_OBJS} $) endif() @@ -32,6 +33,7 @@ if(OQS_ENABLE_KEM_classic_mceliece_348864f_avx) target_include_directories(classic_mceliece_348864f_avx PRIVATE ${CMAKE_CURRENT_LIST_DIR}/pqclean_mceliece348864f_avx) target_include_directories(classic_mceliece_348864f_avx PRIVATE ${PROJECT_SOURCE_DIR}/src/common/pqclean_shims) target_compile_options(classic_mceliece_348864f_avx PRIVATE -mavx2 -mpopcnt -mbmi) + target_compile_options(classic_mceliece_348864f_avx PRIVATE -Wno-language-extension-token) set(_CLASSIC_MCELIECE_OBJS ${_CLASSIC_MCELIECE_OBJS} $) endif() @@ -47,6 +49,7 @@ if(OQS_ENABLE_KEM_classic_mceliece_460896_avx) target_include_directories(classic_mceliece_460896_avx PRIVATE ${CMAKE_CURRENT_LIST_DIR}/pqclean_mceliece460896_avx) target_include_directories(classic_mceliece_460896_avx PRIVATE ${PROJECT_SOURCE_DIR}/src/common/pqclean_shims) target_compile_options(classic_mceliece_460896_avx PRIVATE -mavx2 -mpopcnt) + target_compile_options(classic_mceliece_460896_avx PRIVATE -Wno-language-extension-token) set(_CLASSIC_MCELIECE_OBJS ${_CLASSIC_MCELIECE_OBJS} $) endif() @@ -62,6 +65,7 @@ if(OQS_ENABLE_KEM_classic_mceliece_460896f_avx) target_include_directories(classic_mceliece_460896f_avx PRIVATE ${CMAKE_CURRENT_LIST_DIR}/pqclean_mceliece460896f_avx) target_include_directories(classic_mceliece_460896f_avx PRIVATE ${PROJECT_SOURCE_DIR}/src/common/pqclean_shims) target_compile_options(classic_mceliece_460896f_avx PRIVATE -mavx2 -mbmi -mpopcnt) + target_compile_options(classic_mceliece_460896f_avx PRIVATE -Wno-language-extension-token) set(_CLASSIC_MCELIECE_OBJS ${_CLASSIC_MCELIECE_OBJS} $) endif() @@ -77,6 +81,7 @@ if(OQS_ENABLE_KEM_classic_mceliece_6688128_avx) target_include_directories(classic_mceliece_6688128_avx PRIVATE ${CMAKE_CURRENT_LIST_DIR}/pqclean_mceliece6688128_avx) target_include_directories(classic_mceliece_6688128_avx PRIVATE ${PROJECT_SOURCE_DIR}/src/common/pqclean_shims) target_compile_options(classic_mceliece_6688128_avx PRIVATE -mavx2 -mpopcnt) + target_compile_options(classic_mceliece_6688128_avx PRIVATE -Wno-language-extension-token) set(_CLASSIC_MCELIECE_OBJS ${_CLASSIC_MCELIECE_OBJS} $) endif() @@ -92,6 +97,7 @@ if(OQS_ENABLE_KEM_classic_mceliece_6688128f_avx) target_include_directories(classic_mceliece_6688128f_avx PRIVATE ${CMAKE_CURRENT_LIST_DIR}/pqclean_mceliece6688128f_avx) target_include_directories(classic_mceliece_6688128f_avx PRIVATE ${PROJECT_SOURCE_DIR}/src/common/pqclean_shims) target_compile_options(classic_mceliece_6688128f_avx PRIVATE -mavx2 -mbmi -mpopcnt) + target_compile_options(classic_mceliece_6688128f_avx PRIVATE -Wno-language-extension-token) set(_CLASSIC_MCELIECE_OBJS ${_CLASSIC_MCELIECE_OBJS} $) endif() @@ -107,6 +113,7 @@ if(OQS_ENABLE_KEM_classic_mceliece_6960119_avx) target_include_directories(classic_mceliece_6960119_avx PRIVATE ${CMAKE_CURRENT_LIST_DIR}/pqclean_mceliece6960119_avx) target_include_directories(classic_mceliece_6960119_avx PRIVATE ${PROJECT_SOURCE_DIR}/src/common/pqclean_shims) target_compile_options(classic_mceliece_6960119_avx PRIVATE -mavx2 -mpopcnt) + target_compile_options(classic_mceliece_6960119_avx PRIVATE -Wno-language-extension-token) set(_CLASSIC_MCELIECE_OBJS ${_CLASSIC_MCELIECE_OBJS} $) endif() @@ -122,6 +129,7 @@ if(OQS_ENABLE_KEM_classic_mceliece_6960119f_avx) target_include_directories(classic_mceliece_6960119f_avx PRIVATE ${CMAKE_CURRENT_LIST_DIR}/pqclean_mceliece6960119f_avx) target_include_directories(classic_mceliece_6960119f_avx PRIVATE ${PROJECT_SOURCE_DIR}/src/common/pqclean_shims) target_compile_options(classic_mceliece_6960119f_avx PRIVATE -mavx2 -mbmi -mpopcnt) + target_compile_options(classic_mceliece_6960119f_avx PRIVATE -Wno-language-extension-token) set(_CLASSIC_MCELIECE_OBJS ${_CLASSIC_MCELIECE_OBJS} $) endif() @@ -137,6 +145,7 @@ if(OQS_ENABLE_KEM_classic_mceliece_8192128_avx) target_include_directories(classic_mceliece_8192128_avx PRIVATE ${CMAKE_CURRENT_LIST_DIR}/pqclean_mceliece8192128_avx) target_include_directories(classic_mceliece_8192128_avx PRIVATE ${PROJECT_SOURCE_DIR}/src/common/pqclean_shims) target_compile_options(classic_mceliece_8192128_avx PRIVATE -mavx2 -mpopcnt) + target_compile_options(classic_mceliece_8192128_avx PRIVATE -Wno-language-extension-token) set(_CLASSIC_MCELIECE_OBJS ${_CLASSIC_MCELIECE_OBJS} $) endif() @@ -152,6 +161,7 @@ if(OQS_ENABLE_KEM_classic_mceliece_8192128f_avx) target_include_directories(classic_mceliece_8192128f_avx PRIVATE ${CMAKE_CURRENT_LIST_DIR}/pqclean_mceliece8192128f_avx) target_include_directories(classic_mceliece_8192128f_avx PRIVATE ${PROJECT_SOURCE_DIR}/src/common/pqclean_shims) target_compile_options(classic_mceliece_8192128f_avx PRIVATE -mavx2 -mpopcnt -mbmi) + target_compile_options(classic_mceliece_8192128f_avx PRIVATE -Wno-language-extension-token) set(_CLASSIC_MCELIECE_OBJS ${_CLASSIC_MCELIECE_OBJS} $) endif() diff --git a/src/kem/classic_mceliece/pqclean_mceliece348864_avx/consts.S b/src/kem/classic_mceliece/pqclean_mceliece348864_avx/consts.S index 385ad55a7a..72176eab4b 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece348864_avx/consts.S +++ b/src/kem/classic_mceliece/pqclean_mceliece348864_avx/consts.S @@ -16,6 +16,19 @@ .globl PQCLEAN_MCELIECE348864_AVX_MASK5_0 .globl PQCLEAN_MCELIECE348864_AVX_MASK5_1 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK0_0 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK0_1 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK1_0 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK1_1 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK2_0 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK2_1 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK3_0 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK3_1 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK4_0 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK4_1 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK5_0 +.hidden PQCLEAN_MCELIECE348864_AVX_MASK5_1 + .p2align 5 PQCLEAN_MCELIECE348864_AVX_MASK0_0: .quad 0x5555555555555555, 0x5555555555555555, 0x5555555555555555, 0x5555555555555555 diff --git a/src/kem/classic_mceliece/pqclean_mceliece348864_avx/int32_sort.c b/src/kem/classic_mceliece/pqclean_mceliece348864_avx/int32_sort.c index f984819f1a..56a1f75a20 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece348864_avx/int32_sort.c +++ b/src/kem/classic_mceliece/pqclean_mceliece348864_avx/int32_sort.c @@ -4,8 +4,8 @@ #include typedef __m256i int32x8; -#define int32x8_load(z) _mm256_loadu_si256((__m256i_u *) (z)) -#define int32x8_store(z,i) _mm256_storeu_si256((__m256i_u *) (z),(i)) +#define int32x8_load(z) _mm256_loadu_si256((__m256i *) (z)) +#define int32x8_store(z,i) _mm256_storeu_si256((__m256i *) (z),(i)) #define int32x8_min _mm256_min_epi32 #define int32x8_max _mm256_max_epi32 diff --git a/src/kem/classic_mceliece/pqclean_mceliece348864f_avx/consts.S b/src/kem/classic_mceliece/pqclean_mceliece348864f_avx/consts.S index 63e6defe50..a2251f63e8 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece348864f_avx/consts.S +++ b/src/kem/classic_mceliece/pqclean_mceliece348864f_avx/consts.S @@ -16,6 +16,19 @@ .globl PQCLEAN_MCELIECE348864F_AVX_MASK5_0 .globl PQCLEAN_MCELIECE348864F_AVX_MASK5_1 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK0_0 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK0_1 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK1_0 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK1_1 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK2_0 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK2_1 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK3_0 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK3_1 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK4_0 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK4_1 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK5_0 +.hidden PQCLEAN_MCELIECE348864F_AVX_MASK5_1 + .p2align 5 PQCLEAN_MCELIECE348864F_AVX_MASK0_0: .quad 0x5555555555555555, 0x5555555555555555, 0x5555555555555555, 0x5555555555555555 diff --git a/src/kem/classic_mceliece/pqclean_mceliece348864f_avx/int32_sort.c b/src/kem/classic_mceliece/pqclean_mceliece348864f_avx/int32_sort.c index 3d00867db2..eaa8469578 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece348864f_avx/int32_sort.c +++ b/src/kem/classic_mceliece/pqclean_mceliece348864f_avx/int32_sort.c @@ -4,8 +4,8 @@ #include typedef __m256i int32x8; -#define int32x8_load(z) _mm256_loadu_si256((__m256i_u *) (z)) -#define int32x8_store(z,i) _mm256_storeu_si256((__m256i_u *) (z),(i)) +#define int32x8_load(z) _mm256_loadu_si256((__m256i *) (z)) +#define int32x8_store(z,i) _mm256_storeu_si256((__m256i *) (z),(i)) #define int32x8_min _mm256_min_epi32 #define int32x8_max _mm256_max_epi32 diff --git a/src/kem/classic_mceliece/pqclean_mceliece460896_avx/consts.S b/src/kem/classic_mceliece/pqclean_mceliece460896_avx/consts.S index de62f1b014..712c6073ec 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece460896_avx/consts.S +++ b/src/kem/classic_mceliece/pqclean_mceliece460896_avx/consts.S @@ -16,6 +16,19 @@ .globl PQCLEAN_MCELIECE460896_AVX_MASK5_0 .globl PQCLEAN_MCELIECE460896_AVX_MASK5_1 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK0_0 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK0_1 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK1_0 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK1_1 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK2_0 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK2_1 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK3_0 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK3_1 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK4_0 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK4_1 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK5_0 +.hidden PQCLEAN_MCELIECE460896_AVX_MASK5_1 + .p2align 5 PQCLEAN_MCELIECE460896_AVX_MASK0_0: .quad 0x5555555555555555, 0x5555555555555555, 0x5555555555555555, 0x5555555555555555 diff --git a/src/kem/classic_mceliece/pqclean_mceliece460896_avx/int32_sort.c b/src/kem/classic_mceliece/pqclean_mceliece460896_avx/int32_sort.c index aae917bd0c..4980ea7993 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece460896_avx/int32_sort.c +++ b/src/kem/classic_mceliece/pqclean_mceliece460896_avx/int32_sort.c @@ -4,8 +4,8 @@ #include typedef __m256i int32x8; -#define int32x8_load(z) _mm256_loadu_si256((__m256i_u *) (z)) -#define int32x8_store(z,i) _mm256_storeu_si256((__m256i_u *) (z),(i)) +#define int32x8_load(z) _mm256_loadu_si256((__m256i *) (z)) +#define int32x8_store(z,i) _mm256_storeu_si256((__m256i *) (z),(i)) #define int32x8_min _mm256_min_epi32 #define int32x8_max _mm256_max_epi32 diff --git a/src/kem/classic_mceliece/pqclean_mceliece460896f_avx/consts.S b/src/kem/classic_mceliece/pqclean_mceliece460896f_avx/consts.S index be96319337..d75f18dbfa 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece460896f_avx/consts.S +++ b/src/kem/classic_mceliece/pqclean_mceliece460896f_avx/consts.S @@ -16,6 +16,19 @@ .globl PQCLEAN_MCELIECE460896F_AVX_MASK5_0 .globl PQCLEAN_MCELIECE460896F_AVX_MASK5_1 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK0_0 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK0_1 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK1_0 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK1_1 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK2_0 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK2_1 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK3_0 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK3_1 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK4_0 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK4_1 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK5_0 +.hidden PQCLEAN_MCELIECE460896F_AVX_MASK5_1 + .p2align 5 PQCLEAN_MCELIECE460896F_AVX_MASK0_0: .quad 0x5555555555555555, 0x5555555555555555, 0x5555555555555555, 0x5555555555555555 diff --git a/src/kem/classic_mceliece/pqclean_mceliece460896f_avx/int32_sort.c b/src/kem/classic_mceliece/pqclean_mceliece460896f_avx/int32_sort.c index d8c2b1c8a5..9b6d0786ce 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece460896f_avx/int32_sort.c +++ b/src/kem/classic_mceliece/pqclean_mceliece460896f_avx/int32_sort.c @@ -4,8 +4,8 @@ #include typedef __m256i int32x8; -#define int32x8_load(z) _mm256_loadu_si256((__m256i_u *) (z)) -#define int32x8_store(z,i) _mm256_storeu_si256((__m256i_u *) (z),(i)) +#define int32x8_load(z) _mm256_loadu_si256((__m256i *) (z)) +#define int32x8_store(z,i) _mm256_storeu_si256((__m256i *) (z),(i)) #define int32x8_min _mm256_min_epi32 #define int32x8_max _mm256_max_epi32 diff --git a/src/kem/classic_mceliece/pqclean_mceliece6688128_avx/consts.S b/src/kem/classic_mceliece/pqclean_mceliece6688128_avx/consts.S index 74691b8ceb..9438992a85 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece6688128_avx/consts.S +++ b/src/kem/classic_mceliece/pqclean_mceliece6688128_avx/consts.S @@ -16,6 +16,19 @@ .globl PQCLEAN_MCELIECE6688128_AVX_MASK5_0 .globl PQCLEAN_MCELIECE6688128_AVX_MASK5_1 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK0_0 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK0_1 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK1_0 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK1_1 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK2_0 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK2_1 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK3_0 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK3_1 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK4_0 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK4_1 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK5_0 +.hidden PQCLEAN_MCELIECE6688128_AVX_MASK5_1 + .p2align 5 PQCLEAN_MCELIECE6688128_AVX_MASK0_0: .quad 0x5555555555555555, 0x5555555555555555, 0x5555555555555555, 0x5555555555555555 diff --git a/src/kem/classic_mceliece/pqclean_mceliece6688128_avx/int32_sort.c b/src/kem/classic_mceliece/pqclean_mceliece6688128_avx/int32_sort.c index d55525e73a..e657a2a765 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece6688128_avx/int32_sort.c +++ b/src/kem/classic_mceliece/pqclean_mceliece6688128_avx/int32_sort.c @@ -4,8 +4,8 @@ #include typedef __m256i int32x8; -#define int32x8_load(z) _mm256_loadu_si256((__m256i_u *) (z)) -#define int32x8_store(z,i) _mm256_storeu_si256((__m256i_u *) (z),(i)) +#define int32x8_load(z) _mm256_loadu_si256((__m256i *) (z)) +#define int32x8_store(z,i) _mm256_storeu_si256((__m256i *) (z),(i)) #define int32x8_min _mm256_min_epi32 #define int32x8_max _mm256_max_epi32 diff --git a/src/kem/classic_mceliece/pqclean_mceliece6688128f_avx/consts.S b/src/kem/classic_mceliece/pqclean_mceliece6688128f_avx/consts.S index f9127c38d5..7e26c56756 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece6688128f_avx/consts.S +++ b/src/kem/classic_mceliece/pqclean_mceliece6688128f_avx/consts.S @@ -16,6 +16,19 @@ .globl PQCLEAN_MCELIECE6688128F_AVX_MASK5_0 .globl PQCLEAN_MCELIECE6688128F_AVX_MASK5_1 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK0_0 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK0_1 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK1_0 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK1_1 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK2_0 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK2_1 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK3_0 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK3_1 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK4_0 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK4_1 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK5_0 +.hidden PQCLEAN_MCELIECE6688128F_AVX_MASK5_1 + .p2align 5 PQCLEAN_MCELIECE6688128F_AVX_MASK0_0: .quad 0x5555555555555555, 0x5555555555555555, 0x5555555555555555, 0x5555555555555555 diff --git a/src/kem/classic_mceliece/pqclean_mceliece6688128f_avx/int32_sort.c b/src/kem/classic_mceliece/pqclean_mceliece6688128f_avx/int32_sort.c index f70f51ddab..ecd24d3fa0 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece6688128f_avx/int32_sort.c +++ b/src/kem/classic_mceliece/pqclean_mceliece6688128f_avx/int32_sort.c @@ -4,8 +4,8 @@ #include typedef __m256i int32x8; -#define int32x8_load(z) _mm256_loadu_si256((__m256i_u *) (z)) -#define int32x8_store(z,i) _mm256_storeu_si256((__m256i_u *) (z),(i)) +#define int32x8_load(z) _mm256_loadu_si256((__m256i *) (z)) +#define int32x8_store(z,i) _mm256_storeu_si256((__m256i *) (z),(i)) #define int32x8_min _mm256_min_epi32 #define int32x8_max _mm256_max_epi32 diff --git a/src/kem/classic_mceliece/pqclean_mceliece6960119_avx/consts.S b/src/kem/classic_mceliece/pqclean_mceliece6960119_avx/consts.S index e4abaf6185..9880cbf94a 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece6960119_avx/consts.S +++ b/src/kem/classic_mceliece/pqclean_mceliece6960119_avx/consts.S @@ -16,6 +16,19 @@ .globl PQCLEAN_MCELIECE6960119_AVX_MASK5_0 .globl PQCLEAN_MCELIECE6960119_AVX_MASK5_1 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK0_0 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK0_1 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK1_0 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK1_1 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK2_0 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK2_1 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK3_0 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK3_1 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK4_0 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK4_1 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK5_0 +.hidden PQCLEAN_MCELIECE6960119_AVX_MASK5_1 + .p2align 5 PQCLEAN_MCELIECE6960119_AVX_MASK0_0: .quad 0x5555555555555555, 0x5555555555555555, 0x5555555555555555, 0x5555555555555555 diff --git a/src/kem/classic_mceliece/pqclean_mceliece6960119_avx/int32_sort.c b/src/kem/classic_mceliece/pqclean_mceliece6960119_avx/int32_sort.c index 02087a3e4f..1a3264e777 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece6960119_avx/int32_sort.c +++ b/src/kem/classic_mceliece/pqclean_mceliece6960119_avx/int32_sort.c @@ -4,8 +4,8 @@ #include typedef __m256i int32x8; -#define int32x8_load(z) _mm256_loadu_si256((__m256i_u *) (z)) -#define int32x8_store(z,i) _mm256_storeu_si256((__m256i_u *) (z),(i)) +#define int32x8_load(z) _mm256_loadu_si256((__m256i *) (z)) +#define int32x8_store(z,i) _mm256_storeu_si256((__m256i *) (z),(i)) #define int32x8_min _mm256_min_epi32 #define int32x8_max _mm256_max_epi32 diff --git a/src/kem/classic_mceliece/pqclean_mceliece6960119f_avx/consts.S b/src/kem/classic_mceliece/pqclean_mceliece6960119f_avx/consts.S index a3096c1f0b..ef2ee0ff73 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece6960119f_avx/consts.S +++ b/src/kem/classic_mceliece/pqclean_mceliece6960119f_avx/consts.S @@ -16,6 +16,19 @@ .globl PQCLEAN_MCELIECE6960119F_AVX_MASK5_0 .globl PQCLEAN_MCELIECE6960119F_AVX_MASK5_1 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK0_0 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK0_1 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK1_0 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK1_1 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK2_0 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK2_1 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK3_0 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK3_1 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK4_0 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK4_1 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK5_0 +.hidden PQCLEAN_MCELIECE6960119F_AVX_MASK5_1 + .p2align 5 PQCLEAN_MCELIECE6960119F_AVX_MASK0_0: .quad 0x5555555555555555, 0x5555555555555555, 0x5555555555555555, 0x5555555555555555 diff --git a/src/kem/classic_mceliece/pqclean_mceliece6960119f_avx/int32_sort.c b/src/kem/classic_mceliece/pqclean_mceliece6960119f_avx/int32_sort.c index 73bf75a2d6..2bafa18e89 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece6960119f_avx/int32_sort.c +++ b/src/kem/classic_mceliece/pqclean_mceliece6960119f_avx/int32_sort.c @@ -4,8 +4,8 @@ #include typedef __m256i int32x8; -#define int32x8_load(z) _mm256_loadu_si256((__m256i_u *) (z)) -#define int32x8_store(z,i) _mm256_storeu_si256((__m256i_u *) (z),(i)) +#define int32x8_load(z) _mm256_loadu_si256((__m256i *) (z)) +#define int32x8_store(z,i) _mm256_storeu_si256((__m256i *) (z),(i)) #define int32x8_min _mm256_min_epi32 #define int32x8_max _mm256_max_epi32 diff --git a/src/kem/classic_mceliece/pqclean_mceliece8192128_avx/consts.S b/src/kem/classic_mceliece/pqclean_mceliece8192128_avx/consts.S index e34172eab8..cdf5cbcde4 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece8192128_avx/consts.S +++ b/src/kem/classic_mceliece/pqclean_mceliece8192128_avx/consts.S @@ -16,6 +16,19 @@ .globl PQCLEAN_MCELIECE8192128_AVX_MASK5_0 .globl PQCLEAN_MCELIECE8192128_AVX_MASK5_1 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK0_0 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK0_1 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK1_0 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK1_1 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK2_0 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK2_1 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK3_0 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK3_1 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK4_0 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK4_1 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK5_0 +.hidden PQCLEAN_MCELIECE8192128_AVX_MASK5_1 + .p2align 5 PQCLEAN_MCELIECE8192128_AVX_MASK0_0: .quad 0x5555555555555555, 0x5555555555555555, 0x5555555555555555, 0x5555555555555555 diff --git a/src/kem/classic_mceliece/pqclean_mceliece8192128_avx/int32_sort.c b/src/kem/classic_mceliece/pqclean_mceliece8192128_avx/int32_sort.c index 0e11f1c4c0..5bace82e1e 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece8192128_avx/int32_sort.c +++ b/src/kem/classic_mceliece/pqclean_mceliece8192128_avx/int32_sort.c @@ -4,8 +4,8 @@ #include typedef __m256i int32x8; -#define int32x8_load(z) _mm256_loadu_si256((__m256i_u *) (z)) -#define int32x8_store(z,i) _mm256_storeu_si256((__m256i_u *) (z),(i)) +#define int32x8_load(z) _mm256_loadu_si256((__m256i *) (z)) +#define int32x8_store(z,i) _mm256_storeu_si256((__m256i *) (z),(i)) #define int32x8_min _mm256_min_epi32 #define int32x8_max _mm256_max_epi32 diff --git a/src/kem/classic_mceliece/pqclean_mceliece8192128f_avx/consts.S b/src/kem/classic_mceliece/pqclean_mceliece8192128f_avx/consts.S index 57ba3d8b6e..b495465a8a 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece8192128f_avx/consts.S +++ b/src/kem/classic_mceliece/pqclean_mceliece8192128f_avx/consts.S @@ -16,6 +16,19 @@ .globl PQCLEAN_MCELIECE8192128F_AVX_MASK5_0 .globl PQCLEAN_MCELIECE8192128F_AVX_MASK5_1 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK0_0 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK0_1 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK1_0 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK1_1 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK2_0 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK2_1 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK3_0 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK3_1 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK4_0 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK4_1 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK5_0 +.hidden PQCLEAN_MCELIECE8192128F_AVX_MASK5_1 + .p2align 5 PQCLEAN_MCELIECE8192128F_AVX_MASK0_0: .quad 0x5555555555555555, 0x5555555555555555, 0x5555555555555555, 0x5555555555555555 diff --git a/src/kem/classic_mceliece/pqclean_mceliece8192128f_avx/int32_sort.c b/src/kem/classic_mceliece/pqclean_mceliece8192128f_avx/int32_sort.c index a35e886e20..6c0bd81f3b 100644 --- a/src/kem/classic_mceliece/pqclean_mceliece8192128f_avx/int32_sort.c +++ b/src/kem/classic_mceliece/pqclean_mceliece8192128f_avx/int32_sort.c @@ -4,8 +4,8 @@ #include typedef __m256i int32x8; -#define int32x8_load(z) _mm256_loadu_si256((__m256i_u *) (z)) -#define int32x8_store(z,i) _mm256_storeu_si256((__m256i_u *) (z),(i)) +#define int32x8_load(z) _mm256_loadu_si256((__m256i *) (z)) +#define int32x8_store(z,i) _mm256_storeu_si256((__m256i *) (z),(i)) #define int32x8_min _mm256_min_epi32 #define int32x8_max _mm256_max_epi32