From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.redhat.com (mail.redhat.com [199.183.24.239]) by listman.redhat.com (Postfix) with ESMTP id 8A8B02F61F for ; Thu, 25 Jan 2001 11:36:38 -0500 (EST) Received: (from mail@localhost) by mail.redhat.com (8.11.0/8.8.7) id f0PGaQ604853 for axp-list@listman.redhat.com; Thu, 25 Jan 2001 11:36:26 -0500 Received: from zmamail03.zma.compaq.com (zmamail03.zma.compaq.com [161.114.64.103]) by mail.redhat.com (8.11.0/8.8.7) with ESMTP id f0PGaQd04849 for ; Thu, 25 Jan 2001 11:36:26 -0500 Received: by zmamail03.zma.compaq.com (Postfix, from userid 12345) id 323C56CBA; Thu, 25 Jan 2001 11:36:29 -0500 (EST) Received: from ives.lkg.dec.com (ives.lkg.dec.com [16.24.240.4]) by zmamail03.zma.compaq.com (Postfix) with ESMTP id DCB616E00 for ; Thu, 25 Jan 2001 11:36:28 -0500 (EST) Received: by ives.lkg.dec.com (8.8.8/1.1.19.2/18May00-1129AM) id LAA28416; Thu, 25 Jan 2001 11:36:28 -0500 (EST) From: Bharadwaj Yadavalli Message-Id: <200101251636.LAA28416@ives.lkg.dec.com> Subject: Re: Finding processor frequency To: axp-list@redhat.com Date: Thu, 25 Jan 2001 11:36:28 -0500 (EST) In-Reply-To: <3A6F9551.45CB217F@appnet.com> from "Jeff Sturm" at Jan 24, 2001 09:54:09 PM X-Mailer: ELM [version 2.5 PL1] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Loop: axp-list@redhat.com Sender: axp-list-admin@redhat.com Errors-To: axp-list-admin@redhat.com X-BeenThere: axp-list@redhat.com X-Mailman-Version: 2.0beta4 Precedence: bulk Reply-To: axp-list@redhat.com List-Id: Linux and Red Hat on Alpha processors Ross A Knepper wrote: > personally, i think that exporting a hwrpb_struct to userland is both ugly > and unnecessary. the rpb is intended to be hidden to upper levels and > certainly to userland. I fully agree with you. > whereas finding the MHz of the cpu is conceptually > the same from the user's point of view on any architecture, > parsing a hwrpb_struct is clearly alpha-specific. AFAIK, this is the only place that the processor frequency is recorded in the kernel. Not knowing how else to get the value (other than parsing /proc/cpuinfo and hence relying on the string "cycle frequency [Hz]" not changing in the sprintf() in get_cpuinfo()), I enquired. As you say, since processor frequency is an architecture independent characteristic, may be it should be part of information returned in struct sysinfo structure by or sysconf(). getsysinfo() on Tru64 lets you pick that information with GSI_CPU_INFO operation. Jeff Sturm suggested: > The lmbench suite Thanks. I'll check it out. Bharadwaj (resigned to parsing /proc/cpuinfo :-((