From: Andrew Cagney <ac131313@redhat.com>
To: Joel Brobecker <brobecker@gnat.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: Re-initializing a list after the control returns to gdb...
Date: Wed, 19 Feb 2003 12:47:00 -0000 [thread overview]
Message-ID: <3E537DF0.50205@redhat.com> (raw)
In-Reply-To: <20030219020101.GI2105@gnat.com>
> Hello,
>
> I am trying to do a small cleanup in our ada-tasks module, and I was
> wondering if somebody could help me making sure I am using the right
> approach.
Joel,
A more higher level question. What exactly is the story behind
ada-task*. I glanced at the code and it looked very like a clone of the
existing thread code.
Andrew
> Basically: the ada_language provides a set of commands, namely "info
> tasks" and "task". Here is the syntax:
>
> - info tasks -> prints the list of tasks, equivalent of "info threads"
> - info tasks <task_id> -> the detailed information on a given task
> - task -> print the current task id, equivalent of "thread"
> - task <task_id> -> switch to the given task
>
> The small annoyance I am trying to fix is that all these commands use
> a list internally maintained in ada-tasks.c, which gets built only
> when the "info tasks" command is called. So far, we have documented that
> the above command may only be used after "info tasks" has been issued.
>
> What I am trying to do is to lift this limitation, by updating the
> list of tasks every time the user has resumed the execution of the
> inferior, just before the user gets back the prompt.
>
> I did it by inserting a call to ada_reset_tasks_list() inside
> normal_stop(), like so:
>
> *************** print_stop_reason (enum inferior_stop_re
> *** 3360,3365 ****
> --- 3362,3369 ----
> void
> normal_stop (void)
> {
> + ada_reset_tasks_list (NULL);
> +
> /* As with the notification of thread events, we want to delay
> notifying the user that we've switched thread context until
> the inferior actually stops.
>
> My testing shows that it seems to be working pretty well. But do you
> think that this is a good idea? And does this change have any chance of
> being accepted for inclusion (eventually, we are still ironing out some
> wrinkles here and there to make our changes more acceptable, but hope to
> be able to contribute our ada-language support changes soon)?
>
> -- Joel
next prev parent reply other threads:[~2003-02-19 12:47 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-02-19 2:01 Joel Brobecker
2003-02-19 12:47 ` Andrew Cagney [this message]
2003-02-19 16:05 ` Joel Brobecker
2003-02-19 16:49 ` Andrew Cagney
2003-02-19 17:46 ` Joel Brobecker
2003-02-19 17:01 ` Andrew Cagney
2003-02-19 17:50 ` Joel Brobecker
2003-02-19 18:05 ` Andrew Cagney
2003-02-19 19:24 ` Joel Brobecker
2003-02-19 20:30 ` Andrew Cagney
2003-02-25 1:37 ` Joel Brobecker
2003-02-26 15:57 ` Andrew Cagney
2003-02-27 7:13 ` Joel Brobecker
2003-02-27 18:44 ` Andrew Cagney
2003-02-28 7:42 ` Joel Brobecker
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=3E537DF0.50205@redhat.com \
--to=ac131313@redhat.com \
--cc=brobecker@gnat.com \
--cc=gdb-patches@sources.redhat.com \
/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