From 30aa3c9266c76d4d7d797eec9204b9d84663ec58 Mon Sep 17 00:00:00 2001 From: ekharkov Date: Mon, 2 Mar 2026 01:47:14 -0800 Subject: [PATCH] Revert "Disable IPP with AVX512 in cv::compare because of performance regression" --- modules/core/src/arithm_ipp.hpp | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/modules/core/src/arithm_ipp.hpp b/modules/core/src/arithm_ipp.hpp index 33ade50918..ed722113a7 100644 --- a/modules/core/src/arithm_ipp.hpp +++ b/modules/core/src/arithm_ipp.hpp @@ -283,40 +283,24 @@ inline IppCmpOp arithm_ipp_convert_cmp(int cmpop) inline int arithm_ipp_cmp8u(const uchar* src1, size_t step1, const uchar* src2, size_t step2, uchar* dst, size_t step, int width, int height, int cmpop) { - // perf regression with AVX512: https://github.com/opencv/opencv/issues/28251 - if (ippCPUID_AVX512F&cv::ipp::getIppFeatures()) - return 0; - ARITHM_IPP_CMP(ippiCompare_8u_C1R, src1, (int)step1, src2, (int)step2, dst, (int)step, ippiSize(width, height)); } inline int arithm_ipp_cmp16u(const ushort* src1, size_t step1, const ushort* src2, size_t step2, uchar* dst, size_t step, int width, int height, int cmpop) { - // perf regression with AVX512: https://github.com/opencv/opencv/issues/28251 - if (ippCPUID_AVX512F&cv::ipp::getIppFeatures()) - return 0; - ARITHM_IPP_CMP(ippiCompare_16u_C1R, src1, (int)step1, src2, (int)step2, dst, (int)step, ippiSize(width, height)); } inline int arithm_ipp_cmp16s(const short* src1, size_t step1, const short* src2, size_t step2, uchar* dst, size_t step, int width, int height, int cmpop) { - // perf regression with AVX512: https://github.com/opencv/opencv/issues/28251 - if (ippCPUID_AVX512F&cv::ipp::getIppFeatures()) - return 0; - ARITHM_IPP_CMP(ippiCompare_16s_C1R, src1, (int)step1, src2, (int)step2, dst, (int)step, ippiSize(width, height)); } inline int arithm_ipp_cmp32f(const float* src1, size_t step1, const float* src2, size_t step2, uchar* dst, size_t step, int width, int height, int cmpop) { - // perf regression with AVX512: https://github.com/opencv/opencv/issues/28251 - if (ippCPUID_AVX512F&cv::ipp::getIppFeatures()) - return 0; - ARITHM_IPP_CMP(ippiCompare_32f_C1R, src1, (int)step1, src2, (int)step2, dst, (int)step, ippiSize(width, height)); }