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: add file I/O support when debugging an embedded target via jtag


On Wed, Oct 01, 2008 at 07:38:22PM +0100, Bart Veer wrote:
> Adding a new stratum certainly appears to be controversial, although I
> am not certain why.

Because this is not about what in the current sources will break.
It's about the purpose of the target stack, which does not include
synthesizing operations like this.

>     Daniel> I don't see why it has to be in the target vector at all.
> 
> The h/w debug file I/O code needs to take some action for every load,
> resume and wait operation. For the wait, deprecated_target_wait_hook
> provides an alternative but I assume that hook is going to disappear
> at some point. There are no equivalent hooks for load and resume.

Those operations are where your patch acts, but I don't think they're
what you actually want.  What you do after load doesn't have anything
to do with "load"; I assume that at load time you're setting the
breakpoint, but GDB already has several hooks to set internal
breakpoints.  And it already has support for hitting an internal
breakpoint, hiding it from the user, and taking some action - this is
how SVR4 shared library support works.

-- 
Daniel Jacobowitz
CodeSourcery


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