[llvm-commits] [llvm] r124814 - /llvm/trunk/lib/CodeGen/SlotIndexes.cpp
Jakob Stoklund Olesen
stoklund at 2pi.dk
Thu Feb 3 12:29:41 PST 2011
Author: stoklund
Date: Thu Feb 3 14:29:41 2011
New Revision: 124814
URL: http://llvm.org/viewvc/llvm-project?rev=124814&view=rev
Log:
Tweak debug output from SlotIndexes.
Modified:
llvm/trunk/lib/CodeGen/SlotIndexes.cpp
Modified: llvm/trunk/lib/CodeGen/SlotIndexes.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SlotIndexes.cpp?rev=124814&r1=124813&r2=124814&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SlotIndexes.cpp (original)
+++ llvm/trunk/lib/CodeGen/SlotIndexes.cpp Thu Feb 3 14:29:41 2011
@@ -158,6 +158,7 @@
// resulting numbering will match what would have been generated by the
// pass during the initial numbering of the function if the new instructions
// had been present.
+ DEBUG(dbgs() << "\n*** Renumbering SlotIndexes ***\n");
functionSize = 0;
unsigned index = 0;
@@ -203,7 +204,10 @@
// Print a SlotIndex to a raw_ostream.
void SlotIndex::print(raw_ostream &os) const {
- os << entry().getIndex() << "LudS"[getSlot()];
+ if (isValid())
+ os << entry().getIndex() << "LudS"[getSlot()];
+ else
+ os << "invalid";
}
// Dump a SlotIndex to stderr.
More information about the llvm-commits
mailing list