21 #include <type_traits>
29 namespace experimental {
32 template <
typename index_t =
size_t,
typename storage_t = std::
byte>
54 data_[bin_from_index(index)] |= mask_in_bin(index);
59 data_[bin_from_index(index)] &= ~mask_in_bin(index);
65 if (index < num_bits_) { result = ((data_[bin_from_index(index)] & mask_in_bin(index)) != 0); }
80 data_[i] &= other.data_[i];
87 data_[i] |= other.data_[i];
94 data_[i] ^= other.data_[i];
#define DEVICE
Definition: gpu_support.hpp:35
#define HOST
Definition: gpu_support.hpp:34
uint32_t index_type
Definition: index_type.hpp:21
Definition: dbscan.hpp:30
Definition: bitset.hpp:33
HOST DEVICE auto & set(index_type index)
Definition: bitset.hpp:52
HOST DEVICE auto size() const
Definition: bitset.hpp:45
index_t index_type
Definition: bitset.hpp:35
HOST DEVICE auto & flip()
Definition: bitset.hpp:68
HOST DEVICE auto & operator^=(bitset< storage_type > const &other)
Definition: bitset.hpp:91
HOST DEVICE auto bin_count() const
Definition: bitset.hpp:46
HOST DEVICE auto & operator~() const
Definition: bitset.hpp:98
HOST DEVICE bitset(storage_type *data, index_type size)
Definition: bitset.hpp:41
HOST DEVICE auto & operator&=(bitset< storage_type > const &other)
Definition: bitset.hpp:77
HOST DEVICE auto & clear(index_type index)
Definition: bitset.hpp:57
HOST DEVICE bitset()
Definition: bitset.hpp:39
HOST DEVICE auto & operator|=(bitset< storage_type > const &other)
Definition: bitset.hpp:84
storage_t storage_type
Definition: bitset.hpp:34
HOST DEVICE bitset(storage_type *data)
Definition: bitset.hpp:43
HOST DEVICE auto test(index_type index) const
Definition: bitset.hpp:62
constexpr static auto const bin_width
Definition: bitset.hpp:37