This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH: Decompress section before applying simple relocations


On Wed, Dec 15, 2010 at 09:27:55AM -0800, H.J. Lu wrote:
> On Wed, Dec 15, 2010 at 6:28 AM, H.J. Lu <hjl.tools@gmail.com> wrote:
> > On Wed, Dec 15, 2010 at 2:54 AM, Alan Modra <amodra@gmail.com> wrote:
> >> On Tue, Dec 14, 2010 at 01:56:54PM -0800, H.J. Lu wrote:
> >>> Hi,
> >>>
> >>> Since bfd_get_full_section_contents caches the decompressed section
> >>> content, we have to decompress compressed section before applying
> >>> simple relocations if it doesn't use RELA relocations. ?OK to install?
> >>
> >> Not OK. ?This fix doesn't belong in simple.c.
> >>
> >
> > Any suggestions? We don't want to apply simple relocations
> > if real relocations will be applied later.
> >
> 
> I still think bfd_simple_get_relocated_section_contents should
> avoid touching uncompressed section content.  Here is the
> updated patch.

I continue to think this is wrong.  Please go back and rethink
bfd_get_full_section_contents.  Why do you need to cache anything in
that function?

-- 
Alan Modra
Australia Development Lab, IBM


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]