This is the mail archive of the
mailing list for the GDB project.
Re: threads and target-function-calls
- From: Michael Snyder <msnyder at redhat dot com>
- To: Daniel Jacobowitz <drow at mvista dot com>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Wed, 08 Jan 2003 16:48:35 -0800
- Subject: Re: threads and target-function-calls
- Organization: Red Hat, Inc.
- References: <3E1B7829.6B6E8BAF@redhat.com> <20030108010842.GA30628@nevyn.them.org>
Daniel Jacobowitz wrote:
> On Tue, Jan 07, 2003 at 05:00:25PM -0800, Michael Snyder wrote:
> > Hey folks,
> > Did you know that (at least on x86 linux), if you have a multi-thread
> > program and you execute a target function call, all the threads get to
> > run? Doesn't that seem like a bad thing? Wouldn't we really rather
> > only run the thread that is executing the target function call?
> Eeeeek! I think I agree with you here; that's the logical behavior.
> It never occured to me to try.
I just happened to have "debug lin-lwp" turned on.
Perhaps we need to think about what "target function call"
actually means in the presence of threads that can interact
with each other.