aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorEric Christopher <echristo@apple.com>2010-05-25 21:49:43 +0000
committerEric Christopher <echristo@apple.com>2010-05-25 21:49:43 +0000
commit3fe79fd1451918e661b45268de5610b9657ae72c (patch)
tree9c101f50244e18a08d887e48a0a3080502a84eb4 /lib
parentbdfd6ab89d0bcefa2ca91a87da5fa2a03bcde305 (diff)
downloadexternal_llvm-3fe79fd1451918e661b45268de5610b9657ae72c.zip
external_llvm-3fe79fd1451918e661b45268de5610b9657ae72c.tar.gz
external_llvm-3fe79fd1451918e661b45268de5610b9657ae72c.tar.bz2
Move the verbose asm output up a bit so it can be used in the special cases
as well. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104642 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/CodeGen/AsmPrinter/AsmPrinter.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/CodeGen/AsmPrinter/AsmPrinter.cpp b/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
index 8a5fe4d..5a0c27b 100644
--- a/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
+++ b/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
@@ -241,6 +241,12 @@ void AsmPrinter::EmitGlobalVariable(const GlobalVariable *GV) {
if (EmitSpecialLLVMGlobal(GV))
return;
+ if (isVerbose()) {
+ WriteAsOperand(OutStreamer.GetCommentOS(), GV,
+ /*PrintType=*/false, GV->getParent());
+ OutStreamer.GetCommentOS() << '\n';
+ }
+
MCSymbol *GVSym = Mang->getSymbol(GV);
EmitVisibility(GVSym, GV->getVisibility());
@@ -361,11 +367,6 @@ void AsmPrinter::EmitGlobalVariable(const GlobalVariable *GV) {
EmitLinkage(GV->getLinkage(), GVSym);
EmitAlignment(AlignLog, GV);
- if (isVerbose()) {
- WriteAsOperand(OutStreamer.GetCommentOS(), GV,
- /*PrintType=*/false, GV->getParent());
- OutStreamer.GetCommentOS() << '\n';
- }
OutStreamer.EmitLabel(GVSym);
EmitGlobalConstant(GV->getInitializer());