[PATCH] PPC64 enable hp-timing 4th try

Steven Munroe munroesj@us.ibm.com
Mon Oct 31 23:23:00 GMT 2005


This version uses a small 1024 byte buffer on the stack. 1K is the sweet
spot and will handle up to 8 processors in the 1st read. For larger
systems (/proc/cpuinfo larger than 1023 bytes) we will read 512 bytes at
a time until we find EOF, keeping the last two 512 buffers. The last
512-1023 bytes of the file will contain the timebase value.

This will handle any number of CPUs in /proc/cpuinfo as long as timebase
value follows the CPUs.



-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: ppc64-hp-timing-20051031.txt
URL: <http://sourceware.org/pipermail/libc-alpha/attachments/20051031/caa8a6f2/attachment.txt>


More information about the Libc-alpha mailing list