diff --git a/src/dsp/yuv_mips32.c b/src/dsp/yuv_mips32.c index 4746ff33..80b9ba3c 100644 --- a/src/dsp/yuv_mips32.c +++ b/src/dsp/yuv_mips32.c @@ -84,17 +84,21 @@ ROW_FUNC(YuvToBgraRow, 4, 2, 1, 0, 3) #undef ROW_FUNC -#endif // WEBP_USE_MIPS32 - //------------------------------------------------------------------------------ +// Entry point extern void WebPInitSamplersMIPS32(void); WEBP_TSAN_IGNORE_FUNCTION void WebPInitSamplersMIPS32(void) { -#if defined(WEBP_USE_MIPS32) WebPSamplers[MODE_RGB] = YuvToRgbRow; WebPSamplers[MODE_RGBA] = YuvToRgbaRow; WebPSamplers[MODE_BGR] = YuvToBgrRow; WebPSamplers[MODE_BGRA] = YuvToBgraRow; -#endif // WEBP_USE_MIPS32 } + +#else // !WEBP_USE_MIPS32 + +extern void WebPInitSamplersMIPS32(void); +WEBP_TSAN_IGNORE_FUNCTION void WebPInitSamplersMIPS32(void) {} + +#endif // WEBP_USE_MIPS32 diff --git a/src/dsp/yuv_mips_dsp_r2.c b/src/dsp/yuv_mips_dsp_r2.c index 9cfa50b4..8f6caa93 100644 --- a/src/dsp/yuv_mips_dsp_r2.c +++ b/src/dsp/yuv_mips_dsp_r2.c @@ -115,17 +115,21 @@ ROW_FUNC(YuvToBgraRow, 4, 2, 1, 0, 3) #undef ROW_FUNC_PART_2 #undef ROW_FUNC_PART_1 -#endif // WEBP_USE_MIPS_DSP_R2 - //------------------------------------------------------------------------------ +// Entry point extern void WebPInitSamplersMIPSdspR2(void); WEBP_TSAN_IGNORE_FUNCTION void WebPInitSamplersMIPSdspR2(void) { -#if defined(WEBP_USE_MIPS_DSP_R2) WebPSamplers[MODE_RGB] = YuvToRgbRow; WebPSamplers[MODE_RGBA] = YuvToRgbaRow; WebPSamplers[MODE_BGR] = YuvToBgrRow; WebPSamplers[MODE_BGRA] = YuvToBgraRow; -#endif // WEBP_USE_MIPS_DSP_R2 } + +#else // !WEBP_USE_MIPS_DSP_R2 + +extern void WebPInitSamplersMIPSdspR2(void); +WEBP_TSAN_IGNORE_FUNCTION void WebPInitSamplersMIPSdspR2(void) {} + +#endif // WEBP_USE_MIPS_DSP_R2 diff --git a/src/dsp/yuv_sse2.c b/src/dsp/yuv_sse2.c index 08cebd07..d7671ce3 100644 --- a/src/dsp/yuv_sse2.c +++ b/src/dsp/yuv_sse2.c @@ -304,19 +304,22 @@ static void YuvToBgrRowSSE2(const uint8_t* y, } } -#endif // WEBP_USE_SSE2 - //------------------------------------------------------------------------------ // Entry point extern void WebPInitSamplersSSE2(void); WEBP_TSAN_IGNORE_FUNCTION void WebPInitSamplersSSE2(void) { -#if defined(WEBP_USE_SSE2) WebPSamplers[MODE_RGB] = YuvToRgbRowSSE2; WebPSamplers[MODE_RGBA] = YuvToRgbaRowSSE2; WebPSamplers[MODE_BGR] = YuvToBgrRowSSE2; WebPSamplers[MODE_BGRA] = YuvToBgraRowSSE2; WebPSamplers[MODE_ARGB] = YuvToArgbRowSSE2; -#endif // WEBP_USE_SSE2 } + +#else // !WEBP_USE_SSE2 + +extern void WebPInitSamplersSSE2(void); +WEBP_TSAN_IGNORE_FUNCTION void WebPInitSamplersSSE2(void) {} + +#endif // WEBP_USE_SSE2