35 #define WORD_OFFSET(n) (n/64)
36 #define BIT_OFFSET(n) (n & 0x3f)
43 BitMap() { start = NULL; end = NULL;};
49 end = start + num_longs;
57 uint64_t num_longs = rhs.end - rhs.start;
60 end = start + num_longs;
61 std::copy(rhs.start, rhs.end, start);
68 uint64_t num_longs = rhs.end - rhs.start;
71 end = start + num_longs;
72 std::copy(rhs.start, rhs.end, start);
80 for(
uint64_t *it=start; it!=end; it++)
120 if (bit_offset != 63) {
121 temp = temp >> (bit_offset+1);
126 next = (next & 0xffffffc0);
150 std::copy(other->start, other->end, start);
157 std::cout <<
" " << i;
158 std::cout << std::endl;
bool get_bit(uint64_t pos)
void set_bit(uint64_t pos)
void set_bit_atomic(long pos)
BitMap & operator=(const BitMap &rhs)
long get_next_bit(uint64_t pos)
void copy_from(const BitMap *other)
void reset_bit(uint64_t pos)
BitMap(const BitMap &rhs)
unsigned __int64 uint64_t