[comp.unix.ultrix] Clock granularity on MIPS workstations

vancleef@iastate.edu (Van Cleef Henry H) (06/08/91)

I am doing some profile-type testing in which I use the gettimeofday(2)
function, which returns a struct timeval with seconds and microseconds.

What is the granularity of the clock in updating the microsecond field.
That is, how many microseconds are added?  

Hardware involved is DECstation 2100, 3100, and 5000, running Ultrix 
4.1 (soon to update to 4.2).  If the values are different on different
workstations, I need to know this too.  


-- 
Hank van Cleef  
vancleef@iastate.edu	Iowa State University, Ames. Ia.
tmn!vancleef		The Union Institute, Cincinnati, Oh.

mogul@pa.dec.com (Jeffrey Mogul) (06/11/91)

In article <1991Jun7.214327.21897@news.iastate.edu> vancleef@iastate.edu (Van Cleef Henry H) writes:
>I am doing some profile-type testing in which I use the gettimeofday(2)
>function, which returns a struct timeval with seconds and microseconds.
>
>What is the granularity of the clock in updating the microsecond field.
>That is, how many microseconds are added?  
>
>Hardware involved is DECstation 2100, 3100, and 5000, running Ultrix 
>4.1 (soon to update to 4.2).  If the values are different on different
>workstations, I need to know this too.  

DECstations are set up to interrupt at 256 Hz, or 3906.25 uSec per tick.

However, the hardware is capable of running at a variety of other
clock rates.  I've tried running at up to 8196 Hz, and I've had reasonable
luck running at 4096 Hz (for some network tracing experiments that I
am doing, which require fine-grain timing).  Some things (such as ntp
and the X keyboard driver) break with such high clock rates, but on
a DS3100 or DS5000/200, the high clock interrupt rate doesn't seem
to soak up too much of the CPU (for my purposes).

If other people would like my modified clock driver (FOR RESEARCH
PURPOSES ONLY; I am SURE that Digital will not, and should not, support
systems modified to run like this) for Ultrix 4.2, we can probably
work something out.  (Please don't ask about code for previous releases
of Ultrix, unless you can offer an enormous bribe!)  If you have Ultrix
kernel sources, that would make it easier for me.  Otherwise, I can
send a modified binary.

-Jeff

P.S.: The catch: people who take me up on this offer will be asked if they
are willing to run some network-measurement code that I've been working
with.  This means giving up use of a DS5000 for a day or two, since it
has to run standalone.  In exchange, you help science and you get an
acknowledgement if I write another paper about this.