[lld] r250555 - [ELF2] getLocalRelTarget should handle R_PPC64_TOC directly

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 16 15:45:47 PDT 2015


On Fri, Oct 16, 2015 at 3:43 PM, Hal Finkel via llvm-commits <
llvm-commits at lists.llvm.org> wrote:

> ----- Original Message -----
> > From: "Rafael EspĂ­ndola" <rafael.espindola at gmail.com>
> > To: "Hal Finkel" <hfinkel at anl.gov>
> > Cc: "llvm-commits" <llvm-commits at lists.llvm.org>
> > Sent: Friday, October 16, 2015 5:40:49 PM
> > Subject: Re: [lld] r250555 - [ELF2] getLocalRelTarget should handle
> R_PPC64_TOC directly
> >
> > > When why does the code in RelocationSection<ELFT>::writeTo have
> > > this?
> > >
> > >   bool IsMips64EL = Relocs[0].C.getFile()->getObj().isMips64EL();
> > >
> > > I thought this might return a different result from
> > > File.getObj().isMips64EL() [but then forgot to ask].
> >
> > The code is there just to factor out IsMips64EL. The value will be
> > the
> > same for every reloc, so this puts the boring code out of the way.
>
> Sure, but is IsMips64EL = Relocs[0].C.getFile()->getObj().isMips64EL() ==
> File.getObj().isMips64EL() always true?
>

If Mips64EL is true for one file, all files are Mips64EL, and vice versa.
We can make it a global configuration.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151016/694b0645/attachment.html>


More information about the llvm-commits mailing list