This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB 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: [rfc] Do not read from the executable if ptrace fails


Dan Jacobowitz wrote:
> On Mon, Jun 25, 2007 at 07:54:03PM -0400, Joel Brobecker wrote:
> > > Any comments, or shall I apply this?
> > > 
> > > -- 
> > > Daniel Jacobowitz
> > > CodeSourcery
> > > 
> > > 2007-06-24  Daniel Jacobowitz  <dan@codesourcery.com>
> > > 
> > > 	PR symtab/2161
> > > 	* target.c (memory_xfer_partial): Do not continue past targets with
> > > 	all memory.
> > 
> > FWIW, it looks pretty good to me, and I think it should be part of 6.7
> > too.
> 
> OK, I checked it in.

I only noticed now, but this breaks SPU overlay support.

Overlay support uses "LMA" addresses to refer to overlay sections
not currently loaded, and performs xfer_partial requests to read
from those (e.g. when invoking skip_prologue on a function not
currently present).

This works only if accesses to those LMA addresses go through to
the xfer_memory routine in exec.c, which implements the required
logic to retrieve those section contents from the executable file.

This used to work (probably accidentally?), but is broken by
this patch.  Any suggestions how to fix it?  Should the overlay
logic from xfer_memory be moved to memory_xfer_partial, maybe?

Bye,
Ulrich

-- 
  Dr. Ulrich Weigand
  GNU Toolchain for Linux on System z and Cell BE
  Ulrich.Weigand@de.ibm.com


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