summaryrefslogtreecommitdiffstats
path: root/llvm/unittests/ADT/BitVectorTest.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Fix a bug in the set(I,E)/reset(I,E) methods that I recently added. The ↵Owen Anderson2012-10-161-0/+10
| | | | | | boundary condition for checking if I and E were in the same word were incorrect, and, beyond that, the mask computation was not using a wide enough constant. llvm-svn: 166015
* Add range-based set()/reset() to BitVector. These allow fast ↵Owen Anderson2012-10-151-0/+42
| | | | | | setting/resetting of ranges of bits, particularly useful when dealing with very large BitVector's. llvm-svn: 165984
* Merge the SmallBitVector and BitVector unit tests with gtest's typed test ↵Benjamin Kramer2012-06-161-16/+25
| | | | | | magic and bring SmallBitVector up to date. llvm-svn: 158600
* Remove the expensive BitVector::operator~().Jakob Stoklund Olesen2012-05-141-3/+4
| | | | | | | Returning a temporary BitVector is very expensive. If you must, create the temporary explicitly: Use BitVector(A).flip() instead of ~A. llvm-svn: 156768
* Add BitVector::anyCommon().Jakob Stoklund Olesen2012-05-141-1/+29
| | | | | | The existing operation (A & B).any() is very slow. llvm-svn: 156760
* Add portable bit mask operations to BitVector.Jakob Stoklund Olesen2012-01-171-0/+46
| | | | | | | | | | | | BitVector uses the native word size for its internal representation. That doesn't work well for literal bit masks in source code. This patch adds BitVector operations to efficiently apply literal bit masks specified as arrays of uint32_t. Since each array entry always holds exactly 32 bits, these portable bit masks can be source code literals, probably produced by TableGen. llvm-svn: 148272
* Add an all() method to BitVector, for testing whether all bits are set.Dan Gohman2010-09-271-0/+7
| | | | llvm-svn: 114830
* Update BitVectorTest.cpp to stay in sync with SmallBitVectorTest.cpp,Dan Gohman2010-04-301-3/+15
| | | | | | and fix a bug in BitVector's reference proxy class which this exposed. llvm-svn: 102768
* Silence GCC warnings.Benjamin Kramer2010-02-101-6/+6
| | | | llvm-svn: 95779
* Implement operators |=, &=, and ^= for SmallBitVector, and remove theDan Gohman2010-02-101-0/+40
| | | | | | | restriction in BitVector for |= and ^= that the operand must be the same length. llvm-svn: 95768
* Disable unittests/ADT/BitVectorTest on PPC Darwin.Dale Johannesen2010-02-091-0/+2
| | | | | | | | | It fails with a release build only, for reasons as yet unknown. (If there's a better way to Xfail things here let me know, doesn't seem to be any prior art in unittests.) llvm-svn: 95700
* Add a SmallBitVector class, which mimics BitVector but uses onlyDan Gohman2010-01-051-0/+140
a single pointer (PointerIntPair) member. In "small" mode, the pointer field is reinterpreted as a set of bits. In "large" mode, the pointer points to a heap-allocated object. Also, give BitVector empty and swap functions. And, add some simple unittests for BitVector and SmallBitVector. llvm-svn: 92730
OpenPOWER on IntegriCloud