On Tuesday 22 January 2002 20:33, Brooks Davis wrote: Hi.
> I'm trying to figure out how to get it from userland (in a shell script). > I've looked at the cpuid port which seems to do most of it, but it > doesn't display clock speed, only works on IA32 cpus, and won't be > accurate if we have mismatched CPUs.[0] Well, cpuid relies on the CPUID instruction to gather all that info from the processor. That's why it is x86 only. Unfortunately that opcode has no options to give info about cpu speed. You could roll your own code to do so, but I'm not sure you can messure cpu speed once multitasking/multiuser state is reached. > Linux displays this information in /proc/cpuinfo though there's no > consistancy between platforms (at least alpha and i386 seem to have > nothing in common.) Is there something similar I'm missing or is this a > missing feature? There are not sysctl variables that provide cpu speed afair, so that basicly means that you could: a) Fetch data from dmesg b) Require that linuxprocs is mounted (so you could cat /compat/linux/proc/cpuinfo) c) Roll your own code (don't know if possible at all) Cheers, -- Miguel Mendez - [EMAIL PROTECTED] EnergyHQ :: http://energyhq.homeip.net FreeBSD - The power to serve! To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-hackers" in the body of the message