diff mbox series

[PULL,03/15] target/mips: Fix more TCG temporary leaks in gen_pool32a5_nanomips_insn

Message ID 20210625092329.1529100-4-f4bug@amsat.org (mailing list archive)
State New, archived
Headers show
Series [PULL,01/15] target/mips: Fix potential integer overflow (CID 1452921) | expand

Commit Message

Philippe Mathieu-Daudé June 25, 2021, 9:23 a.m. UTC
Fix multiple TCG temporary leaks in gen_pool32a5_nanomips_insn().

Fixes: 3285a3e4445 ("target/mips: Add emulation of DSP ASE for nanoMIPS - part 1")
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20210617174323.2900831-3-f4bug@amsat.org>
---
 target/mips/tcg/translate.c | 4 ++++
 1 file changed, 4 insertions(+)
diff mbox series

Patch

diff --git a/target/mips/tcg/translate.c b/target/mips/tcg/translate.c
index 120484a6c06..09b19262c8c 100644
--- a/target/mips/tcg/translate.c
+++ b/target/mips/tcg/translate.c
@@ -20298,6 +20298,10 @@  static void gen_pool32a5_nanomips_insn(DisasContext *ctx, int opc,
         gen_reserved_instruction(ctx);
         break;
     }
+
+    tcg_temp_free(v2_t);
+    tcg_temp_free(v1_t);
+    tcg_temp_free(t0);
 }
 
 static int decode_nanomips_32_48_opc(CPUMIPSState *env, DisasContext *ctx)