add a new HiddenDirective member for handling visibility.
authorChris Lattner <sabre@nondot.org>
Sun, 14 Jan 2007 06:27:21 +0000 (06:27 +0000)
committerChris Lattner <sabre@nondot.org>
Sun, 14 Jan 2007 06:27:21 +0000 (06:27 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33197 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Target/TargetAsmInfo.h
lib/Target/TargetAsmInfo.cpp

index 6682c31923aa86afac2a7c843fe69328a205c69b..c922d4c3d9bfbcaf91c1353137208ab864a280ce 100644 (file)
@@ -216,6 +216,10 @@ namespace llvm {
     /// global as being a weak undefined symbol.
     const char *WeakRefDirective;         // Defaults to null.
     
+    /// HiddenDirective - This directive, if non-null, is used to declare a
+    /// global or function as having hidden visibility.
+    const char *HiddenDirective;          // Defaults to "\t.hidden\t".
+    
     //===--- Dwarf Emission Directives -----------------------------------===//
 
     /// HasLEB128 - True if target asm supports leb128 directives.
@@ -429,6 +433,9 @@ namespace llvm {
     const char *getWeakRefDirective() const {
       return WeakRefDirective;
     }
+    const char *getHiddenDirective() const {
+      return HiddenDirective;
+    }
     bool hasLEB128() const {
       return HasLEB128;
     }
index 8b818fb3ea477bc76aa6394d94c64f676d92ccff..c2f3e034363847c8d2d7334264cadaa526965477 100644 (file)
@@ -62,6 +62,7 @@ TargetAsmInfo::TargetAsmInfo() :
   HasDotTypeDotSizeDirective(true),
   UsedDirective(0),
   WeakRefDirective(0),
+  HiddenDirective("\t.hidden\t"),
   HasLEB128(false),
   HasDotLoc(false),
   HasDotFile(false),