From: Philip Mucci <mucci@cs.utk.edu>
To: Linux MIPS <linux-mips@linux-mips.org>
Subject: /dev/cpuid or /proc/cpuinfo
Date: Mon, 30 Jan 2006 18:54:29 +0000 [thread overview]
Message-ID: <1138647269.4077.11.camel@localhost.localdomain> (raw)
In-Reply-To: <Pine.LNX.4.44.0601271349350.2185-100000@bharathi.midascomm.com>
Hello MIPSers,
In reference to the performance counting thread we had going earlier,
I've noticed a 'feature' I need out of MIPS/Linux that isn't currently
available. This has also recently come up on the oprofile list with one
of the oprofile/mips tools not being able to grab cpu Mhz
from /proc/cpuinfo because it's not there.
I have need to execute the mfc0 instruction on the config register and
grok the results to find out things like cache size etc. In addition, it
might be nice to also actually be able to find out the clock rate.
(Currently I grab BogoMIPS and punt.)
On the intel and PPC systems, I believe you can execute similar
instructions from user mode which makes things easy. However, of course
an MFC0 is a privileged instruction...meaning that if the value or
values aren't found in /proc/cpuinfo, I'm s.o.l.
What does the list think about this? Making a mips /dev/cpuid is a bit
gross but extending and grokking /proc/cpuinfo is perhaps grosser...and
many tools do just this (like PAPI and oprofile's opreport...)
Comments? I'm certainly willing to implement this, but I'd rather 'do it
right the first time' rather than get rotten vegetables thrown my way.
Phil
next prev parent reply other threads:[~2006-01-30 19:31 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-16 15:36 Timer Interrupt Bharathi Subramanian
2006-01-17 7:30 ` Bharathi Subramanian
2006-01-17 14:13 ` Bharathi Subramanian
2006-01-17 14:52 ` Kevin D. Kissell
2006-01-17 15:28 ` Bharathi Subramanian
2006-01-27 8:32 ` Bharathi Subramanian
2006-01-30 18:54 ` Philip Mucci [this message]
2006-02-01 11:30 ` /dev/cpuid or /proc/cpuinfo Ralf Baechle
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1138647269.4077.11.camel@localhost.localdomain \
--to=mucci@cs.utk.edu \
--cc=linux-mips@linux-mips.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox