This is the mail archive of the
binutils@sourceware.cygnus.com
mailing list for the binutils project.
Re: patch for m32r (relocations)
- To: Donald Lindsay <dlindsay at cygnus dot com>
- Subject: Re: patch for m32r (relocations)
- From: Jeffrey A Law <law at cygnus dot com>
- Date: Fri, 11 Feb 2000 11:28:12 -0700
- cc: Ian Lance Taylor <ian at zembu dot com>, binutils at sourceware dot cygnus dot com
- Reply-To: law at cygnus dot com
In message <Pine.LNX.4.10.10002111012330.24288-100000@hound.cygnus.com>you wr
ite:
> > The following fixes a problem with the m32r, whereby the reloc for a
> > struct member was marked as being relative to the struct, but had an
> > offset which was instead relative to the front of the dsect. This chan
> ge
> > causes the reloc to be restamped as dsect-relative (with the offset no
> t
> > being changed). Hence the reloc becomes correct.
> >
> > This isn't the right way to fix this sort of problem. For most ELF
> > targets, relocations against global symbols should not be adjusted.
> > If they were, it would be impossible to override those symbols in a
> > shared library.
>
> Yes, it's a hack. We have not yet found the place which caused this
> situation. (Reloc code tends to have downstream bugs.)
>
> However, this patch got us off the hook with a customer, so finding the
> real fix is no longer urgent, so I'm now supposed to be doing something
> else. You're welcome to my test case...
>
> Anyway, for the moment, it's a hack, but it's a useful hack.
But this is not a hack that we should install.
Just because it fixes the customer bug doesn't mean we should install the
fix into the source tree. You are not finished with the CR until you find
the correct fix.
jeff