From 4679f848c45510531976ebdf32c42b1c27b92960 Mon Sep 17 00:00:00 2001 From: hebin Date: Wed, 29 Jun 2022 15:48:08 +0800 Subject: [PATCH] fix windows compile on avx512 --- source/backend/cpu/x86_x64/avx512/Gemm10_32.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/source/backend/cpu/x86_x64/avx512/Gemm10_32.h b/source/backend/cpu/x86_x64/avx512/Gemm10_32.h index f75935bec..97ef65014 100644 --- a/source/backend/cpu/x86_x64/avx512/Gemm10_32.h +++ b/source/backend/cpu/x86_x64/avx512/Gemm10_32.h @@ -8,6 +8,10 @@ template void _AVX512_MNNPackedMatMulO32FullLoadKernel(float* C, const float* A, const float* B, const size_t* parameter, const float* postParameters, const float* bias) { +#ifdef _MSC_VER +#define _mm_prefetch(ptr, hint) _mm_prefetch((const char*)(ptr), hint) +#endif // _MSC_VER + #define REDUCE_MUL_ADD(ick) \ zmm0 = _mm512_loadu_ps(filterICPtr + (ick * bStride + 0 * AVX512_PACK_C_UNIT)); \ zmm1 = _mm512_loadu_ps(filterICPtr + (ick * bStride + 1 * AVX512_PACK_C_UNIT)); \