From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19817 invoked by alias); 8 Jan 2003 02:49:50 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 19807 invoked from network); 8 Jan 2003 02:49:49 -0000 Received: from unknown (HELO outbound0.sv.meer.net) (205.217.152.15) by 209.249.29.67 with SMTP; 8 Jan 2003 02:49:49 -0000 Received: from mail.meer.net (mail.meer.net [209.157.152.14]) by outbound0.sv.meer.net (8.12.6/8.12.6) with ESMTP id h082nbqC023182; Tue, 7 Jan 2003 18:49:37 -0800 (PST) (envelope-from dmose@mozilla.org) Received: from mozilla.org (dsl081-050-187.sfo1.dsl.speakeasy.net [64.81.50.187]) by mail.meer.net (8.12.1/8.12.1/meer) with ESMTP id h082nbJA005432; Tue, 7 Jan 2003 18:49:37 -0800 (PST) Message-ID: <3E1B91B7.4010309@mozilla.org> Date: Wed, 08 Jan 2003 02:49:00 -0000 From: Dan Mosedale User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3b) Gecko/20030102 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Daniel Jacobowitz CC: gdb-patches@sources.redhat.com Subject: Re: threads and target-function-calls References: <3E1B7829.6B6E8BAF@redhat.com> <20030108010842.GA30628@nevyn.them.org> In-Reply-To: <20030108010842.GA30628@nevyn.them.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2003-01/txt/msg00317.txt.bz2 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. > What happens if the target function wants to interact with another thread? e.g. wait on a mutex being held by another thread? Dan