diff options
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCTargetObjectFile.cpp')
-rw-r--r-- | llvm/lib/Target/PowerPC/PPCTargetObjectFile.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCTargetObjectFile.cpp b/llvm/lib/Target/PowerPC/PPCTargetObjectFile.cpp index 870a4e3128a..a049dc3fda9 100644 --- a/llvm/lib/Target/PowerPC/PPCTargetObjectFile.cpp +++ b/llvm/lib/Target/PowerPC/PPCTargetObjectFile.cpp @@ -23,7 +23,7 @@ Initialize(MCContext &Ctx, const TargetMachine &TM) { } MCSection *PPC64LinuxTargetObjectFile::SelectSectionForGlobal( - const GlobalValue *GV, SectionKind Kind, const TargetMachine &TM) const { + const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const { // Here override ReadOnlySection to DataRelROSection for PPC64 SVR4 ABI // when we have a constant that contains global relocations. This is // necessary because of this ABI's handling of pointers to functions in @@ -39,13 +39,13 @@ MCSection *PPC64LinuxTargetObjectFile::SelectSectionForGlobal( // For more information, see the description of ELIMINATE_COPY_RELOCS in // GNU ld. if (Kind.isReadOnly()) { - const GlobalVariable *GVar = dyn_cast<GlobalVariable>(GV); + const auto *GVar = dyn_cast<GlobalVariable>(GO); if (GVar && GVar->isConstant() && GVar->getInitializer()->needsRelocation()) Kind = SectionKind::getReadOnlyWithRel(); } - return TargetLoweringObjectFileELF::SelectSectionForGlobal(GV, Kind, TM); + return TargetLoweringObjectFileELF::SelectSectionForGlobal(GO, Kind, TM); } const MCExpr *PPC64LinuxTargetObjectFile:: |