PR5207: Make APInt::set(), APInt::clear() and APInt::flip() return void.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120413 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Jay Foad
2010-11-30 09:02:01 +00:00
parent d872f144e2
commit a99793c5ea
4 changed files with 39 additions and 33 deletions

View File

@@ -875,8 +875,9 @@ bool llvm::ComputeMultiple(Value *V, unsigned Base, Value *&Multiple,
// Turn Op0 << Op1 into Op0 * 2^Op1
APInt Op1Int = Op1CI->getValue();
uint64_t BitToSet = Op1Int.getLimitedValue(Op1Int.getBitWidth() - 1);
Op1 = ConstantInt::get(V->getContext(),
APInt(Op1Int.getBitWidth(), 0).set(BitToSet));
APInt API(Op1Int.getBitWidth(), 0);
API.set(BitToSet);
Op1 = ConstantInt::get(V->getContext(), API);
}
Value *Mul0 = NULL;