aboutsummaryrefslogtreecommitdiff
path: root/target/i386/cc_helper.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@twiddle.net>2016-11-21 12:18:53 +0100
committerRichard Henderson <rth@twiddle.net>2017-01-10 08:49:59 -0800
commit4885c3c49531995d67e54907d01d5aa1350faaaf (patch)
tree2989af156daa6b59c803809a06dda0b3777906ad /target/i386/cc_helper.c
parent3253cddd21ab288fa94cb6c8b9ec9fe9a7fcb3e5 (diff)
target-i386: Use ctpop helper
Signed-off-by: Richard Henderson <rth@twiddle.net>
Diffstat (limited to 'target/i386/cc_helper.c')
-rw-r--r--target/i386/cc_helper.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/target/i386/cc_helper.c b/target/i386/cc_helper.c
index 83af223c9f..c9c90e10db 100644
--- a/target/i386/cc_helper.c
+++ b/target/i386/cc_helper.c
@@ -105,6 +105,8 @@ target_ulong helper_cc_compute_all(target_ulong dst, target_ulong src1,
return src1;
case CC_OP_CLR:
return CC_Z | CC_P;
+ case CC_OP_POPCNT:
+ return src1 ? 0 : CC_Z;
case CC_OP_MULB:
return compute_all_mulb(dst, src1);
@@ -232,6 +234,7 @@ target_ulong helper_cc_compute_c(target_ulong dst, target_ulong src1,
case CC_OP_LOGICL:
case CC_OP_LOGICQ:
case CC_OP_CLR:
+ case CC_OP_POPCNT:
return 0;
case CC_OP_EFLAGS: