[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 7/8] target/mips: Use tcg_constant_i32() in generate_exception_er
From: |
Philippe Mathieu-Daudé |
Subject: |
[PATCH 7/8] target/mips: Use tcg_constant_i32() in generate_exception_err() |
Date: |
Mon, 16 Aug 2021 22:51:06 +0200 |
excp/err are temporaries input, so we can replace tcg_const_i32()
calls by tcg_constant_i32() equivalent.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
target/mips/tcg/translate.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/target/mips/tcg/translate.c b/target/mips/tcg/translate.c
index c515a337ebc..93b72c994f2 100644
--- a/target/mips/tcg/translate.c
+++ b/target/mips/tcg/translate.c
@@ -1363,12 +1363,9 @@ static inline void restore_cpu_state(CPUMIPSState *env,
DisasContext *ctx)
void generate_exception_err(DisasContext *ctx, int excp, int err)
{
- TCGv_i32 texcp = tcg_const_i32(excp);
- TCGv_i32 terr = tcg_const_i32(err);
save_cpu_state(ctx, 1);
- gen_helper_raise_exception_err(cpu_env, texcp, terr);
- tcg_temp_free_i32(terr);
- tcg_temp_free_i32(texcp);
+ gen_helper_raise_exception_err(cpu_env, tcg_constant_i32(excp),
+ tcg_constant_i32(err));
ctx->base.is_jmp = DISAS_NORETURN;
}
--
2.31.1
- [PATCH 0/8] target/mips: Housekeeping in gen_helper() macros, Philippe Mathieu-Daudé, 2021/08/16
- [PATCH 1/8] target/mips: Remove gen_helper_0e3i(), Philippe Mathieu-Daudé, 2021/08/16
- [PATCH 3/8] target/mips: Use tcg_constant_i32() in gen_helper_0e2i(), Philippe Mathieu-Daudé, 2021/08/16
- [PATCH 2/8] target/mips: Remove gen_helper_1e2i(), Philippe Mathieu-Daudé, 2021/08/16
- [PATCH 4/8] target/mips: Simplify gen_helper() macros by using tcg_constant_i32(), Philippe Mathieu-Daudé, 2021/08/16
- [PATCH 5/8] target/mips: Inline gen_helper_1e1i() call in op_ld_INSN() macros, Philippe Mathieu-Daudé, 2021/08/16
- [PATCH 6/8] target/mips: Inline gen_helper_0e0i(), Philippe Mathieu-Daudé, 2021/08/16
- [PATCH 7/8] target/mips: Use tcg_constant_i32() in generate_exception_err(),
Philippe Mathieu-Daudé <=
- [PATCH 8/8] target/mips: Define gen_helper() macros in translate.h, Philippe Mathieu-Daudé, 2021/08/16
- Re: [PATCH 0/8] target/mips: Housekeeping in gen_helper() macros, Richard Henderson, 2021/08/17