Andrey Semashev 83bdf5a335 Reenabled popcnt for MSVC, improved perf by leveraging ILP.
On MSVC and compatible compilers popcnt is now enabled if it is known at
compile time that the target CPU supports popcnt instruction. Unfortunately,
MSVC does not have a predefined macro specifically for popcnt, so we have
to test for AVX instead. __POPCNT__ is still tested in case clang or user
defines it.

For MSVC, the 64-bit popcount is now also implemented on 32-bit targets by
issuing two 32-bit popcnt instructions. For gcc and compatible compilers,
16-bit popcount implementation is provided, which is better than the generic
popcount implementation, but still slower than byte-wise do_count.

The do_count algorithm implementations have been improved by leveraging
instruction level parallelism better, which gives 0 to 27% improvement and
no regressions.

Also made code formatting more consistent and reduced code duplication between
do_count implementations.
2019-04-26 08:55:53 -04:00
2017-01-09 03:09:28 -05:00
2014-08-18 14:58:36 +01:00
2002-07-17 16:21:43 +00:00
2006-11-07 19:11:57 +00:00
2018-07-04 08:05:54 -04:00

DynamicBitset, part of collection of the Boost C++ Libraries, is similar to std::bitset however the size is specified at run-time instead of at compile-time.

License

Distributed under the Boost Software License, Version 1.0.

Properties

  • C++03
  • Header-only

Build Status

Branch Travis Appveyor Coverity Scan codecov.io Deps Docs Tests
master Build Status Build status Coverity Scan Build Status codecov Deps Documentation Enter the Matrix
develop Build Status Build status Coverity Scan Build Status codecov Deps Documentation Enter the Matrix

Directories

Name Purpose
example examples
doc documentation
include headers
test unit tests

More information

  • Ask questions
  • Report bugs: Be sure to mention Boost version, platform and compiler you're using. A small compilable code sample to reproduce the problem is always good as well.
  • Submit your patches as pull requests against develop branch. Note that by submitting patches you agree to license your modifications under the Boost Software License, Version 1.0.
  • Discussions about the library are held on the Boost developers mailing list. Be sure to read the discussion policy before posting and add the [dynamic_bitset] tag at the beginning of the subject line.
Description
Mirrored via gitea-mirror
Readme BSL-1.0 2.3 MiB
Languages
C++ 98%
CMake 1.6%
HTML 0.4%