From 58d2a9aef4cacb3056f5b12c1eb92105704183fe Mon Sep 17 00:00:00 2001 From: Aurelien Jarno Date: Mon, 1 May 2017 23:20:43 +0200 Subject: target/sh4: optimize gen_store_fpr64 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Using extr and avoiding intermediate temps. Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Signed-off-by: Aurelien Jarno --- target/sh4/translate.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'target/sh4') diff --git a/target/sh4/translate.c b/target/sh4/translate.c index a4c7a08..fe8bff5 100644 --- a/target/sh4/translate.c +++ b/target/sh4/translate.c @@ -305,13 +305,7 @@ static inline void gen_load_fpr64(TCGv_i64 t, int reg) static inline void gen_store_fpr64 (TCGv_i64 t, int reg) { - TCGv_i32 tmp = tcg_temp_new_i32(); - tcg_gen_extrl_i64_i32(tmp, t); - tcg_gen_mov_i32(cpu_fregs[reg + 1], tmp); - tcg_gen_shri_i64(t, t, 32); - tcg_gen_extrl_i64_i32(tmp, t); - tcg_gen_mov_i32(cpu_fregs[reg], tmp); - tcg_temp_free_i32(tmp); + tcg_gen_extr_i64_i32(cpu_fregs[reg + 1], cpu_fregs[reg], t); } #define B3_0 (ctx->opcode & 0xf) -- cgit v1.1