diff options
Diffstat (limited to 'target-ppc/int_helper.c')
-rw-r--r-- | target-ppc/int_helper.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/target-ppc/int_helper.c b/target-ppc/int_helper.c index 7fca9f093b..3b67ae363f 100644 --- a/target-ppc/int_helper.c +++ b/target-ppc/int_helper.c @@ -1549,6 +1549,20 @@ VGENERIC_DO(clzd, u64) #undef clzw #undef clzd +#define popcntb(v) ctpop8(v) +#define popcnth(v) ctpop16(v) +#define popcntw(v) ctpop32(v) +#define popcntd(v) ctpop64(v) + +VGENERIC_DO(popcntb, u8) +VGENERIC_DO(popcnth, u16) +VGENERIC_DO(popcntw, u32) +VGENERIC_DO(popcntd, u64) + +#undef popcntb +#undef popcnth +#undef popcntw +#undef popcntd #undef VGENERIC_DO |