This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: Is the current gdb 5.1 broken for Linuxthreads?
- To: Eric Paire <paire at ri dot silicomp dot fr>
- Subject: Re: Is the current gdb 5.1 broken for Linuxthreads?
- From: Andrew Cagney <ac131313 at cygnus dot com>
- Date: Wed, 19 Sep 2001 16:38:51 -0400
- Cc: Mark Kettenis <kettenis at science dot uva dot nl>, "H . J . Lu" <hjl at lucon dot org>, GDB <gdb at sourceware dot cygnus dot com>
- References: <200109191438.f8JEcoR29295@mailhost.ri.silicomp.fr>
> I already started a thread to explain that that stopping all threads in
> a synchronous way was an illusion: Think of a 2-way processor on which
> 2 threads are running on each processor: If one thread stops, the time
> required by one processor to handle the trap, discover that others
> threads must be stopped, makwe the interprocessor request, ... allows
> the other thread to run thousands of instructions on the second
> processor before being stopped. The result is that you think all threads
> have stopped at the same time, while it's false, even if you have the best
> interface you can think of.
Just an aside, everyone will agree with your point that synchronized
thread stop model is an illusion. However, that doesn't make the
model/illusion wrong. Most other systems still make a synchronised halt
interface available since it is simple and fast - the complexity of
having to suspend all related threads being constrained to the kernel.
As a separate issue, it would be good if GDB was able to control threads
with a finer guranularity then all/none running.
enjoy,
Andrew