external/skia/source/skia_opts_internal.hxx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
New commits: commit 304352d9df17ec5e9963c1b0d41c7f7cb951012e Author: Luboš Luňák <l.lu...@collabora.com> AuthorDate: Sun Mar 14 13:45:11 2021 +0100 Commit: Luboš Luňák <l.lu...@collabora.com> CommitDate: Mon Mar 15 21:40:22 2021 +0100 less complicated Skia SSSE3 loop I copy&pasted this from other code, but in this case it's simpler and less confusing to not overrun the output buffer. Change-Id: I782348d9870ac1e87c49e2267953c2f6299dbcd0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112537 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lu...@collabora.com> diff --git a/external/skia/source/skia_opts_internal.hxx b/external/skia/source/skia_opts_internal.hxx index 1f46ee72eb4a..0ca6a04351d2 100644 --- a/external/skia/source/skia_opts_internal.hxx +++ b/external/skia/source/skia_opts_internal.hxx @@ -52,15 +52,13 @@ inline void RGB1_to_R(uint8_t dst[], const uint32_t* src, int count) { const uint8_t X = 0xFF; // Used a placeholder. The value of X is irrelevant. __m128i pack = _mm_setr_epi8(0,4,8,12, X,X,X,X,X,X,X,X,X,X,X,X); -// Storing 4 pixels should store 4 bytes, but here it stores 16, so test count >= 16 -// in order to not overrun the output buffer. - while (count >= 16) { + while (count >= 4) { __m128i rgba = _mm_loadu_si128((const __m128i*) src); __m128i rgb = _mm_shuffle_epi8(rgba, pack); // Store 4 pixels. - _mm_storeu_si128((__m128i*) dst, rgb); + *((uint32_t*)dst) = _mm_cvtsi128_si32(rgb); src += 4; dst += 4; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits