aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/mips/vp9_idct_msa.c
diff options
context:
space:
mode:
authorgxw <guxiwei-hf@loongson.cn>2019-08-06 19:11:16 +0800
committerMichael Niedermayer <michael@niedermayer.cc>2019-09-16 00:04:18 +0200
commit92fc0bfa54d82e3bb18138f9f0ebc3a7322b64ce (patch)
tree8486e67e8177fd2043a11c339a5896393f1373de /libavcodec/mips/vp9_idct_msa.c
parent77937a42e7127271bd50d7f8035c3ebd5a1047c5 (diff)
downloadffmpeg-92fc0bfa54d82e3bb18138f9f0ebc3a7322b64ce.tar.gz
avutil/mips: refactor msa SLDI_Bn_0 and SLDI_Bn macros.
Changing details as following: 1. The previous order of parameters are irregular and difficult to understand. Adjust the order of the parameters according to the rule: (RTYPE, input registers, input mask/input index/..., output registers). Most of the existing msa macros follow the rule. 2. Remove the redundant macro SLDI_Bn_0 and use SLDI_Bn instead. Reviewed-by: Shiyou Yin <yinshiyou-hf@loongson.cn> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/mips/vp9_idct_msa.c')
-rw-r--r--libavcodec/mips/vp9_idct_msa.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/mips/vp9_idct_msa.c b/libavcodec/mips/vp9_idct_msa.c
index a3f5270b73..53bfbb4765 100644
--- a/libavcodec/mips/vp9_idct_msa.c
+++ b/libavcodec/mips/vp9_idct_msa.c
@@ -249,6 +249,7 @@ static const int32_t sinpi_4_9 = 15212;
v8i16 c0_m, c1_m, c2_m, c3_m; \
v8i16 step0_m, step1_m; \
v4i32 tmp0_m, tmp1_m, tmp2_m, tmp3_m; \
+ v16i8 zeros = { 0 }; \
\
c0_m = VP9_SET_COSPI_PAIR(cospi_16_64, cospi_16_64); \
c1_m = VP9_SET_COSPI_PAIR(cospi_16_64, -cospi_16_64); \
@@ -262,7 +263,7 @@ static const int32_t sinpi_4_9 = 15212;
SRARI_W4_SW(tmp0_m, tmp1_m, tmp2_m, tmp3_m, VP9_DCT_CONST_BITS); \
\
PCKEV_H2_SW(tmp1_m, tmp0_m, tmp3_m, tmp2_m, tmp0_m, tmp2_m); \
- SLDI_B2_0_SW(tmp0_m, tmp2_m, tmp1_m, tmp3_m, 8); \
+ SLDI_B2_SW(zeros, tmp0_m, zeros, tmp2_m, 8, tmp1_m, tmp3_m); \
BUTTERFLY_4((v8i16) tmp0_m, (v8i16) tmp1_m, \
(v8i16) tmp2_m, (v8i16) tmp3_m, \
out0, out1, out2, out3); \