diff --git a/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp b/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp index 860d5005672..c61afe3fc71 100644 --- a/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp +++ b/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp @@ -816,7 +816,8 @@ void X86ATTAsmPrinter::PrintGlobalVariable(const GlobalVariable* GVar) { EmitAlignment(Align, GVar); O << name << ":"; if (VerboseAsm) { - O << "\t\t\t\t" << TAI->getCommentString() << ' '; + O.PadToColumn(TAI->getCommentColumn(), 1); + O << TAI->getCommentString() << ' '; PrintUnmangledNameSafely(GVar, O); } O << '\n'; @@ -837,7 +838,8 @@ void X86ATTAsmPrinter::PrintGlobalVariable(const GlobalVariable* GVar) { O << ',' << (TAI->getAlignmentIsInBytes() ? (1 << Align) : Align); } if (VerboseAsm) { - O << "\t\t" << TAI->getCommentString() << ' '; + O.PadToColumn(TAI->getCommentColumn(), 1); + O << TAI->getCommentString() << ' '; PrintUnmangledNameSafely(GVar, O); } O << '\n'; @@ -880,7 +882,8 @@ void X86ATTAsmPrinter::PrintGlobalVariable(const GlobalVariable* GVar) { EmitAlignment(Align, GVar); O << name << ":"; if (VerboseAsm){ - O << "\t\t\t\t" << TAI->getCommentString() << ' '; + O.PadToColumn(TAI->getCommentColumn(), 1); + O << TAI->getCommentString() << ' '; PrintUnmangledNameSafely(GVar, O); } O << '\n'; diff --git a/lib/Target/X86/AsmPrinter/X86IntelAsmPrinter.cpp b/lib/Target/X86/AsmPrinter/X86IntelAsmPrinter.cpp index 153f41abf07..8b4ca58fb25 100644 --- a/lib/Target/X86/AsmPrinter/X86IntelAsmPrinter.cpp +++ b/lib/Target/X86/AsmPrinter/X86IntelAsmPrinter.cpp @@ -524,7 +524,8 @@ void X86IntelAsmPrinter::PrintGlobalVariable(const GlobalVariable *GV) { O << name << ":"; if (VerboseAsm) - O << "\t\t\t\t" << TAI->getCommentString() + O.PadToColumn(TAI->getCommentColumn(), 1); + O << TAI->getCommentString() << " " << GV->getName(); O << '\n';