Skip to content

Commit 74341af

Browse files
committed
target/mips: Use tcg_constant_i32() in gen_msa_2r()
Avoid using a TCG temporary by moving Data Format to the constant pool. Signed-off-by: Philippe Mathieu-Daudé <[email protected]> Reviewed-by: Richard Henderson <[email protected]> Message-Id: <[email protected]>
1 parent e81a48b commit 74341af

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

target/mips/tcg/msa_translate.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1946,7 +1946,6 @@ static void gen_msa_2r(DisasContext *ctx)
19461946
uint8_t df = (ctx->opcode >> 16) & 0x3;
19471947
TCGv_i32 twd = tcg_const_i32(wd);
19481948
TCGv_i32 tws = tcg_const_i32(ws);
1949-
TCGv_i32 tdf = tcg_const_i32(df);
19501949

19511950
switch (MASK_MSA_2R(ctx->opcode)) {
19521951
case OPC_FILL_df:
@@ -1957,7 +1956,8 @@ static void gen_msa_2r(DisasContext *ctx)
19571956
break;
19581957
}
19591958
#endif
1960-
gen_helper_msa_fill_df(cpu_env, tdf, twd, tws); /* trs */
1959+
gen_helper_msa_fill_df(cpu_env, tcg_constant_i32(df),
1960+
twd, tws); /* trs */
19611961
break;
19621962
case OPC_NLOC_df:
19631963
switch (df) {
@@ -2015,7 +2015,6 @@ static void gen_msa_2r(DisasContext *ctx)
20152015

20162016
tcg_temp_free_i32(twd);
20172017
tcg_temp_free_i32(tws);
2018-
tcg_temp_free_i32(tdf);
20192018
}
20202019

20212020
static void gen_msa_2rf(DisasContext *ctx)

0 commit comments

Comments
 (0)