Date: Sun, 12 Mar 2000 20:01:51 +0100 (CET) From: Andrzej Bialecki <abial@webgiro.com> To: freebsd-hackers@FreeBSD.ORG Subject: Re: Getting CPU usage in FreeBSD Message-ID: <Pine.BSF.4.20.0003121959200.24297-100000@mx.webgiro.com> In-Reply-To: <200003121654.RAA46802@dorifer.heim3.tu-clausthal.de>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 12 Mar 2000, Oliver Fromme wrote: > Kris Kennaway <kris@hub.freebsd.org> wrote in list.freebsd-hackers: > > On Sun, 12 Mar 2000, Oliver Fromme wrote: > > > Then look up the definition of kread() in the same file, and > > > how the contents of cur.cp_time are used in the cpustats() > > > function. Note that "cur" is a "struct statinfo", which is > > > defined in /usr/include/devstat.h. The CPU states are defined > > > in /usr/include/sys/dkstat.h. > > > > We probably should make this into a sysctl to divorce the binaries from > > having to read kvm. > > Sounds like a good idea. But then again, vmstat.c uses kvm > for about a dozen different things. Shouldn't they all be > made into sysctls then? Just wondering... Many of them can already be obtained via sysctl (e.g. vmtotal, proc list). This is rather historical dependency, or one related to very rare uses (like reading VM statistics from post mortem dump). Andrzej Bialecki // <abial@webgiro.com> WebGiro AB, Sweden (http://www.webgiro.com) // ------------------------------------------------------------------- // ------ FreeBSD: The Power to Serve. http://www.freebsd.org -------- // --- Small & Embedded FreeBSD: http://www.freebsd.org/~picobsd/ ---- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.20.0003121959200.24297-100000>