[gl, vk] Access Tracking Synchronization

This commit is contained in:
CamilleLaVey 2025-12-02 22:09:38 -04:00 committed by Caio Oliveira
parent 642c91a49b
commit 699dda1957
10 changed files with 236 additions and 7 deletions

View file

@ -130,6 +130,17 @@ public:
ResetStorageBit(id.index);
}
[[nodiscard]] bool Contains(SlotId id) const noexcept {
if (!id) {
return false;
}
const size_t word = id.index / 64;
if (word >= stored_bitset.size()) {
return false;
}
return ((stored_bitset[word] >> (id.index % 64)) & 1) != 0;
}
[[nodiscard]] Iterator begin() noexcept {
const auto it = std::ranges::find_if(stored_bitset, [](u64 value) { return value != 0; });
if (it == stored_bitset.end()) {