aboutsummaryrefslogtreecommitdiff
path: root/include/llvm/CodeGen
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-09-26 23:59:50 +0000
committerChris Lattner <sabre@nondot.org>2006-09-26 23:59:50 +0000
commit3ce9b67e0c0f171c6d09c19407930ce6989f1b9d (patch)
tree4441d4ed2e9d4efbcd0b093e7c0e8aeb3472ea42 /include/llvm/CodeGen
parent16f046a6cee08981084dc4339ceaf76b2e291b4c (diff)
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. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30619 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/CodeGen')
-rw-r--r--include/llvm/CodeGen/AsmPrinter.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/llvm/CodeGen/AsmPrinter.h b/include/llvm/CodeGen/AsmPrinter.h
index 386a8d53fd..4c34dcd21d 100644
--- a/include/llvm/CodeGen/AsmPrinter.h
+++ b/include/llvm/CodeGen/AsmPrinter.h
@@ -108,6 +108,14 @@ namespace llvm {
/// 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