[comp.sys.ibm.pc] Identifying CPU type and MHZ

mshiels@tmsoft.uucp (Michael A. Shiels) (08/12/89)

If I have time I can post many different ways to identify CPUS
including the 486.  What I would like in return is a way
to calculate the MHZ of the CPU?

  

nelson@sun.soe.clarkson.edu (Russ Nelson) (08/12/89)

In article <1989Aug12.005931.4807@tmsoft.uucp> mshiels@tmsoft.uucp (Michael A. Shiels) writes:

   If I have time I can post many different ways to identify CPUS
   including the 486.  What I would like in return is a way
   to calculate the MHZ of the CPU?

Not as easy as you would think.  If all you want to do is calculate the Mhz,
i.e. clock speed, then just do a few multiples right in a row, and time them.
Then run this program on a few machines of known Mhz, and solve the equation
for the Mhz of the machine, given the time.

BUT

You also have to account for the memory access speed.  The number of wait
states you will get depends upon the architecture.  I believe that 8088s
access system memory in zero wait states.  286s access system memory in zero
or one wait states.  386s can vary wildly, depending on whether or not you
have a memory cache installed.

You have to time the execution of a memory-intensive operation such as a
rep cmpsb with a large count.  This will tell you the number of wait states,
after you have taken the speed of the machine into account.
--
--russ (nelson@clutx [.bitnet | .clarkson.edu])|(70441.205@compuserve.com)|
       (Russ.Nelson@f360.n260.z1.fidonet.org)|(BH01@GEnie.com :-)