From owner-freebsd-current@FreeBSD.ORG Mon Apr 30 20:42:22 2007 Return-Path: X-Original-To: current@freebsd.org Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 950CE16A403; Mon, 30 Apr 2007 20:42:22 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (tim.des.no [194.63.250.121]) by mx1.freebsd.org (Postfix) with ESMTP id 4B2E113C48C; Mon, 30 Apr 2007 20:42:22 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (localhost [127.0.0.1]) by spam.des.no (Postfix) with ESMTP id 95B4F2083; Mon, 30 Apr 2007 22:42:18 +0200 (CEST) X-Spam-Tests: AWL X-Spam-Learn: disabled X-Spam-Score: 0.0/3.0 X-Spam-Checker-Version: SpamAssassin 3.1.7 (2006-10-05) on tim.des.no Received: from dwp.des.no (des.no [80.203.243.180]) by smtp.des.no (Postfix) with ESMTP id 7ED96207E; Mon, 30 Apr 2007 22:42:18 +0200 (CEST) Received: by dwp.des.no (Postfix, from userid 1001) id E41E2560B; Mon, 30 Apr 2007 22:42:17 +0200 (CEST) From: des@des.no (Dag-Erling =?iso-8859-1?Q?Sm=F8rgrav?=) To: Robert Watson References: <20070423113400.GC28587@gw.humppa.dk> <462CD251.9060105@freebsd.org> <20070423161711.GV39474@elvis.mu.org> <462D821F.6030707@freebsd.org> <20070424042102.GI38475@tnn.dglawrence.com> <86veflholn.fsf@dwp.des.no> <20070428113752.A28395@fledge.watson.org> <4633299B.2020206@dlr.de> <20070428121554.T28395@fledge.watson.org> Date: Mon, 30 Apr 2007 22:42:17 +0200 In-Reply-To: <20070428121554.T28395@fledge.watson.org> (Robert Watson's message of "Sat, 28 Apr 2007 12:23:12 +0100 (BST)") Message-ID: <86bqh5ppau.fsf@dwp.des.no> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/21.3 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Cc: current@freebsd.org, Hartmut Brandt , Tim Kientzle , David G Lawrence , "Jesper B. Rosenkilde" Subject: Re: Suggestions on Avoiding syscall Overhead X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Apr 2007 20:42:22 -0000 Robert Watson writes: > Unfortunately, this sort of thing can't be expressed using the > standard APIs. This leaves us two choices: allow the behavior of > standard APIs to be configured at some granularity, or introduce new > APIs. My feeling is we should prefer new APIs, and suggest that > programmers use those. Take a look at sys/sys/time.h:1.71 for an > example of what might make sense. I'm not sure this is a good example. There is already a suitable extensible API: clock_gettime(), which is part of SUSv3. Define new CLOCK_* constants for requesting a faster, less precise timecounter, and if you feel like it, submit it to X/Open for inclusion in the next version of the SUS. DES --=20 Dag-Erling Sm=F8rgrav - des@des.no