From: Christopher Faylor <cgf-use-the-mailinglist-please@sourceware.org>
To: gdb-patches@sourceware.org,
Oswald Buddenhagen <oswald.buddenhagen@trolltech.de>,
Eli Zaretskii <eliz@gnu.org>
Subject: Re: make attaching to stopped processes work under windows
Date: Tue, 03 Mar 2009 05:21:00 -0000 [thread overview]
Message-ID: <20090303052130.GA28801@ednor.casa.cgf.cx> (raw)
In-Reply-To: <ubpsjoc33.fsf@gnu.org>
On Mon, Mar 02, 2009 at 11:21:20PM +0200, Eli Zaretskii wrote:
>> Date: Mon, 2 Mar 2009 20:56:25 +0100
>> From: Oswald Buddenhagen <oswald.buddenhagen@trolltech.de>
>>
>> > As someone who have certainly read the patch, I can assure you that
>> > Chris's question didn't sound like it was answered in the comment.
>> >
>> well, then i would be thankful for questions that somehow indicate what
>> is missing from the comment or why it is entirely irrelevant.
>
>It is not irrelevant, but its wording is obscure and unclear, at least
>to me. The full comment reads:
>
> + /* Resume main thread if we are attaching to a suspended
> + process.
> + Note that we are not trying to handle multi-threaded
> + situations, as these are likely to be too complex anyway.
> + This is primarily meant to cover the case where someone
> + creates a process in suspended state and hands it over
> + to gdb (this is an abstraction - you cannot actually do
> + that due to Windows bugs. You need to start debugging the
> + process yourself, and once it has started up, you suspend
> + it and detach from it). */
>
>Perhaps I read this too naively, but note how you first seem to
>describe a use-case:
>
> This is primarily meant to cover the case where someone
> creates a process in suspended state and hands it over
> to gdb
>
>but then immediately say that it cannot be done:
>
> this is an abstraction - you cannot actually do
> that due to Windows bugs.
>
>After reading this, I already become confused.
>
> You need to start debugging the process yourself,
> and once it has started up, you suspend it and detach from it
>
>And now I'm _really_ confused: ``detach''? didn't you say ``attach''
>above? why detach from a process if you want to debug it?
>
>Of course, Chris knows much more than I do about debugging on Windows,
>so perhaps his difficulty with your concept was different and more
>deep. I will let him speak for himself.
Thanks, Eli. You're right. Part of my concern about the patch was that
I didn't understand the comment.
I thought I would get to that when I understood when and why someone
would start a process in a suspended state and then want to debug it.
In my definition of "use case", you don't just theorize that something
could be done, you explain that "Package X does this all of the time
because of Y and that makes it hard for me to debug things." You don't
just assert that you want to change the code because it is theoretically
possible.
Once the "use case" was explained, I thought I would try to remember why
I had rejected a concept like this in Cygwin many years ago and see if
this was related. I know that I had many problems when I arbitrarily
suspeded processes, especially on older versions of Windows.
cgf
next prev parent reply other threads:[~2009-03-03 5:21 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-27 15:04 Oswald Buddenhagen
2009-02-28 7:15 ` Christopher Faylor
2009-03-02 10:07 ` Oswald Buddenhagen
2009-03-02 17:23 ` Joel Brobecker
2009-03-02 18:28 ` Oswald Buddenhagen
2009-03-02 19:18 ` Eli Zaretskii
2009-03-02 19:55 ` Oswald Buddenhagen
2009-03-02 21:21 ` Eli Zaretskii
2009-03-03 5:21 ` Christopher Faylor [this message]
2009-03-03 12:05 ` Oswald Buddenhagen
2009-03-08 19:32 ` Christopher Faylor
2009-03-09 18:45 ` Joel Brobecker
2009-03-09 20:51 ` Oswald Buddenhagen
2009-03-10 8:52 ` Christopher Faylor
2009-03-10 13:37 ` Oswald Buddenhagen
2009-03-03 5:41 ` Christopher Faylor
2009-03-02 19:14 ` 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=20090303052130.GA28801@ednor.casa.cgf.cx \
--to=cgf-use-the-mailinglist-please@sourceware.org \
--cc=eliz@gnu.org \
--cc=gdb-patches@sourceware.org \
--cc=oswald.buddenhagen@trolltech.de \
/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