From owner-freebsd-current@FreeBSD.ORG Sun Feb 12 19:27:45 2006 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C113B16A420 for ; Sun, 12 Feb 2006 19:27:45 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from pasmtp.tele.dk (pasmtp.tele.dk [193.162.159.95]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6855843D45 for ; Sun, 12 Feb 2006 19:27:45 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from critter.freebsd.dk (0x535c0e2a.sgnxx1.adsl-dhcp.tele.dk [83.92.14.42]) by pasmtp.tele.dk (Postfix) with ESMTP id 76D1A1EC329; Sun, 12 Feb 2006 20:27:41 +0100 (CET) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.13.4/8.13.4) with ESMTP id k1CJRbVw029219; Sun, 12 Feb 2006 19:27:37 GMT (envelope-from phk@critter.freebsd.dk) To: Yuriy Tsibizov From: "Poul-Henning Kamp" In-Reply-To: Your message of "Sun, 12 Feb 2006 22:14:46 +0300." <20060212220216.F1605@free.home.local> Date: Sun, 12 Feb 2006 19:27:37 +0000 Message-ID: <29218.1139772457@critter.freebsd.dk> Sender: phk@critter.freebsd.dk Cc: freebsd-current@freebsd.org Subject: Re: calcru: runtime went backwards 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: Sun, 12 Feb 2006 19:27:45 -0000 In message <20060212220216.F1605@free.home.local>, Yuriy Tsibizov writes: >On Sun, 12 Feb 2006, Poul-Henning Kamp wrote: >> In message <20060212114050.I1160@free.home.local>, Yuriy Tsibizov writes: >>> while playing 8 PCM streams in parallel (it uses almost all CPU power I >>> have). >>> >>> -CURRENT with last changes to src/sys from imp at 2006-02-11 03:58:07 UTC >> >> Can you try to update to a more recent current ? I think you have >> not gotten my latest commit to the cpu time accounting at that >> point... >With -CURRENT up to 2006-02-12 06:57:41 UTC (last commit by scottl) >I still can see some calcru messages: Right, but these have much smaller deltas than the other ones you saw. >calcru: runtime went backwards from 3508844 usec to 3508842 usec for pid 28 (pagezero) My theory currently is that these are side effects of the cputick calibration code: If the cputick rate gets measured to be a bit higher, the next calculation will result in slightly lower numbers for the cpu utilization in microseconds and the warning will fire. This will be particularly easy to trigger on machines with power management on (laptops mostly). My current inclination is to simply not issue this warning if the cpu_tick is marked as "variable". The other side of this is that I've been looking at having the ACPI power management code announce the maximum speed of the TSC to the cputick code, that would make such machines "fixed frequency" cpu_tick machines from the start and even if enabled, this warning should not issue in that case. -- 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.