[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 1/2] target/ppc: Use tcg_gen_abs_i32
From: |
Philippe Mathieu-Daudé |
Subject: |
[Qemu-devel] [PATCH 1/2] target/ppc: Use tcg_gen_abs_i32 |
Date: |
Tue, 23 Apr 2019 12:21:44 +0200 |
Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
---
target/ppc/translate/spe-impl.inc.c | 14 +-------------
1 file changed, 1 insertion(+), 13 deletions(-)
diff --git a/target/ppc/translate/spe-impl.inc.c
b/target/ppc/translate/spe-impl.inc.c
index 8c1c16c63e..41da7fab97 100644
--- a/target/ppc/translate/spe-impl.inc.c
+++ b/target/ppc/translate/spe-impl.inc.c
@@ -125,19 +125,7 @@ static inline void gen_##name(DisasContext *ctx)
\
tcg_temp_free_i32(t0); \
}
-static inline void gen_op_evabs(TCGv_i32 ret, TCGv_i32 arg1)
-{
- TCGLabel *l1 = gen_new_label();
- TCGLabel *l2 = gen_new_label();
-
- tcg_gen_brcondi_i32(TCG_COND_GE, arg1, 0, l1);
- tcg_gen_neg_i32(ret, arg1);
- tcg_gen_br(l2);
- gen_set_label(l1);
- tcg_gen_mov_i32(ret, arg1);
- gen_set_label(l2);
-}
-GEN_SPEOP_ARITH1(evabs, gen_op_evabs);
+GEN_SPEOP_ARITH1(evabs, tcg_gen_abs_i32);
GEN_SPEOP_ARITH1(evneg, tcg_gen_neg_i32);
GEN_SPEOP_ARITH1(evextsb, tcg_gen_ext8s_i32);
GEN_SPEOP_ARITH1(evextsh, tcg_gen_ext16s_i32);
--
2.19.1