summaryrefslogtreecommitdiffstats
path: root/src/gui/painting/qdrawhelper_avx2.cpp
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2019-01-31 11:27:04 +0100
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2019-02-05 17:04:25 +0000
commita6aacdd5607437f13866aff7e0869a7c5f508f00 (patch)
tree375ca6a1b156ea069a46dece518a402af92268a2 /src/gui/painting/qdrawhelper_avx2.cpp
parent93cebb3837e341718dfc0cc44cb74d963e8e2c6c (diff)
Fix convertARGBToARGB32PM_avx2 and convertARGBToRGBA64PM_avx2
The tails was off since f370410097f8cb8d8fdf6174b799497fe7fe0adf Fixes: QTBUG-73440 Change-Id: If86178c6cad3f87d9b5f0f89e90354d49cd386a4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/gui/painting/qdrawhelper_avx2.cpp')
-rw-r--r--src/gui/painting/qdrawhelper_avx2.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/painting/qdrawhelper_avx2.cpp b/src/gui/painting/qdrawhelper_avx2.cpp
index 8c69e21569..4a3e24d6d5 100644
--- a/src/gui/painting/qdrawhelper_avx2.cpp
+++ b/src/gui/painting/qdrawhelper_avx2.cpp
@@ -1054,7 +1054,7 @@ static void convertARGBToARGB32PM_avx2(uint *buffer, const uint *src, qsizetype
__m128i maskedAlphaMask = _mm256_castsi256_si128(alphaMask);
__m128i mask = maskFromCount((count - i) * sizeof(*src));
maskedAlphaMask = _mm_and_si128(mask, maskedAlphaMask);
- __m128i srcVector = _mm_maskload_epi32(reinterpret_cast<const int *>(src), mask);
+ __m128i srcVector = _mm_maskload_epi32(reinterpret_cast<const int *>(src + i), mask);
if (!_mm_testz_si128(srcVector, maskedAlphaMask)) {
// keep the two _mm_test[zc]_siXXX next to each other
@@ -1166,7 +1166,7 @@ static void convertARGBToRGBA64PM_avx2(QRgba64 *buffer, const uint *src, qsizety
__m128i maskedAlphaMask = _mm256_castsi256_si128(alphaMask);
__m128i mask = maskFromCount((count - i) * sizeof(*src));
maskedAlphaMask = _mm_and_si128(mask, maskedAlphaMask);
- __m128i srcVector = _mm_maskload_epi32(reinterpret_cast<const int *>(src), mask);
+ __m128i srcVector = _mm_maskload_epi32(reinterpret_cast<const int *>(src + i), mask);
__m256i src;
if (!_mm_testz_si128(srcVector, maskedAlphaMask)) {