mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-26 04:32:44 +01:00
[MergeICmps][NFC] Improve logging.
llvm-svn: 326683
This commit is contained in:
parent
fd8b3ce3b0
commit
3e66b31c6a
@ -289,13 +289,15 @@ BCECmpChain::BCECmpChain(const std::vector<BasicBlock *> &Blocks, PHINode &Phi)
|
||||
return;
|
||||
}
|
||||
if (Comparison.doesOtherWork()) {
|
||||
DEBUG(dbgs() << "block does extra work besides compare\n");
|
||||
DEBUG(dbgs() << "block '" << Comparison.BB->getName()
|
||||
<< "' does extra work besides compare\n");
|
||||
if (BlockIdx == 0) { // First block.
|
||||
// TODO(courbet): The first block can do other things, and we should
|
||||
// split them apart in a separate block before the comparison chain.
|
||||
// Right now we just discard it and make the chain shorter.
|
||||
DEBUG(dbgs()
|
||||
<< "ignoring first block that does extra work besides compare\n");
|
||||
<< "ignoring first block '" << Comparison.BB->getName()
|
||||
<< "' that does extra work besides compare\n");
|
||||
continue;
|
||||
}
|
||||
// TODO(courbet): Right now we abort the whole chain. We could be
|
||||
@ -323,11 +325,11 @@ BCECmpChain::BCECmpChain(const std::vector<BasicBlock *> &Blocks, PHINode &Phi)
|
||||
// We could still merge bb1 and bb2 though.
|
||||
return;
|
||||
}
|
||||
DEBUG(dbgs() << "*Found cmp of " << Comparison.SizeBits()
|
||||
<< " bits between " << Comparison.Lhs().Base() << " + "
|
||||
<< Comparison.Lhs().Offset << " and "
|
||||
<< Comparison.Rhs().Base() << " + " << Comparison.Rhs().Offset
|
||||
<< "\n");
|
||||
DEBUG(dbgs() << "Block '" << Comparison.BB->getName()<< "': Found cmp of "
|
||||
<< Comparison.SizeBits() << " bits between "
|
||||
<< Comparison.Lhs().Base() << " + " << Comparison.Lhs().Offset
|
||||
<< " and " << Comparison.Rhs().Base() << " + "
|
||||
<< Comparison.Rhs().Offset << "\n");
|
||||
DEBUG(dbgs() << "\n");
|
||||
Comparisons.push_back(Comparison);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user