This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 3/3] fix skipping permanent breakpoints
- From: Yao Qi <yao at codesourcery dot com>
- To: Pedro Alves <palves at redhat dot com>
- Cc: <gdb-patches at sourceware dot org>
- Date: Wed, 12 Nov 2014 08:54:29 +0800
- Subject: Re: [PATCH 3/3] fix skipping permanent breakpoints
- Authentication-results: sourceware.org; auth=none
- References: <1415127790-15091-1-git-send-email-palves at redhat dot com> <1415127790-15091-4-git-send-email-palves at redhat dot com> <87y4rp7s02 dot fsf at codesourcery dot com> <545D2330 dot 4090006 at redhat dot com>
Pedro Alves <palves@redhat.com> writes:
> If there was already an outermost step-resume breakpoint set (we're
> already skipping a function for "next", and tripped on a permanent
> breakpoint), we shouldn't clear step, as that'll make us miss
> software watchpoints.
>
> We'd avoid this issue if we could have more than one step-resume
> breakpoint installed for the same thread, that isn't allowed for
> good reason. Thinking again, we have a better breakpoint type
> for this -- a software single-step breakpoint. We're implementing
> single-step ourselves, so sounds like a perfect fit. The only
> issue is that a couple paths in infrun.c we need are guarded by
> gdbarch_software_single_step_p. Those are optimization guards.
> Given we need that code on hardware step targets too, we just
> remove them... (I'll reindent in the final version.)
Yeah, it is clever to use single-step breakpoint here. This version
looks good enough to me, although I've seen some fails on arm. I don't
triage them at this moment, and we can revisit them later.
--
Yao (éå)