diff options
Diffstat (limited to 'lib/Target/X86')
-rw-r--r-- | lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp | 5 | ||||
-rw-r--r-- | lib/Target/X86/AsmPrinter/X86MCInstLower.cpp | 3 | ||||
-rw-r--r-- | lib/Target/X86/X86InstrInfo.h | 8 | ||||
-rw-r--r-- | lib/Target/X86/X86Subtarget.cpp | 9 |
4 files changed, 3 insertions, 22 deletions
diff --git a/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp b/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp index 70f6a27..ad91fad 100644 --- a/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp +++ b/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp @@ -306,7 +306,6 @@ void X86ATTAsmPrinter::printSymbolOperand(const MachineOperand &MO) { Suffix = "$stub"; else if (MO.getTargetFlags() == X86II::MO_DARWIN_NONLAZY || MO.getTargetFlags() == X86II::MO_DARWIN_NONLAZY_PIC_BASE || - MO.getTargetFlags() == X86II::MO_DARWIN_HIDDEN_NONLAZY || MO.getTargetFlags() == X86II::MO_DARWIN_HIDDEN_NONLAZY_PIC_BASE) Suffix = "$non_lazy_ptr"; @@ -321,8 +320,7 @@ void X86ATTAsmPrinter::printSymbolOperand(const MachineOperand &MO) { if (MO.getTargetFlags() == X86II::MO_DARWIN_NONLAZY || MO.getTargetFlags() == X86II::MO_DARWIN_NONLAZY_PIC_BASE) GVStubs[Name] = Mang->getMangledName(GV); - else if (MO.getTargetFlags() == X86II::MO_DARWIN_HIDDEN_NONLAZY || - MO.getTargetFlags() == X86II::MO_DARWIN_HIDDEN_NONLAZY_PIC_BASE) + else if (MO.getTargetFlags() == X86II::MO_DARWIN_HIDDEN_NONLAZY_PIC_BASE) HiddenGVStubs[Name] = Mang->getMangledName(GV); else if (MO.getTargetFlags() == X86II::MO_DARWIN_STUB) FnStubs[Name] = Mang->getMangledName(GV); @@ -360,7 +358,6 @@ void X86ATTAsmPrinter::printSymbolOperand(const MachineOperand &MO) { case X86II::MO_NO_FLAG: // No flag. break; case X86II::MO_DARWIN_NONLAZY: - case X86II::MO_DARWIN_HIDDEN_NONLAZY: case X86II::MO_DLLIMPORT: case X86II::MO_DARWIN_STUB: // These affect the name of the symbol, not any suffix. diff --git a/lib/Target/X86/AsmPrinter/X86MCInstLower.cpp b/lib/Target/X86/AsmPrinter/X86MCInstLower.cpp index 49c42e5..89fac7a 100644 --- a/lib/Target/X86/AsmPrinter/X86MCInstLower.cpp +++ b/lib/Target/X86/AsmPrinter/X86MCInstLower.cpp @@ -62,7 +62,6 @@ MCSymbol *X86ATTAsmPrinter::GetGlobalAddressSymbol(const MachineOperand &MO) { Suffix = "$stub"; else if (MO.getTargetFlags() == X86II::MO_DARWIN_NONLAZY || MO.getTargetFlags() == X86II::MO_DARWIN_NONLAZY_PIC_BASE || - MO.getTargetFlags() == X86II::MO_DARWIN_HIDDEN_NONLAZY || MO.getTargetFlags() == X86II::MO_DARWIN_HIDDEN_NONLAZY_PIC_BASE) Suffix = "$non_lazy_ptr"; @@ -84,7 +83,6 @@ MCSymbol *X86ATTAsmPrinter::GetGlobalAddressSymbol(const MachineOperand &MO) { case X86II::MO_DARWIN_NONLAZY_PIC_BASE: GVStubs[Name] = Mang->getMangledName(GV); break; - case X86II::MO_DARWIN_HIDDEN_NONLAZY: case X86II::MO_DARWIN_HIDDEN_NONLAZY_PIC_BASE: HiddenGVStubs[Name] = Mang->getMangledName(GV); break; @@ -169,7 +167,6 @@ MCOperand X86ATTAsmPrinter::LowerSymbolOperand(const MachineOperand &MO, // These affect the name of the symbol, not any suffix. case X86II::MO_DARWIN_NONLAZY: - case X86II::MO_DARWIN_HIDDEN_NONLAZY: case X86II::MO_DLLIMPORT: case X86II::MO_DARWIN_STUB: case X86II::MO_TLSGD: diff --git a/lib/Target/X86/X86InstrInfo.h b/lib/Target/X86/X86InstrInfo.h index 2e0235a..fd49844 100644 --- a/lib/Target/X86/X86InstrInfo.h +++ b/lib/Target/X86/X86InstrInfo.h @@ -170,16 +170,11 @@ namespace X86II { /// a PIC-base-relative reference to a non-hidden dyld lazy pointer stub. MO_DARWIN_NONLAZY_PIC_BASE = 15, - /// MO_DARWIN_HIDDEN_NONLAZY - On a symbol operand "FOO", this indicates - /// that the reference is actually to the "FOO$non_lazy_ptr" symbol, which - /// is a non-PIC-base-relative reference to a hidden dyld lazy pointer stub. - MO_DARWIN_HIDDEN_NONLAZY = 16, - /// MO_DARWIN_HIDDEN_NONLAZY_PIC_BASE - On a symbol operand "FOO", this /// indicates that the reference is actually to "FOO$non_lazy_ptr -PICBASE", /// which is a PIC-base-relative reference to a hidden dyld lazy pointer /// stub. - MO_DARWIN_HIDDEN_NONLAZY_PIC_BASE = 17 + MO_DARWIN_HIDDEN_NONLAZY_PIC_BASE = 16 }; } @@ -193,7 +188,6 @@ inline static bool isGlobalStubReference(unsigned char TargetFlag) { case X86II::MO_DARWIN_NONLAZY_PIC_BASE: // Normal $non_lazy_ptr ref. case X86II::MO_DARWIN_NONLAZY: // Normal $non_lazy_ptr ref. case X86II::MO_DARWIN_HIDDEN_NONLAZY_PIC_BASE: // Hidden $non_lazy_ptr ref. - case X86II::MO_DARWIN_HIDDEN_NONLAZY: // Hidden $non_lazy_ptr ref. return true; default: return false; diff --git a/lib/Target/X86/X86Subtarget.cpp b/lib/Target/X86/X86Subtarget.cpp index 5e4a6ba..fb76aeb 100644 --- a/lib/Target/X86/X86Subtarget.cpp +++ b/lib/Target/X86/X86Subtarget.cpp @@ -108,14 +108,7 @@ ClassifyGlobalReference(const GlobalValue *GV, const TargetMachine &TM) const { // normal $non_lazy_ptr stub because this symbol might be resolved late. if (!GV->hasHiddenVisibility()) // Non-hidden $non_lazy_ptr reference. return X86II::MO_DARWIN_NONLAZY; - - // If symbol visibility is hidden, we have a stub for common symbol - // references and external declarations. - if (isDecl || GV->hasCommonLinkage()) { - // Hidden $non_lazy_ptr reference. - return X86II::MO_DARWIN_HIDDEN_NONLAZY; - } - + // Otherwise, no stub. return X86II::MO_NO_FLAG; } |