From 0ea510eb9b00625c2e7841c4887951cbbb6850e5 Mon Sep 17 00:00:00 2001 From: Joshua Ashton Date: Sat, 11 Jan 2020 04:12:43 +0000 Subject: [PATCH] [util] Add clearAll helper to bitset --- src/util/util_bit.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/util/util_bit.h b/src/util/util_bit.h index 23b9cb7b..7d6e22df 100644 --- a/src/util/util_bit.h +++ b/src/util/util_bit.h @@ -237,6 +237,11 @@ namespace dxvk::bit { } } + constexpr void clearAll() { + for (size_t i = 0; i < Dwords; i++) + m_dwords[i] = 0; + } + constexpr bool any() { for (size_t i = 0; i < Dwords; i++) { if (m_dwords[i] != 0)