From: Vladislav Shchapov Date: Sat, 27 Dec 2025 10:58:03 +0000 (+0500) Subject: Remove redundant instructions in 256 bit wide chunkset on LoongArch64 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3bb64ec49623845871f157370ee3a1c43a040be4;p=thirdparty%2Fzlib-ng.git Remove redundant instructions in 256 bit wide chunkset on LoongArch64 Signed-off-by: Vladislav Shchapov --- diff --git a/arch/loongarch/chunkset_lasx.c b/arch/loongarch/chunkset_lasx.c index 5626ca1f7..03a0a9c85 100644 --- a/arch/loongarch/chunkset_lasx.c +++ b/arch/loongarch/chunkset_lasx.c @@ -62,10 +62,8 @@ static inline chunk_t GET_CHUNK_MAG(uint8_t *buf, uint32_t *chunk_rem, uint32_t /* This simpler case still requires us to shuffle in 128 bit lanes, so we must apply a static offset after * broadcasting the first vector register to both halves. This is _marginally_ faster than doing two separate * shuffles and combining the halves later */ - const __m256i permute_xform = lasx_set_si128(__lsx_vreplgr2vr_b(16), __lsx_vreplgr2vr_b(0)); __m256i perm_vec = __lasx_xvld(permute_table+lut_rem.idx, 0); __m128i ret_vec0 = __lsx_vld(buf, 0); - perm_vec = __lasx_xvadd_b(perm_vec, permute_xform); ret_vec = lasx_set_si128(ret_vec0, ret_vec0); ret_vec = lasx_shuffle_b(ret_vec, perm_vec); } else {