mirror of
https://github.com/RPCS3/llvm.git
synced 2026-07-19 15:13:49 -04:00
[APInt] Move the >64 bit case for flipAllBits out of line.
This is more consistent with what we do for other operations. This shrinks the opt binary on my build by ~72k. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@298858 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -581,6 +581,11 @@ void APInt::clearBit(unsigned bitPosition) {
|
||||
}
|
||||
|
||||
/// @brief Toggle every bit to its opposite value.
|
||||
void APInt::flipAllBitsSlowCase() {
|
||||
for (unsigned i = 0; i < getNumWords(); ++i)
|
||||
pVal[i] ^= UINT64_MAX;
|
||||
clearUnusedBits();
|
||||
}
|
||||
|
||||
/// Toggle a given bit to its opposite value whose position is given
|
||||
/// as "bitPosition".
|
||||
|
||||
Reference in New Issue
Block a user