Web lists-archives.com

Re: which program can test cpu speed




On Fri 26 Oct 2018 at 11:04:48 (-0400), Michael Stone wrote:
> On Fri, Oct 26, 2018 at 05:34:26PM +0300, Reco wrote:
> > On Fri, Oct 26, 2018 at 09:59:16AM -0400, Michael Stone wrote:
> > > On Fri, Oct 26, 2018 at 08:57:29AM +0300, Reco wrote:
> > > > Why would you need a *program* to do that then you have Linux kernel
> > > > already?
> > > >
> > > > grep bogomips /proc/cpuinfo
> > > 
> > > Anyone reading that advice: ignore it. You cannot use bogomips to meaningfully compare processors.
> > 
> > The reason being?
> 
> As it says in the link you posted, "It is not usable for performance
> comparisons among different CPUs".
> 
> > The kernel uses it just fine for the clock calibration.
> 
> I suppose if you want to use the system exclusively for busy loops,
> you can use the bogomips number to see which cpu will wait the fastest
> and choose based on that.
> 
> FWIW, even the kernel doesn't use naive busy loops anymore on newer
> hardware. (TSC or MWAIT is used, depending on what the processor
> supports.)

I've programmed a "busy loop" in the past and found that linux
bogomips tracked the loop speed quite closely on a variety of machines
from 486DX to 650MHz Pentium III (Coppermine). Nothing multiprocessor.

When I say busy loop, I mean a loop like
   FOR J=1 TO T
     X=X+1
   NEXT J
where X is floating point and the language is an HP Basic clone on MSDOS.

Cheers,
David.