mirror of
https://github.com/opencv/opencv.git
synced 2025-07-29 17:02:49 +08:00
SSE2 : use _mm_cvtpd_epi32 when converting from CV_64F to CV_32S (#10987)
* SSE2 : use _mm_cvtpd_epi32 when converting from CV_64F to CV_32S * No need to define a new universal intrinsic
This commit is contained in:
parent
ee180d5b41
commit
c219f97f48
@ -770,10 +770,10 @@ struct Cvt_SIMD<double, int>
|
|||||||
int cWidth = v_float64x2::nlanes;
|
int cWidth = v_float64x2::nlanes;
|
||||||
for (; x <= width - cWidth * 2; x += cWidth * 2)
|
for (; x <= width - cWidth * 2; x += cWidth * 2)
|
||||||
{
|
{
|
||||||
v_float32x4 v_src0 = v_cvt_f32(v_load(src + x));
|
v_int32x4 v_src0 = v_round(v_load(src + x));
|
||||||
v_float32x4 v_src1 = v_cvt_f32(v_load(src + x + cWidth));
|
v_int32x4 v_src1 = v_round(v_load(src + x + cWidth));
|
||||||
|
|
||||||
v_store(dst + x, v_round(v_combine_low(v_src0, v_src1)));
|
v_store(dst + x, v_combine_low(v_src0, v_src1));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return x;
|
return x;
|
||||||
|
Loading…
Reference in New Issue
Block a user