This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: Insufficient documentation of struct thread_info
- From: Eli Zaretskii <eliz at gnu dot org>
- To: Pedro Alves <palves at redhat dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Mon, 15 Jun 2015 20:03:51 +0300
- Subject: Re: Insufficient documentation of struct thread_info
- Authentication-results: sourceware.org; auth=none
- References: <83zj47si2y dot fsf at gnu dot org> <557EE1C1 dot 7090203 at redhat dot com>
- Reply-to: Eli Zaretskii <eliz at gnu dot org>
> Date: Mon, 15 Jun 2015 15:31:29 +0100
> From: Pedro Alves <palves@redhat.com>
>
> Let's try with an example, based on "(gdb) step".
> [...]
> Hope that helps.
It does, thanks. But you just gave an example, and the question is
now how to generalize it in order to have a better documentation that
doesn't stop at an example.
First, AFAIU, if the state is THREAD_STOPPED, then EXECUTING is
definitely zero, is that right? (The converse is false.)
Next, what other situations, in addition to single-stepping, are
"internal details" that flip the EXECUTING flag, but leave the state
at THREAD_RUNNING?
And finally, why do we need to pretend on the user level that the
thread is running, when it really is stopped? Is it just because we
don't want to allow application of commands to that thread, or are
there other reasons?
TIA