mirror of
https://github.com/opencv/opencv.git
synced 2026-07-29 15:23:05 +04:00
Merge pull request #27220 from Kumataro:fix24757
imgproc: disable SIMD for compareHist(INTERSECT) if f64 is unsupported #27220 Close https://github.com/opencv/opencv/issues/24757 ### Pull Request Readiness Checklist See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request - [x] I agree to contribute to the project under Apache 2 License. - [x] To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV - [x] The PR is proposed to the proper branch - [x] There is a reference to the original bug report and related work - [x] There is accuracy test, performance test and test data in opencv_extra repository, if applicable Patch to opencv_extra has the same branch name. - [ ] The feature is well documented and sample code can be built with the project CMake
This commit is contained in:
@@ -2132,7 +2132,8 @@ double cv::compareHist( InputArray _H1, InputArray _H2, int method )
|
||||
v_result = v_add(v_result, v_add(v_cvt_f64(v_src), v_cvt_f64_high(v_src)));
|
||||
}
|
||||
result += v_reduce_sum(v_result);
|
||||
#elif CV_SIMD
|
||||
#elif CV_SIMD && 0 // Disable vectorization for CV_COMP_INTERSECT if f64 is unsupported due to low precision
|
||||
// See https://github.com/opencv/opencv/issues/24757
|
||||
v_float32 v_result = vx_setzero_f32();
|
||||
for (; j <= len - VTraits<v_float32>::vlanes(); j += VTraits<v_float32>::vlanes())
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user