diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp | 6 | ||||
-rw-r--r-- | lib/Target/TargetLoweringObjectFile.cpp | 2 | ||||
-rw-r--r-- | lib/Target/X86/X86TargetObjectFile.cpp | 2 | ||||
-rw-r--r-- | lib/Target/X86/X86TargetObjectFile.h | 2 |
4 files changed, 6 insertions, 6 deletions
diff --git a/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp b/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp index 398718dc17..e846232370 100644 --- a/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp +++ b/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp @@ -1358,7 +1358,7 @@ void CompileUnit::createGlobalVariableDIE(const MDNode *N) { unsigned PointerSize = Asm->getDataLayout().getPointerSize(); assert((PointerSize == 4 || PointerSize == 8) && "Add support for other sizes if necessary"); - const MCSymbolRefExpr *Ref = + const MCExpr *Expr = Asm->getObjFileLowering().getDebugThreadLocalSymbol(Sym); // Based on GCC's support for TLS: if (!DD->useSplitDwarf()) { @@ -1366,10 +1366,10 @@ void CompileUnit::createGlobalVariableDIE(const MDNode *N) { addUInt(Block, 0, dwarf::DW_FORM_data1, PointerSize == 4 ? dwarf::DW_OP_const4u : dwarf::DW_OP_const8u); // 2) containing the (relocated) address of the TLS variable - addExpr(Block, 0, dwarf::DW_FORM_udata, Ref); + addExpr(Block, 0, dwarf::DW_FORM_udata, Expr); } else { addUInt(Block, 0, dwarf::DW_FORM_data1, dwarf::DW_OP_GNU_const_index); - addUInt(Block, 0, dwarf::DW_FORM_udata, DU->getAddrPoolIndex(Ref)); + addUInt(Block, 0, dwarf::DW_FORM_udata, DU->getAddrPoolIndex(Expr)); } // 3) followed by a custom OP to tell the debugger about TLS (presumably) addUInt(Block, 0, dwarf::DW_FORM_data1, dwarf::DW_OP_lo_user); diff --git a/lib/Target/TargetLoweringObjectFile.cpp b/lib/Target/TargetLoweringObjectFile.cpp index fc50aa5192..cd810b624f 100644 --- a/lib/Target/TargetLoweringObjectFile.cpp +++ b/lib/Target/TargetLoweringObjectFile.cpp @@ -318,7 +318,7 @@ getTTypeReference(const MCSymbolRefExpr *Sym, unsigned Encoding, } } -const MCSymbolRefExpr *TargetLoweringObjectFile::getDebugThreadLocalSymbol(const MCSymbol *Sym) const { +const MCExpr *TargetLoweringObjectFile::getDebugThreadLocalSymbol(const MCSymbol *Sym) const { // FIXME: It's not clear what, if any, default this should have - perhaps a // null return could mean 'no location' & we should just do that here. return MCSymbolRefExpr::Create(Sym, *Ctx); diff --git a/lib/Target/X86/X86TargetObjectFile.cpp b/lib/Target/X86/X86TargetObjectFile.cpp index a00e8d4f4d..a19c5a601e 100644 --- a/lib/Target/X86/X86TargetObjectFile.cpp +++ b/lib/Target/X86/X86TargetObjectFile.cpp @@ -48,7 +48,7 @@ X86LinuxTargetObjectFile::Initialize(MCContext &Ctx, const TargetMachine &TM) { InitializeELF(TM.Options.UseInitArray); } -const MCSymbolRefExpr * +const MCExpr * X86LinuxTargetObjectFile::getDebugThreadLocalSymbol( const MCSymbol *Sym) const { return MCSymbolRefExpr::Create(Sym, MCSymbolRefExpr::VK_DTPOFF, getContext()); diff --git a/lib/Target/X86/X86TargetObjectFile.h b/lib/Target/X86/X86TargetObjectFile.h index 7baedd2ddf..79c861d2e1 100644 --- a/lib/Target/X86/X86TargetObjectFile.h +++ b/lib/Target/X86/X86TargetObjectFile.h @@ -38,7 +38,7 @@ namespace llvm { virtual void Initialize(MCContext &Ctx, const TargetMachine &TM); /// \brief Describe a TLS variable address within debug info. - virtual const MCSymbolRefExpr *getDebugThreadLocalSymbol(const MCSymbol *Sym) const; + virtual const MCExpr *getDebugThreadLocalSymbol(const MCSymbol *Sym) const; }; } // end namespace llvm |