summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Support/APInt.cpp
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2017-03-27 18:16:17 +0000
committerCraig Topper <craig.topper@gmail.com>2017-03-27 18:16:17 +0000
commit70d8ca9276510103beb947b8ba7b365a69a2b863 (patch)
tree32c49e2bee6845d227977901ef1e980458d69e89 /llvm/lib/Support/APInt.cpp
parentf0b22c471bb787adde866e8b30b81f4754d20550 (diff)
downloadbcm5719-llvm-70d8ca9276510103beb947b8ba7b365a69a2b863.tar.gz
bcm5719-llvm-70d8ca9276510103beb947b8ba7b365a69a2b863.zip
[APInt] Move operator&=(uint64_t) inline and use memset to clear the upper words.
This method is pretty new and probably isn't use much in the code base so this should have a negligible size impact. The OR and XOR operators are already inline. llvm-svn: 298870
Diffstat (limited to 'llvm/lib/Support/APInt.cpp')
-rw-r--r--llvm/lib/Support/APInt.cpp12
1 files changed, 0 insertions, 12 deletions
diff --git a/llvm/lib/Support/APInt.cpp b/llvm/lib/Support/APInt.cpp
index aacb7440313..ebcbb151867 100644
--- a/llvm/lib/Support/APInt.cpp
+++ b/llvm/lib/Support/APInt.cpp
@@ -428,18 +428,6 @@ APInt& APInt::operator&=(const APInt& RHS) {
return *this;
}
-APInt &APInt::operator&=(uint64_t RHS) {
- if (isSingleWord()) {
- VAL &= RHS;
- return *this;
- }
- pVal[0] &= RHS;
- unsigned numWords = getNumWords();
- for (unsigned i = 1; i < numWords; ++i)
- pVal[i] = 0;
- return *this;
-}
-
APInt& APInt::operator|=(const APInt& RHS) {
assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
if (isSingleWord()) {
OpenPOWER on IntegriCloud