Teach MachineBasicBlock::print() to annotate instructions and blocks with

SlotIndexes when available.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@117392 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Jakob Stoklund Olesen
2010-10-26 20:21:46 +00:00
parent dbcc2e119d
commit f4a1e1a69f
6 changed files with 32 additions and 22 deletions

View File

@ -280,7 +280,7 @@ void MachineFunction::dump() const {
print(dbgs());
}
void MachineFunction::print(raw_ostream &OS) const {
void MachineFunction::print(raw_ostream &OS, SlotIndexes *Indexes) const {
OS << "# Machine code for function " << Fn->getName() << ":\n";
// Print Frame Information
@ -329,7 +329,7 @@ void MachineFunction::print(raw_ostream &OS) const {
for (const_iterator BB = begin(), E = end(); BB != E; ++BB) {
OS << '\n';
BB->print(OS);
BB->print(OS, Indexes);
}
OS << "\n# End machine code for function " << Fn->getName() << ".\n\n";