This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Add "thread-group id" and "id in thread-group" info to -thread-info output


On 2017-02-23 14:49, Pedro Alves wrote:
Hi Simon,

On 02/20/2017 04:17 PM, Simon Marchi wrote:


Ping.


The code itself looks fine to me.

However, this needs manual and NEWS changes.

Of course, forgot about that.

And, I think you should also test what is printed before you
add the second inferior.  This is because while the CLI
only prints qualified IDs after adding the second inferior,
MI is always printing them.  We should add a test to make sure
that continues to be the case even if someone changes/refactors
the code.

Ok.

While writing the documentation parts, these question popped to mind:

- The type of the id-in-tg field (a string) assumes that a thread belongs to a single group. Currently, the only kind of "thread-group" we have is inferiors. The thread-group terminology suggests that in the future we might have other kinds of thread groups, like user-defined arbitrary groups. Otherwise, why would MI use "thread group" instead of "inferior"? Because of this, do you think that the type of the field will be limiting? For example, should we document right that this field can be a list, when a thread is part of multiple groups, for example?

- The format of the id-in-tg field is "1" for inferior/thread-group 1. In -list-thread-groups, the id is shown as "i1". Again, if there are other kinds of groups later, we can assume that we'll need to differentiate the type, so just "1" won't work. For this reason and for consistency with the result of -list-thread-groups, should we show "i1" here as well?

Thanks,

Simon


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]