Fix AsmPrinter crashes with assertion. Bug 15318 in Bugzilla

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@177472 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Hao Liu 2013-03-20 01:46:36 +00:00
parent 4776bce28c
commit b631a41177

View File

@ -3311,10 +3311,8 @@ namespace {
significand = significand.udiv(divisor);
// Truncate the significand down to its active bit count, but
// don't try to drop below 32.
unsigned newPrecision = std::max(32U, significand.getActiveBits());
significand = significand.trunc(newPrecision);
// Truncate the significand down to its active bit count.
significand = significand.trunc(significand.getActiveBits());
}