From owner-freebsd-arch@FreeBSD.ORG Wed Jun 18 06:36:07 2003 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3C8A037B401; Wed, 18 Jun 2003 06:36:07 -0700 (PDT) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5112D43F85; Wed, 18 Jun 2003 06:36:06 -0700 (PDT) (envelope-from phk@phk.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.9/8.12.9) with ESMTP id h5IDa4BE040090; Wed, 18 Jun 2003 15:36:04 +0200 (CEST) (envelope-from phk@phk.freebsd.dk) To: Robert Watson From: "Poul-Henning Kamp" In-Reply-To: Your message of "Wed, 18 Jun 2003 09:33:18 EDT." Date: Wed, 18 Jun 2003 15:36:04 +0200 Message-ID: <40089.1055943364@critter.freebsd.dk> cc: arch@freebsd.org Subject: Re: marking normal sleep identifiers as such. X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Jun 2003 13:36:07 -0000 In message , Robert Watson writes: >> Should we adopt that as our convention ? > >One >disadvantage of changing to a common name with no distinct string is that >it makes it quite a bit harder to track down the sleep call in the kernel; >you can no longer glimpse/grep on the state to find the stage in the >thread event loop you've reached, which would be one reason to prefer a >fooidle approach. I actually thought a bit more about that. I think all sleeping calls should allow a string to be specified, also when we sleep on semaphores for instance. And I think we should capture __FILE__ and __LINE__ as well, at least when DDB or DIAGNOSTIC is in play. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence.