[llvm-commits] CVS: llvm/include/llvm/CodeGen/AsmPrinter.h

Chris Lattner sabre at nondot.org
Tue Sep 26 17:00:05 PDT 2006



Changes in directory llvm/include/llvm/CodeGen:

AsmPrinter.h updated: 1.49 -> 1.50
---
Log message:

Add support for ${:comment}, which expands to the current target's comment
character, and ${:uid} which expands to a unique ID for the MachineInstr. 
More can be added if/when they are needed.



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

 AsmPrinter.h |    8 ++++++++
 1 files changed, 8 insertions(+)


Index: llvm/include/llvm/CodeGen/AsmPrinter.h
diff -u llvm/include/llvm/CodeGen/AsmPrinter.h:1.49 llvm/include/llvm/CodeGen/AsmPrinter.h:1.50
--- llvm/include/llvm/CodeGen/AsmPrinter.h:1.49	Mon Sep 25 22:38:18 2006
+++ llvm/include/llvm/CodeGen/AsmPrinter.h	Tue Sep 26 18:59:50 2006
@@ -108,6 +108,14 @@
     /// doFinalization - Shut down the asmprinter.  If you override this in your
     /// pass, you must make sure to call it explicitly.
     bool doFinalization(Module &M);
+    
+    /// PrintSpecial - Print information related to the specified machine instr
+    /// that is independent of the operand, and may be independent of the instr
+    /// itself.  This can be useful for portably encoding the comment character
+    /// or other bits of target-specific knowledge into the asmstrings.  The
+    /// syntax used is ${:comment}.  Targets can override this to add support
+    /// for their own strange codes.
+    virtual void PrintSpecial(const MachineInstr *MI, const char *Code);
 
     /// PrintAsmOperand - Print the specified operand of MI, an INLINEASM
     /// instruction, using the specified assembler variant.  Targets should






More information about the llvm-commits mailing list