From owner-cvs-src@FreeBSD.ORG Fri Oct 21 19:53:29 2005 Return-Path: X-Original-To: cvs-src@FreeBSD.org Delivered-To: cvs-src@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 368B116A41F; Fri, 21 Oct 2005 19:53:29 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from phk.freebsd.dk (phk.freebsd.dk [130.225.244.222]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9321243D45; Fri, 21 Oct 2005 19:53:28 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from critter.freebsd.dk (unknown [192.168.48.2]) by phk.freebsd.dk (Postfix) with ESMTP id 30B7CBC50; Fri, 21 Oct 2005 19:53:24 +0000 (UTC) To: Marcel Moolenaar From: "Poul-Henning Kamp" In-Reply-To: Your message of "Fri, 21 Oct 2005 12:38:59 PDT." <01DFB595-5279-4D3A-BEDA-5F0285E9519B@xcllnt.net> Date: Fri, 21 Oct 2005 21:53:24 +0200 Message-ID: <31753.1129924404@critter.freebsd.dk> Sender: phk@critter.freebsd.dk Cc: src-committers@FreeBSD.org, Andre Oppermann , Bruce Evans , cvs-src@FreeBSD.org, cvs-all@FreeBSD.org, Andre Oppermann Subject: Re: Timekeeping [Was: Re: cvs commit: src/usr.bin/vmstat vmstat.c src/usr.bin/w w.c] X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Oct 2005 19:53:29 -0000 In message <01DFB595-5279-4D3A-BEDA-5F0285E9519B@xcllnt.net>, Marcel Moolenaar writes: >> I think we need the definition to consider if (process- ?)state is >> retained while the system is unconcious or not. > >I'm not sure. I think that might be what makes the definition >complex. Actually I don't think it does, it simplifies it. If a process survives across the "unconcious" period, then it follows that CLOCK_MONOTONIC cannot be reset to zero in relation to the unconcious period. But we are only just scratching the surface here, there are tons of ambiguities we need to resolve, for instance: select(...., {3m0s}) suspend [ 2 minutes pass ] resume When does select time out ? One minute after the resume ? Three minutes after the resume ? Right after the resume with a special errno ? Some code should obviously know about the suspend/resume event, dhclient, wep, wpa, bgpd, sshd, just to mention a few But the majority of processes couldn't care less. I wish POSIX gang had taken a look at the HP Integral (I think it came out in 1985 ?) and thought "Gee, we better think about how portable unix should work in the future..." -- 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.