BitMagic-C++
|
Algorithms for bvector<> More...
Go to the source code of this file.
Data Structures | |
struct | bm::distance_metric_descriptor |
Distance metric descriptor, holds metric code and result. More... | |
Namespaces | |
bm | |
Enumerations | |
enum | bm::distance_metric { bm::COUNT_AND = set_COUNT_AND, bm::COUNT_XOR = set_COUNT_XOR, bm::COUNT_OR = set_COUNT_OR, bm::COUNT_SUB_AB = set_COUNT_SUB_AB, bm::COUNT_SUB_BA = set_COUNT_SUB_BA, bm::COUNT_A = set_COUNT_A, bm::COUNT_B = set_COUNT_B } |
Distance metrics codes defined for vectors A and B. More... | |
Functions | |
distance_metric | bm::operation2metric (set_operation op) |
Convert set operation into compatible distance metric. More... | |
void | bm::combine_count_operation_with_block (const bm::word_t *blk, const bm::word_t *arg_blk, distance_metric_descriptor *dmit, distance_metric_descriptor *dmit_end) |
Internal function computes different distance metrics. More... | |
unsigned | bm::combine_count_and_operation_with_block (const bm::word_t *blk, const bm::word_t *arg_blk) |
Internal function computes AND distance. More... | |
void | bm::combine_any_operation_with_block (const bm::word_t *blk, unsigned gap, const bm::word_t *arg_blk, unsigned arg_gap, distance_metric_descriptor *dmit, distance_metric_descriptor *dmit_end) |
Internal function computes different existense of distance metric. More... | |
unsigned | bm::combine_count_operation_with_block (const bm::word_t *blk, const bm::word_t *arg_blk, distance_metric metric) |
bm::distance_metric_descriptor::size_type | bm::combine_any_operation_with_block (const bm::word_t *blk, unsigned gap, const bm::word_t *arg_blk, unsigned arg_gap, distance_metric metric) |
void | bm::distance_stage (const distance_metric_descriptor *dmit, const distance_metric_descriptor *dmit_end, bool *is_all_and) |
Staging function for distance operation. More... | |
template<class BV > | |
void | bm::distance_operation (const BV &bv1, const BV &bv2, distance_metric_descriptor *dmit, distance_metric_descriptor *dmit_end) |
Distance computing template function. More... | |
template<class BV > | |
BV::size_type | bm::distance_and_operation (const BV &bv1, const BV &bv2) |
Distance AND computing template function. More... | |
template<class BV > | |
void | bm::distance_operation_any (const BV &bv1, const BV &bv2, distance_metric_descriptor *dmit, distance_metric_descriptor *dmit_end) |
Distance screening template function. More... | |
template<class BV > | |
BV::size_type | bm::count_and (const BV &bv1, const BV &bv2) |
Computes bitcount of AND operation of two bitsets. More... | |
template<class BV > | |
BV::size_type | bm::any_and (const BV &bv1, const BV &bv2) |
Computes if there is any bit in AND operation of two bitsets. More... | |
template<class BV > | |
bm::distance_metric_descriptor::size_type | bm::count_xor (const BV &bv1, const BV &bv2) |
Computes bitcount of XOR operation of two bitsets. More... | |
template<class BV > | |
BV::size_type | bm::any_xor (const BV &bv1, const BV &bv2) |
Computes if there is any bit in XOR operation of two bitsets. More... | |
template<class BV > | |
BV::size_type | bm::count_sub (const BV &bv1, const BV &bv2) |
Computes bitcount of SUB operation of two bitsets. More... | |
template<class BV > | |
BV::size_type | bm::any_sub (const BV &bv1, const BV &bv2) |
Computes if there is any bit in SUB operation of two bitsets. More... | |
template<class BV > | |
BV::size_type | bm::count_or (const BV &bv1, const BV &bv2) |
Computes bitcount of OR operation of two bitsets. More... | |
template<class BV > | |
BV::size_type | bm::any_or (const BV &bv1, const BV &bv2) |
Computes if there is any bit in OR operation of two bitsets. More... | |
template<typename It , typename SIZE_TYPE > | |
It | bm::block_range_scan (It first, It last, SIZE_TYPE nblock, SIZE_TYPE *max_id) |
Internal algorithms scans the input for the block range limit. More... | |
template<class BV , class It > | |
void | bm::combine_or (BV &bv, It first, It last) |
OR Combine bitvector and the iterable sequence. More... | |
template<class BV , class It > | |
void | bm::combine_xor (BV &bv, It first, It last) |
XOR Combine bitvector and the iterable sequence. More... | |
template<class BV , class It > | |
void | bm::combine_sub (BV &bv, It first, It last) |
SUB Combine bitvector and the iterable sequence. More... | |
template<class BV , class It > | |
void | bm::combine_and_sorted (BV &bv, It first, It last) |
AND Combine bitvector and the iterable sequence. More... | |
template<class BV , class It > | |
void | bm::combine_and (BV &bv, It first, It last) |
AND Combine bitvector and the iterable sequence. More... | |
template<class BV > | |
BV::size_type | bm::count_intervals (const BV &bv) |
Compute number of bit intervals (GAPs) in the bitvector. More... | |
template<typename BV , class It > | |
void | bm::export_array (BV &bv, It first, It last) |
Export bitset from an array of binary data representing the bit vector. More... | |
template<typename Func , typename SIZE_TYPE > | |
void | bm::for_each_bit_blk (const bm::word_t *block, SIZE_TYPE offset, Func &bit_functor) |
for-each visitor, calls a special visitor functor for each 1 bit group More... | |
template<typename T , typename Func , typename SIZE_TYPE > | |
void | bm::for_each_gap_blk (const T *buf, SIZE_TYPE offset, Func &bit_functor) |
for-each visitor, calls a special visitor functor for each 1 bit range More... | |
Algorithms for bvector<>
Definition in file bmalgo_impl.h.