NCBI C++ ToolKit
Classes | Namespaces | Functions
bmutil.h File Reference

Bit manipulation primitives (internal) More...

#include "bmdef.h"
#include "bmconst.h"
+ Include dependency graph for bmutil.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Go to the SVN repository for this file.


struct  bm::bit_block_t
 bit-block array wrapped into union for correct interpretation of 32-bit vs 64-bit access vs SIMD More...
union  bm::bit_block_t::bunion_t
struct  bm::conditional< b >
 ad-hoc conditional expressions More...
struct  bm::conditional< false >
class  bm::ptr_guard< T >
 Mini auto-pointer for internal memory management. More...
struct  bm::and_func
 and functor More...
struct  bm::xor_func
 xor functor More...
struct  bm::or_func
 or functor More...
struct  bm::sub_func
 sub functor More...




template<typename T >
T bm::min_value (T v1, T v2) noexcept
 Get minimum of 2 values. More...
template<typename T >
T bm::ilog2 (T x) noexcept
 Fast loop-less function to find LOG2. More...
bm::gap_word_t bm::ilog2 (gap_word_t x) noexcept
unsigned bm::count_leading_zeros (unsigned x) noexcept
 Portable LZCNT with (uses minimal LUT) More...
unsigned bm::count_trailing_zeros (unsigned v) noexcept
 Portable TZCNT with (uses 37-LUT) More...
template<typename T >
T bm::ilog2_LUT (T x) noexcept
 Lookup table based integer LOG2. More...
bm::gap_word_t bm::ilog2_LUT< bm::gap_word_t > (bm::gap_word_t x) noexcept
 Lookup table based short integer LOG2. More...
template<typename T >
T bm::bit_scan_fwd (T v) noexcept
unsigned bm::bit_scan_reverse32 (unsigned w) noexcept
unsigned bm::bit_scan_forward32 (unsigned w) noexcept
unsigned long long bm::bmi_bslr_u64 (unsigned long long w) noexcept
unsigned long long bm::bmi_blsi_u64 (unsigned long long w)
unsigned bm::count_leading_zeros_u32 (unsigned w) noexcept
 32-bit bit-scan reverse More...
unsigned bm::count_leading_zeros_u64 (bm::id64_t w) noexcept
 64-bit bit-scan reverse More...
unsigned bm::count_trailing_zeros_u32 (unsigned w) noexcept
 32-bit bit-scan fwd More...
unsigned bm::count_trailing_zeros_u64 (bm::id64_t w) noexcept
 64-bit bit-scan fwd More...
template<class T >
unsigned bm::bit_scan_reverse (T value) noexcept
unsigned bm::mask_r_u32 (unsigned nbit) noexcept
unsigned bm::mask_l_u32 (unsigned nbit) noexcept
template<typename W >
void bm::xor_swap (W &x, W &y) noexcept
 XOR swap two variables. More...
unsigned bm::compute_h64_mask (unsigned long long w) noexcept
 –°ompute mask of bytes presense in 64-bit word. More...
bool bm::has_zero_byte_u64 (bm::id64_t v) noexcept
 Returns true if INT64 contains 0 octet. More...
bm::id_t bm::word_bitcount (bm::id_t w) noexcept
unsigned bm::word_bitcount64 (bm::id64_t x) noexcept
template<typename T >
bool bm::is_aligned (T *p) noexcept
 Check pointer alignment. More...

Detailed Description

Bit manipulation primitives (internal)

Definition in file bmutil.h.

Modified on Mon Jul 15 05:31:34 2024 by rev. 669887