23 #ifndef _LOCKFREE_BITMAP_HPP_ 24 #define _LOCKFREE_BITMAP_HPP_ 82 #define LF_BITMAP_FULL_USAGE_RATIO lockfree::bitmap::FULL_USAGE_RATIO 83 #define LF_BITMAP_95PERCENTILE_USAGE_RATIO lockfree::bitmap::NINTETYFIVE_PERCENTILE_USAGE_RATIO 85 #define LF_BITFIELD_WORD_SIZE (int) (sizeof (unsigned int) * 8) 87 #define LF_BITMAP_IS_FULL(bitmap) (bitmap)->is_full () 89 #define LF_BITMAP_COUNT_ALIGN(count) \ 90 (((count) + (LF_BITFIELD_WORD_SIZE) - 1) & ~((LF_BITFIELD_WORD_SIZE) - 1)) 92 #endif // !_LOCKFREE_BITMAP_HPP_ static const float FULL_USAGE_RATIO
static const LF_BITMAP_STYLE LF_BITMAP_ONE_CHUNK
void free_entry(int entry_idx)
static const float NINTETYFIVE_PERCENTILE_USAGE_RATIO
std::atomic< int > entry_count_in_use
static const LF_BITMAP_STYLE LF_BITMAP_LIST_OF_CHUNKS
std::atomic< unsigned int > * bitfield
std::atomic< unsigned int > start_idx
void init(chunking_style style, int entries_count, float usage_ratio)