From 726d397a8cc48a5cb5d2f8a0fe10f7f17f7d4afc Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Wed, 10 Feb 2010 00:36:00 +0000 Subject: print all the newlines at the end of instructions with OutStreamer.AddBlankLine instead of textually. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95734 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/AsmPrinter/AsmPrinter.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'lib/CodeGen/AsmPrinter') diff --git a/lib/CodeGen/AsmPrinter/AsmPrinter.cpp b/lib/CodeGen/AsmPrinter/AsmPrinter.cpp index 570916f7b7..25e0818404 100644 --- a/lib/CodeGen/AsmPrinter/AsmPrinter.cpp +++ b/lib/CodeGen/AsmPrinter/AsmPrinter.cpp @@ -1442,7 +1442,8 @@ void AsmPrinter::printInlineAsm(const MachineInstr *MI) const { } } } - O << "\n\t" << MAI->getCommentString() << MAI->getInlineAsmEnd() << '\n'; + O << "\n\t" << MAI->getCommentString() << MAI->getInlineAsmEnd(); + OutStreamer.AddBlankLine(); } /// printImplicitDef - This method prints the specified machine instruction @@ -1451,7 +1452,8 @@ void AsmPrinter::printImplicitDef(const MachineInstr *MI) const { if (!VerboseAsm) return; O.PadToColumn(MAI->getCommentColumn()); O << MAI->getCommentString() << " implicit-def: " - << TRI->getName(MI->getOperand(0).getReg()) << '\n'; + << TRI->getName(MI->getOperand(0).getReg()); + OutStreamer.AddBlankLine(); } void AsmPrinter::printKill(const MachineInstr *MI) const { @@ -1463,14 +1465,14 @@ void AsmPrinter::printKill(const MachineInstr *MI) const { assert(op.isReg() && "KILL instruction must have only register operands"); O << ' ' << TRI->getName(op.getReg()) << (op.isDef() ? "" : ""); } - O << '\n'; + OutStreamer.AddBlankLine(); } /// printLabel - This method prints a local label used by debug and /// exception handling tables. void AsmPrinter::printLabelInst(const MachineInstr *MI) const { printLabel(MI->getOperand(0).getImm()); - O << '\n'; + OutStreamer.AddBlankLine(); } void AsmPrinter::printLabel(unsigned Id) const { -- cgit v1.2.3