Changes in directory llvm/lib/CodeGen:

AsmPrinter.cpp updated: 1.63 -> 1.64
---
Log message:

Extend printBasicBlockLabel a bit so that it can be used to print all 
basic block labels, consolidating the code to do so in one place for each
target.


---
Diffs of the changes:  (+8 -3)

 AsmPrinter.cpp |   11 ++++++++---
 1 files changed, 8 insertions(+), 3 deletions(-)


Index: llvm/lib/CodeGen/AsmPrinter.cpp
diff -u llvm/lib/CodeGen/AsmPrinter.cpp:1.63 
llvm/lib/CodeGen/AsmPrinter.cpp:1.64
--- llvm/lib/CodeGen/AsmPrinter.cpp:1.63        Mon May  1 22:58:45 2006
+++ llvm/lib/CodeGen/AsmPrinter.cpp     Tue May  2 00:37:32 2006
@@ -728,9 +728,14 @@
 
 /// printBasicBlockLabel - This method prints the label for the specified
 /// MachineBasicBlock
-void AsmPrinter::printBasicBlockLabel(const MachineBasicBlock *MBB) const {
+void AsmPrinter::printBasicBlockLabel(const MachineBasicBlock *MBB,
+                                      bool printColon,
+                                      bool printComment) const {
   O << PrivateGlobalPrefix << "LBB" 
     << Mang->getValueName(MBB->getParent()->getFunction())
-    << "_" << MBB->getNumber() << '\t' << CommentString
-    << MBB->getBasicBlock()->getName();
+    << "_" << MBB->getNumber();
+  if (printColon)
+    O << ':';
+  if (printComment)
+    O << '\t' << CommentString << MBB->getBasicBlock()->getName();
 }



_______________________________________________
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

Reply via email to