diff options
Diffstat (limited to 'llvm/lib/Target/TargetLoweringObjectFile.cpp')
-rw-r--r-- | llvm/lib/Target/TargetLoweringObjectFile.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Target/TargetLoweringObjectFile.cpp b/llvm/lib/Target/TargetLoweringObjectFile.cpp index 26e9f9e..7d9b926 100644 --- a/llvm/lib/Target/TargetLoweringObjectFile.cpp +++ b/llvm/lib/Target/TargetLoweringObjectFile.cpp @@ -129,7 +129,7 @@ MCSymbol *TargetLoweringObjectFile::getSymbolWithGlobalValueBase( assert(!Suffix.empty()); SmallString<60> NameStr; - NameStr += GV->getParent()->getDataLayout().getPrivateGlobalPrefix(); + NameStr += GV->getDataLayout().getPrivateGlobalPrefix(); TM.getNameWithPrefix(NameStr, GV, *Mang); NameStr.append(Suffix.begin(), Suffix.end()); return getContext().getOrCreateSymbol(NameStr); @@ -284,7 +284,7 @@ SectionKind TargetLoweringObjectFile::getKindForGlobal(const GlobalObject *GO, // a section for this size, use it, otherwise use the arbitrary sized // mergable section. switch ( - GVar->getParent()->getDataLayout().getTypeAllocSize(C->getType())) { + GVar->getDataLayout().getTypeAllocSize(C->getType())) { case 4: return SectionKind::getMergeableConst4(); case 8: return SectionKind::getMergeableConst8(); case 16: return SectionKind::getMergeableConst16(); @@ -350,7 +350,7 @@ TargetLoweringObjectFile::SectionForGlobal(const GlobalObject *GO, MCSection *TargetLoweringObjectFile::getSectionForJumpTable( const Function &F, const TargetMachine &TM) const { Align Alignment(1); - return getSectionForConstant(F.getParent()->getDataLayout(), + return getSectionForConstant(F.getDataLayout(), SectionKind::getReadOnly(), /*C=*/nullptr, Alignment); } |