diff options
author | Chris Lattner <sabre@nondot.org> | 2010-01-23 06:53:23 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-01-23 06:53:23 +0000 |
commit | 152a29bfa6fa505182658d046bc75626e10d67c3 (patch) | |
tree | 349b6840002462d1d3f7cb83a8eb9ff0c1d1cc4b /lib/MC | |
parent | a5ad93a10a5435f21090b09edb6b3a7e44967648 (diff) | |
download | llvm-152a29bfa6fa505182658d046bc75626e10d67c3.tar.gz llvm-152a29bfa6fa505182658d046bc75626e10d67c3.tar.bz2 llvm-152a29bfa6fa505182658d046bc75626e10d67c3.tar.xz |
mcize visibility directives.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@94295 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/MC')
-rw-r--r-- | lib/MC/MCAsmInfo.cpp | 5 | ||||
-rw-r--r-- | lib/MC/MCAsmInfoCOFF.cpp | 4 | ||||
-rw-r--r-- | lib/MC/MCAsmInfoDarwin.cpp | 8 |
3 files changed, 11 insertions, 6 deletions
diff --git a/lib/MC/MCAsmInfo.cpp b/lib/MC/MCAsmInfo.cpp index ef6dd071e0..debccaf4b1 100644 --- a/lib/MC/MCAsmInfo.cpp +++ b/lib/MC/MCAsmInfo.cpp @@ -61,9 +61,8 @@ MCAsmInfo::MCAsmInfo() { WeakRefDirective = 0; WeakDefDirective = 0; LinkOnceDirective = 0; - // FIXME: These are ELFish - move to ELFMAI. - HiddenDirective = "\t.hidden\t"; - ProtectedDirective = "\t.protected\t"; + HiddenVisibilityAttr = MCSA_Hidden; + ProtectedVisibilityAttr = MCSA_Protected; AbsoluteDebugSectionOffsets = false; AbsoluteEHSectionOffsets = false; HasLEB128 = false; diff --git a/lib/MC/MCAsmInfoCOFF.cpp b/lib/MC/MCAsmInfoCOFF.cpp index 1b27bf026e..5ca66b56d5 100644 --- a/lib/MC/MCAsmInfoCOFF.cpp +++ b/lib/MC/MCAsmInfoCOFF.cpp @@ -22,11 +22,13 @@ MCAsmInfoCOFF::MCAsmInfoCOFF() { COMMDirectiveTakesAlignment = false; HasDotTypeDotSizeDirective = false; HasSingleParameterDotFile = false; - HiddenDirective = NULL; PrivateGlobalPrefix = "L"; // Prefix for private global symbols WeakRefDirective = "\t.weak\t"; LinkOnceDirective = "\t.linkonce same_size\n"; SetDirective = "\t.set\t"; + + // Doesn't support visibility: + HiddenVisibilityAttr = ProtectedVisibilityAttr = MCSA_Invalid; // Set up DWARF directives HasLEB128 = true; // Target asm supports leb128 directives (little-endian) diff --git a/lib/MC/MCAsmInfoDarwin.cpp b/lib/MC/MCAsmInfoDarwin.cpp index a66a83d014..8495aa44ec 100644 --- a/lib/MC/MCAsmInfoDarwin.cpp +++ b/lib/MC/MCAsmInfoDarwin.cpp @@ -32,12 +32,16 @@ MCAsmInfoDarwin::MCAsmInfoDarwin() { // Directives: WeakDefDirective = "\t.weak_definition "; WeakRefDirective = "\t.weak_reference "; - HiddenDirective = "\t.private_extern "; ZeroDirective = "\t.space\t"; // ".space N" emits N zeros. HasMachoZeroFillDirective = true; // Uses .zerofill HasStaticCtorDtorReferenceInStaticMode = true; SetDirective = "\t.set"; - ProtectedDirective = "\t.globl\t"; + + HiddenVisibilityAttr = MCSA_PrivateExtern; + // Doesn't support protected visibility. + ProtectedVisibilityAttr = MCSA_Global; + + HasDotTypeDotSizeDirective = false; HasNoDeadStrip = true; // Note: Even though darwin has the .lcomm directive, it is just a synonym for |