Re: [patch] "single step" atomic instruction sequences as a whole.

Daniel Jacobowitz
2007-04-12T15:33:05Z

On Thu, Apr 12, 2007 at 04:58:21PM +0200, Ulrich Weigand wrote:
> While we're on this topic, I'm wondering whether we could do some
> further simplification on the single-step code. In particular,
> now every single-step implementation makes use of the
> insert_single_step_breakpoint helper to insert breakpoints,
> and the !insert_breakpoint_p side of every single-step implementation
> consist of a sole call to the remove_single_step_breakpoints helper.
>
> It might be a good idea to actually enforce that behaviour. In fact,
> we could just *remove* the insert_breakpoint_p flag of the gdbarch
> callback, call that callback solely in insert the breakpoints (which
> *must* use the insert_single_step_breakpoint helper), and just call
> remove_single_step_breakpoints directly from common code instead of
> the gdbarch callback to remove the breakpoints.
>
> That would allow future changes to the details of single-step
> breakpoint implementation in common code without having to go
> through all implementations every time ...
>
> What do you think?

"Yes please". That's one of the reasons I wanted to get the common
helper in place.

--
Daniel Jacobowitz
CodeSourcery