Optimize std::rotl and std::rotr, add test for std::popcount
authorJonathan Wakely <jwakely@redhat.com>
Wed, 4 Jul 2018 08:07:23 +0000 (09:07 +0100)
committerJonathan Wakely <redi@gcc.gnu.org>
Wed, 4 Jul 2018 08:07:23 +0000 (09:07 +0100)
commit90fc44ecfa4741a055ec3d35722e2624c2231f98
treefd397e0cb3a87ce87d0e8d28b2e2e5a46427262d
parent6e38deee4659d87d57e54a869d546dc01cf733cc
Optimize std::rotl and std::rotr, add test for std::popcount

* include/std/bit (__rotl, __rotr): Avoid branch.
(_If_is_unsigned_integer): Use remove_cv_t.
* testsuite/26_numerics/bit/bitops.count/popcount.cc: New.

From-SVN: r262378
libstdc++-v3/ChangeLog
libstdc++-v3/include/std/bit
libstdc++-v3/testsuite/26_numerics/bit/bitops.count/popcount.cc [new file with mode: 0644]