Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 22 Mar 2008 06:26:46 -0700 (PDT)
From:      Barney Cordoba <barney_cordoba@yahoo.com>
To:        Poul-Henning Kamp <phk@phk.freebsd.dk>, Julian Elischer <julian@elischer.org>
Cc:        current@freebsd.org
Subject:   Re: kvm_read() vs ioctl performance 
Message-ID:  <416202.18656.qm@web63914.mail.re1.yahoo.com>
In-Reply-To: <9428.1206171107@critter.freebsd.dk>

next in thread | previous in thread | raw e-mail | index | archive | help

--- Poul-Henning Kamp <phk@phk.freebsd.dk> wrote:

> In message <47E46682.4020403@elischer.org>, Julian
> Elischer writes:
> 
> >>> tried a shared memory page?
> >> 
> >> No, but I built a test and kvm_read is 70 times
> >> faster, in
> >> case anyone is interested.
> 
> The shared memory approach is much better than that,
> you should
> go that way.
> 
> Look at the adlink driver for an example.

I can't easily follow this driver, given the superior
comments :) 

I don't see this in the handbook. Is there a document
which describes  both kernel and userland
implementation?

My concern is this: stats may be updated in iterations
of 100K+ times per second, while stats are only
gathered once every few seconds. Even a tiny addition
to the kernel cpu cycles can make it a "cut off your
head to stop a nosebleed" scenario. I don't want to
lose cpu cycles for the sake of saving a fraction of a
ms every few minutes.

Barney


      ____________________________________________________________________________________
Be a better friend, newshound, and 
know-it-all with Yahoo! Mobile.  Try it now.  http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?416202.18656.qm>