aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2005-11-21 19:51:51 +0000
committerChris Lattner <sabre@nondot.org>2005-11-21 19:51:51 +0000
commit02d09206ee2a215d0428fa4991d1f1d579783454 (patch)
tree8d5e29c1b7633100f0623435f8bfc672638da5d5
parent8fccc97b0bb4297ce5c6a74b1562634fe3e38d7f (diff)
downloadexternal_llvm-02d09206ee2a215d0428fa4991d1f1d579783454.zip
external_llvm-02d09206ee2a215d0428fa4991d1f1d579783454.tar.gz
external_llvm-02d09206ee2a215d0428fa4991d1f1d579783454.tar.bz2
Add some more directives
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@24474 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--include/llvm/CodeGen/AsmPrinter.h19
1 files changed, 18 insertions, 1 deletions
diff --git a/include/llvm/CodeGen/AsmPrinter.h b/include/llvm/CodeGen/AsmPrinter.h
index b6ed3a5..9f9b47e 100644
--- a/include/llvm/CodeGen/AsmPrinter.h
+++ b/include/llvm/CodeGen/AsmPrinter.h
@@ -134,6 +134,20 @@ namespace llvm {
/// before emitting the constant pool for a function.
const char *ConstantPoolSection; // Defaults to "\t.section .rodata\n"
+ //===--- Global Variable Emission Directives --------------------------===//
+
+ /// LCOMMDirective - This is the name of a directive (if supported) that can
+ /// be used to efficiently declare a local (internal) block of zero
+ /// initialized data in the .bss/.data section. The syntax expected is:
+ /// <LCOMMDirective> SYMBOLNAME LENGTHINBYTES, ALIGNMENT
+ const char *LCOMMDirective; // Defaults to null.
+
+ const char *COMMDirective; // Defaults to "\t.comm\t".
+
+ /// COMMDirectiveTakesAlignment - True if COMMDirective take a third
+ /// argument that specifies the alignment of the declaration.
+ bool COMMDirectiveTakesAlignment; // Defaults to true.
+
AsmPrinter(std::ostream &o, TargetMachine &tm)
: FunctionNumber(0), O(o), TM(tm),
CommentString("#"),
@@ -153,7 +167,10 @@ namespace llvm {
AlignDirective("\t.align\t"),
AlignmentIsInBytes(true),
SwitchToSectionDirective("\t.section\t"),
- ConstantPoolSection("\t.section .rodata\n") {
+ ConstantPoolSection("\t.section .rodata\n"),
+ LCOMMDirective(0),
+ COMMDirective("\t.comm\t"),
+ COMMDirectiveTakesAlignment(true) {
}
/// SwitchSection - Switch to the specified section of the executable if we