From: muller@cerbere.u-strasbg.fr
To: Mark Kettenis <kettenis@science.uva.nl>
Cc: Eli Zaretskii <eliz@is.elta.co.il>, gdb-patches@sources.redhat.com
Subject: Re: [RFA/RFC 3] Remove hardware break and watchpoints at program exit.
Date: Sat, 12 Jan 2002 13:16:00 -0000 [thread overview]
Message-ID: <3.0.6.32.20020112222820.00ff9750@ics.u-strasbg.fr> (raw)
In-Reply-To: <s3iy9j31zcm.fsf@soliton.wins.uva.nl>
At 14:19 12/01/02 +0100, Mark Kettenis wrote:
>Pierre Muller <muller@cerbere.u-strasbg.fr> writes:
>
>> After the previous discussion about the
>> hardware watch and breakpoint removal
>> about the debuggee exited. I slightly modifed my patch
>> by adding a test to avoid calling ptrace
>> in i386-linux-nat.c, i386bsd-nat.c and x86-64-linux-nat.c
>> i386_linux_dr_set, i386bsd_dr_set and x86_64_linux_dr_set functions
>> if taget_has_execution is 0.
>
>That should not be necessary. Those functions shouldn't be called
>when there is no debuggee. I suspect that there is something wrong
>with the hardware breakpoint/watchpoint implementation at a much
>higher level.
There was no call tp ptrace before my patch,
but as Eli thought that the right solution would be to remove the
hardware break and watchpoints at exit, I tried to implement this.
But that implementation then ran into that
problem that the code in i386-linux-nat.c,
i386bsd-nat.c and x86-64-linux-nat.c
implicitly supposed that the debuggee was still running...
So here there is a conflict between
i386-nat code that would work cleaner if
we remove the hardware break and watchpoint at exit
(and which works correctly for go32v2
and my still uncommitted patch for win32-nat)
and the code that use ptrace.
I did quite agree with Eli that its cleaner
to remove those breakpoints, but if you prefer, I could
resubmit a patch where the macros that
trigger the removal are only set for go32v2 and
win32 targets. As long as we also call i386_cleanup_dregs
function, it should solve the bug present in 5.1
version, by which a watchpoint does not work anymore after
a rerun of the debuggee.
next prev parent reply other threads:[~2002-01-12 21:16 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-01-11 4:01 [RFA/RFC 2] " Pierre Muller
2002-01-11 4:38 ` Eli Zaretskii
2002-01-11 4:57 ` Pierre Muller
2002-01-11 5:58 ` Eli Zaretskii
2002-01-11 5:39 ` Pierre Muller
2002-01-11 6:06 ` Eli Zaretskii
2002-01-11 8:15 ` Pierre Muller
2002-01-11 9:20 ` [RFA/RFC 3] " Pierre Muller
2002-01-12 5:20 ` Mark Kettenis
2002-01-12 13:16 ` muller [this message]
2002-01-13 0:31 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3.0.6.32.20020112222820.00ff9750@ics.u-strasbg.fr \
--to=muller@cerbere.u-strasbg.fr \
--cc=eliz@is.elta.co.il \
--cc=gdb-patches@sources.redhat.com \
--cc=kettenis@science.uva.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox