From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:40314) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWcnG-0007rN-5k for qemu-devel@nongnu.org; Tue, 14 Jun 2011 19:13:11 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QWcnE-00044p-VN for qemu-devel@nongnu.org; Tue, 14 Jun 2011 19:13:10 -0400 Received: from mail-gx0-f173.google.com ([209.85.161.173]:41250) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWcnE-00044k-Sm for qemu-devel@nongnu.org; Tue, 14 Jun 2011 19:13:08 -0400 Received: by gxk26 with SMTP id 26so4869357gxk.4 for ; Tue, 14 Jun 2011 16:13:07 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <4DF7E18F.6050708@cray.com> References: <4DF7E18F.6050708@cray.com> From: Mulyadi Santosa Date: Wed, 15 Jun 2011 06:12:26 +0700 Message-ID: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] High speed polling List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Clay Andreasen Cc: qemu-devel@nongnu.org Hi Clay..... On Wed, Jun 15, 2011 at 05:32, Clay Andreasen wrote: > I have a network device simulation that I am connecting to multiple > instances of Qemu (nodes) via a shared memory queue. =A0It works pretty w= ell > as > long as all of the nodes are initiating communication but when one node i= s > passive, it must poll to get packets. =A0So far the fastest I have been a= ble > to > get it to poll is about every 2M emulated clocks. that means, once every ... 1 mili second? (I doubt it, but theoritically possible) > This is with CONFIG_HIGH_RES_TIMERS and CONFIG_NO_HZ on the host. > I also set MIN_TIMER_REARM_NS in qemu-timer.c to 100000. > Is there some way to increase the polling rate by about an order of > magnitude? with the way current kernel did fair scheduling, your problem is timing handling latency actually i.e timer is fast, but the handler needs some time to catch up. what I can suggest is experimenting with rt- kernel and put yourself into such high priority process with realtime scheduling, keep reducing MIN_TIMER_REARM_NS.. --=20 regards, Mulyadi Santosa Freelance Linux trainer and consultant blog: the-hydra.blogspot.com training: mulyaditraining.blogspot.com