From c36482a11ae0c38f19fee960e70ca6bbaedaeefd Mon Sep 17 00:00:00 2001 From: Pauli Oikkonen Date: Thu, 24 Jan 2019 15:25:45 +0200 Subject: [PATCH] Fix bug in 24-wide SAD *facepalm* --- src/strategies/sse41/reg_sad_pow2_widths-sse41.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/strategies/sse41/reg_sad_pow2_widths-sse41.h b/src/strategies/sse41/reg_sad_pow2_widths-sse41.h index d659ee7d..144eef41 100644 --- a/src/strategies/sse41/reg_sad_pow2_widths-sse41.h +++ b/src/strategies/sse41/reg_sad_pow2_widths-sse41.h @@ -204,8 +204,8 @@ static INLINE uint32_t reg_sad_w24(const kvz_pixel * const data1, const kvz_pixe if (height_parity) { __m128i a = _mm_loadu_si128 ((const __m128i *) (data1 + y * stride1)); __m128i b = _mm_loadu_si128 ((const __m128i *) (data2 + y * stride2)); - __m128i c = _mm_cvtsi64_si128(*(const uint64_t *)(data1 + y * stride1 + 8)); - __m128i d = _mm_cvtsi64_si128(*(const uint64_t *)(data2 + y * stride2 + 8)); + __m128i c = _mm_cvtsi64_si128(*(const uint64_t *)(data1 + y * stride1 + 16)); + __m128i d = _mm_cvtsi64_si128(*(const uint64_t *)(data2 + y * stride2 + 16)); __m128i curr_sads_1 = _mm_sad_epu8(a, b); __m128i curr_sads_2 = _mm_sad_epu8(c, d);