summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--llvm/include/llvm/Target/TargetAsmInfo.h7
-rw-r--r--llvm/lib/Target/TargetAsmInfo.cpp1
2 files changed, 8 insertions, 0 deletions
diff --git a/llvm/include/llvm/Target/TargetAsmInfo.h b/llvm/include/llvm/Target/TargetAsmInfo.h
index 6682c31923a..c922d4c3d9b 100644
--- a/llvm/include/llvm/Target/TargetAsmInfo.h
+++ b/llvm/include/llvm/Target/TargetAsmInfo.h
@@ -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;
}
diff --git a/llvm/lib/Target/TargetAsmInfo.cpp b/llvm/lib/Target/TargetAsmInfo.cpp
index 8b818fb3ea4..c2f3e034363 100644
--- a/llvm/lib/Target/TargetAsmInfo.cpp
+++ b/llvm/lib/Target/TargetAsmInfo.cpp
@@ -62,6 +62,7 @@ TargetAsmInfo::TargetAsmInfo() :
HasDotTypeDotSizeDirective(true),
UsedDirective(0),
WeakRefDirective(0),
+ HiddenDirective("\t.hidden\t"),
HasLEB128(false),
HasDotLoc(false),
HasDotFile(false),
OpenPOWER on IntegriCloud