From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1975 invoked by alias); 29 Nov 2006 13:36:48 -0000 Received: (qmail 1963 invoked by uid 22791); 29 Nov 2006 13:36:46 -0000 X-Spam-Check-By: sourceware.org Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Wed, 29 Nov 2006 13:36:39 +0000 Received: from drow by nevyn.them.org with local (Exim 4.63) (envelope-from ) id 1GpPc5-0007bc-Bi for gdb@sourceware.org; Wed, 29 Nov 2006 08:36:37 -0500 Date: Wed, 29 Nov 2006 13:36:00 -0000 From: Daniel Jacobowitz To: gdb@sourceware.org Subject: Re: Single stepping and threads Message-ID: <20061129133637.GB28834@nevyn.them.org> Mail-Followup-To: gdb@sourceware.org References: <20061129052942.GA16029@nevyn.them.org> <6734.193.137.208.250.1164804049.squirrel@webmail.xs4all.nl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <6734.193.137.208.250.1164804049.squirrel@webmail.xs4all.nl> User-Agent: Mutt/1.5.13 (2006-08-11) X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2006-11/txt/msg00220.txt.bz2 On Wed, Nov 29, 2006 at 01:40:49PM +0100, Mark Kettenis wrote: > Are you talking about stepi or step? > For step we should be very careful, since on some platforms the dynamic > linker may play games with locks and we risk a deadlock if we don't let > the other threads run. That's the second part of the question :-) The current setting of "set scheduler-locking" applies to whenever proceed() is told to step, rather than when the user says "step". So it affects stepi always and step within a source line, but not step over a function. I talked about "stepping" over prologues and over functions without debug info; I hadn't thought about skipping shared library trampolines, but I can definitely see how that would be a problem. I don't like the user interface here; we say "step" and it will sometimes run one thread and sometimes run all threads and it's hard to explain which. But we may not be able to do better without adding unacceptable risk of deadlocks :-( -- Daniel Jacobowitz CodeSourcery