summaryrefslogtreecommitdiffstats
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
commitf3925438e5747b340539bba35f0a35c09ee1104f (patch)
tree70cf030b42fb8de83a2af67ac61b0a86046e01e3
parentb04ef0cfbc406d8dd3317a40d0b281ed537b02d3 (diff)
downloadbcm5719-llvm-f3925438e5747b340539bba35f0a35c09ee1104f.tar.gz
bcm5719-llvm-f3925438e5747b340539bba35f0a35c09ee1104f.zip
Move the verbose asm output up a bit so it can be used in the special cases
as well. llvm-svn: 104642
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp b/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
index 8a5fe4d3716..5a0c27b300a 100644
--- a/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
+++ b/llvm/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());
OpenPOWER on IntegriCloud