From owner-freebsd-hackers@FreeBSD.ORG Mon Aug 30 09:09:37 2010 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 40FDC10656A5; Mon, 30 Aug 2010 09:09:37 +0000 (UTC) (envelope-from gljennjohn@googlemail.com) Received: from mail-bw0-f54.google.com (mail-bw0-f54.google.com [209.85.214.54]) by mx1.freebsd.org (Postfix) with ESMTP id 323888FC12; Mon, 30 Aug 2010 09:09:36 +0000 (UTC) Received: by bwz20 with SMTP id 20so4182011bwz.13 for ; Mon, 30 Aug 2010 02:09:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:date:from:to:cc:subject :message-id:in-reply-to:references:reply-to:x-mailer:mime-version :content-type:content-transfer-encoding; bh=P1cR1NoL6yhtI+A+tYH+HFnxtINVAqOqo1OdvjYTzl8=; b=oGizXyCs8UQk+BSmKQF0zlCu+2Hg3S/jx+BHYwQcp/Ncg8PVMo8nltcUYG/SNZkfD8 JiJq89h1NHCUCGDg1x3R+YFQn9GPmX19UWu9eAWLQ6ryvw6qQTUUZ2v5dkPL09mXmBhk 7UJPjkxTBFwcbBqCuNRj7pl16Ra+/nqyHujBY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=date:from:to:cc:subject:message-id:in-reply-to:references:reply-to :x-mailer:mime-version:content-type:content-transfer-encoding; b=fipuzUIsUs/K7mxdD6O+39QIR+tPiPwz3qb58ormisGTadQhkZMMUraie7Z7BymDTy h7QXsItocveO56LtLO3MD0Mj1U8G28CuneNfjBz9cbDqI60Dsqquc8QjdpFiwFKarff3 VoKPZT0qoOu96aowcQxtymkheaXn5C5BpVyvs= Received: by 10.204.39.203 with SMTP id h11mr3022078bke.8.1283159375085; Mon, 30 Aug 2010 02:09:35 -0700 (PDT) Received: from ernst.jennejohn.org (p578E3A7B.dip.t-dialin.net [87.142.58.123]) by mx.google.com with ESMTPS id g12sm5031326bkb.2.2010.08.30.02.09.33 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 30 Aug 2010 02:09:34 -0700 (PDT) Date: Mon, 30 Aug 2010 11:09:32 +0200 From: Gary Jennejohn To: Alexander Motin Message-ID: <20100830110932.23425932@ernst.jennejohn.org> In-Reply-To: <4C7A5C28.1090904@FreeBSD.org> References: <4C7A5C28.1090904@FreeBSD.org> X-Mailer: Claws Mail 3.7.6 (GTK+ 2.18.7; amd64-portbld-freebsd9.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org, FreeBSD-Current Subject: Re: One-shot-oriented event timers management X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: gljennjohn@googlemail.com List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Aug 2010 09:09:37 -0000 On Sun, 29 Aug 2010 16:10:00 +0300 Alexander Motin wrote: > I have actively tested this code for a few days on my amd64 Core2Duo > laptop and i386 Core-i5 desktop system. With C2/C3 states enabled > systems experience only about 100-150 interrupts per second, having HZ > set to 1000. These events mostly caused by several event-greedy > processes in our tree. I have traced and hacked several most aggressive > ones in this patch: http://people.freebsd.org/~mav/tm6292_idle.patch . > It allowed me to reduce down to as low as 50 interrupts per system, > including IPIs! Here is the output of `systat -vm 1` from my test > system: http://people.freebsd.org/~mav/systat_w_oneshot.txt . Obviously > that with additional tuning the results can be improved even more. > Hmm. I applied your patches and am now running the new kernel. But I only installed the new kernel and didn't do make buildworld installworld. Mu systat -vm 1 doesn't look anything like yours. I'm seeing about 2300 interrupts per second and most of those are coming from the hpet timers: 1122 hpet0:t0 1124 hpet0:t1 So, what else did you do to reduce interrupts so much? Ah, I think I see it now. My desktop has only C1 enabled. Is that it? Unfortunately, it appears that only C1 is supported :( -- Gary Jennejohn