A target has-a 1:N threads?
Andrew Cagney
ac131313@redhat.com
Thu Oct 9 16:10:00 GMT 2003
>> Hello,
>>
>> At present GDB maintains a thread-db that contains all the "threads" known to GDB. The list is cross-target. That is, it can include both LWPs from the lower "process layer" and "threads" from the higher "thread layer".
>>
>> I think the currently implicit target <-> thread relationship should be made more explicit:
>>
>> - thread_info should point back at it's target
>> - a target should let you iterate over its "threads"
>>
>> This, I belive, will help clean-up the current tid:pid dance. A thread would always know its target and hence thread operations would always be applied at the correct level.
>
> Make that 0:N threads. I forgot the targets that don't have threads.
It's really, really not my day.
The "0" is for the case where nothing has executed. For instance, a not
yet running executable (Kevin's e-mail under another related
thread^D^D^D^Dtopic raised it). Once the executable has executed,
there's at least one "thread".
Andrew
More information about the Gdb
mailing list