[PATCH] D13566: [ELF2] PPC64 needs to delay local-call relocations until after the function-descriptor values are known

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 12 15:31:08 PDT 2015


ruiu added inline comments.

================
Comment at: ELF/Writer.cpp:479-480
@@ -475,1 +478,4 @@
+  // relocations.
+  PPC64TargetInfo::OpdPtr =
+    Map.lookup({".opd", SHT_PROGBITS, SHF_WRITE | SHF_ALLOC});
 }
----------------
hfinkel wrote:
> ruiu wrote:
> >   if (OutputSection<ELFT> *Sec = Map.lookup({".opd", ...))
> >     Target->Opd = reinterpret_cast<OutputSection<ELF64BE> *>(Sec);
> Do you want me to move Opd and OpdBuf into TargetInfo to make this work?
> 
Ah, then this?

  if (OutputSection<ELFT> *Sec = Map.lookup({".opd", ...))
    reinterpet_cast<PPC64TargetInfo *>(Target)->Opd = reinterpret_cast<OutputSection<ELF64BE> *>(Sec);



http://reviews.llvm.org/D13566





More information about the llvm-commits mailing list