Skip to content

Conversation

kazutakahirata
Copy link
Contributor

This patch removes BitVector::next_unset_in_word as the private method
doesn't seem to be used anywhere.

This patch removes BitVector::next_unset_in_word as the private method
doesn't seem to be used anywhere.
@llvmbot
Copy link
Member

llvmbot commented Sep 1, 2025

@llvm/pr-subscribers-llvm-adt

Author: Kazu Hirata (kazutakahirata)

Changes

This patch removes BitVector::next_unset_in_word as the private method
doesn't seem to be used anywhere.


Full diff: https://github.com/llvm/llvm-project/pull/156273.diff

1 Files Affected:

  • (modified) llvm/include/llvm/ADT/BitVector.h (-5)
diff --git a/llvm/include/llvm/ADT/BitVector.h b/llvm/include/llvm/ADT/BitVector.h
index 70de4c239c1c7..cb5b4e496d3a8 100644
--- a/llvm/include/llvm/ADT/BitVector.h
+++ b/llvm/include/llvm/ADT/BitVector.h
@@ -769,11 +769,6 @@ class BitVector {
     std::fill(Bits.begin() + NumWords - Count, Bits.begin() + NumWords, 0);
   }
 
-  int next_unset_in_word(int WordIndex, BitWord Word) const {
-    unsigned Result = WordIndex * BITWORD_SIZE + llvm::countr_one(Word);
-    return Result < size() ? Result : -1;
-  }
-
   unsigned NumBitWords(unsigned S) const {
     return (S + BITWORD_SIZE-1) / BITWORD_SIZE;
   }

@kazutakahirata kazutakahirata merged commit bed3c7e into llvm:main Sep 1, 2025
11 checks passed
@kazutakahirata kazutakahirata deleted the cleanup_20250831_BitVector_next_unset_in_word branch September 1, 2025 06:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants