https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109011
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Hacker's Delight has also a variant for popcount, either .POPCOUNT ((x - 1) & ~x) or bitsize - .POPCOUNT (x | -x), though a question is if there are any targets which have vector popcount and don't have vector clz nor ctz for some mode.