From b35344e4a0968fd1341ec1c1ed2e6b5c0d851542 Mon Sep 17 00:00:00 2001 From: Nikunj A Dadhania Date: Tue, 26 Jul 2016 17:28:33 +0530 Subject: target-ppc: add cnttzw[.] instruction Add ISA3.0: Count trailing zeros word instruction. Signed-off-by: Nikunj A Dadhania Reviewed-by: Richard Henderson Signed-off-by: David Gibson --- target-ppc/int_helper.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'target-ppc/int_helper.c') diff --git a/target-ppc/int_helper.c b/target-ppc/int_helper.c index 93e8dfa1e7..02b6df3b66 100644 --- a/target-ppc/int_helper.c +++ b/target-ppc/int_helper.c @@ -145,6 +145,11 @@ target_ulong helper_cntlzw(target_ulong t) return clz32(t); } +target_ulong helper_cnttzw(target_ulong t) +{ + return ctz32(t); +} + #if defined(TARGET_PPC64) target_ulong helper_cntlzd(target_ulong t) { -- cgit v1.2.3