1
0
mirror of https://github.com/c64scene-ar/llvm-6502.git synced 2025-04-14 06:37:33 +00:00

Add additional check to ensure that iv is canonicalized.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@55682 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Devang Patel 2008-09-03 00:29:13 +00:00
parent a9348dc7ac
commit e925ccc553

@ -1935,6 +1935,7 @@ void LoopStrengthReduce::OptimizeIVType(Loop *L) {
ConstantInt *CInit = dyn_cast<ConstantInt>(PHI->getIncomingValue(Entry));
if (!CInit) return;
if (!CInit->isZero()) return;
bool signedInit = CInit->getValue().isNegative();