[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 28/65] target-cris: Use clz opcode
From: |
Richard Henderson |
Subject: |
[Qemu-devel] [PATCH 28/65] target-cris: Use clz opcode |
Date: |
Fri, 23 Dec 2016 20:00:05 -0800 |
Cc: Edgar E. Iglesias <address@hidden>
Signed-off-by: Richard Henderson <address@hidden>
---
target/cris/helper.h | 1 -
target/cris/op_helper.c | 5 -----
target/cris/translate.c | 2 +-
3 files changed, 1 insertion(+), 7 deletions(-)
diff --git a/target/cris/helper.h b/target/cris/helper.h
index ff35956..20d21c4 100644
--- a/target/cris/helper.h
+++ b/target/cris/helper.h
@@ -7,7 +7,6 @@ DEF_HELPER_1(rfn, void, env)
DEF_HELPER_3(movl_sreg_reg, void, env, i32, i32)
DEF_HELPER_3(movl_reg_sreg, void, env, i32, i32)
-DEF_HELPER_FLAGS_1(lz, TCG_CALL_NO_SE, i32, i32)
DEF_HELPER_FLAGS_4(btst, TCG_CALL_NO_SE, i32, env, i32, i32, i32)
DEF_HELPER_FLAGS_4(evaluate_flags_muls, TCG_CALL_NO_SE, i32, env, i32, i32,
i32)
diff --git a/target/cris/op_helper.c b/target/cris/op_helper.c
index 5043039..e92505c 100644
--- a/target/cris/op_helper.c
+++ b/target/cris/op_helper.c
@@ -230,11 +230,6 @@ void helper_rfn(CPUCRISState *env)
env->pregs[PR_CCS] |= M_FLAG_V32;
}
-uint32_t helper_lz(uint32_t t0)
-{
- return clz32(t0);
-}
-
uint32_t helper_btst(CPUCRISState *env, uint32_t t0, uint32_t t1, uint32_t ccs)
{
/* FIXME: clean this up. */
diff --git a/target/cris/translate.c b/target/cris/translate.c
index b910427..0ee05ca 100644
--- a/target/cris/translate.c
+++ b/target/cris/translate.c
@@ -767,7 +767,7 @@ static void cris_alu_op_exec(DisasContext *dc, int op,
t_gen_subx_carry(dc, dst);
break;
case CC_OP_LZ:
- gen_helper_lz(dst, b);
+ tcg_gen_clzi_tl(dst, b, TARGET_LONG_BITS);
break;
case CC_OP_MULS:
tcg_gen_muls2_tl(dst, cpu_PR[PR_MOF], a, b);
--
2.9.3
- [Qemu-devel] [PATCH 20/65] tcg: Add markup for output requires new register, (continued)
- [Qemu-devel] [PATCH 20/65] tcg: Add markup for output requires new register, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 23/65] tcg: Allow an operand to be matching or a constant, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 16/65] target-mips: Use the new extract op, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 25/65] disas/i386.c: Handle tzcnt, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 26/65] disas/ppc: Handle popcnt and cnttz, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 22/65] tcg: Pass the opcode width to target_parse_constraint, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 27/65] target-alpha: Use the ctz and clz opcodes, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 29/65] target-microblaze: Use clz opcode, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 30/65] target-mips: Use clz opcode, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 24/65] tcg: Add clz and ctz opcodes, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 28/65] target-cris: Use clz opcode,
Richard Henderson <=
- [Qemu-devel] [PATCH 36/65] target-unicore32: Use clz opcode, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 32/65] target-ppc: Use clz and ctz opcodes, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 31/65] target-openrisc: Use clz and ctz opcodes, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 34/65] target-tilegx: Use clz and ctz opcodes, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 33/65] target-s390x: Use clz opcode, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 35/65] target-tricore: Use clz opcode, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 38/65] target-arm: Use clz opcode, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 39/65] target-i386: Use clz and ctz opcodes, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 41/65] tcg/aarch64: Handle ctz and clz opcodes, Richard Henderson, 2016/12/23
- [Qemu-devel] [PATCH 43/65] tcg/mips: Handle clz opcode, Richard Henderson, 2016/12/23