Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
* High resolution clock on Alpha
@ 2001-04-03 16:59 Adrian Wong
  2001-04-03 19:47 ` Bob Koehler
  2001-04-04 12:48 ` Bart Z. Lederman
  0 siblings, 2 replies; 3+ messages in thread
From: Adrian Wong @ 2001-04-03 16:59 UTC (permalink / raw)


Hello all,
I am in need of a sub-microsecond (10s of nanoseconds)
resolution clock on Alpha (particularly EV67). I tried 
get_clock(), but it's *only* microsecond accurate. Perhaps 
someone has a fragment of assembler that reads the Alpha's
real-time tick count, that will work, as long as I
know the conversion rate.

(Clearly, I am measuring very small deltas of time, what
the actual absolute clock tick means is irrelevant).

thanks
Adrian

-- 
Adrian Wong      |  NERSC, MS 50D
+1-510-486 4032  |  Lawrence Berkeley National Laboratory
atwong@nersc.gov |  1 Cyclotron Rd, Berkeley, CA 94720


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: High resolution clock on Alpha
  2001-04-03 16:59 High resolution clock on Alpha Adrian Wong
@ 2001-04-03 19:47 ` Bob Koehler
  2001-04-04 12:48 ` Bart Z. Lederman
  1 sibling, 0 replies; 3+ messages in thread
From: Bob Koehler @ 2001-04-03 19:47 UTC (permalink / raw)


In article <3ACA0176.B1BE6632@nersc.gov>, Adrian Wong <atwong@nersc.gov> writes:
> Hello all,
> I am in need of a sub-microsecond (10s of nanoseconds)
> resolution clock on Alpha (particularly EV67). I tried 
> get_clock(), but it's *only* microsecond accurate. Perhaps 
> someone has a fragment of assembler that reads the Alpha's
> real-time tick count, that will work, as long as I
> know the conversion rate.
> 

Bad idea, since you won't know when the leap ticks are inserted.
Alpha has instructions specifically designed for software timing,
perhaps you could use them.

----------------------------------------------------------------------
Bob Koehler                     | Computer Sciences Corporation
NASA GSFC Flight Software       | Federal Sector, Civil Group
                                | please remove ".aspm" when replying


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: High resolution clock on Alpha
  2001-04-03 16:59 High resolution clock on Alpha Adrian Wong
  2001-04-03 19:47 ` Bob Koehler
@ 2001-04-04 12:48 ` Bart Z. Lederman
  1 sibling, 0 replies; 3+ messages in thread
From: Bart Z. Lederman @ 2001-04-04 12:48 UTC (permalink / raw)


There is a system call, RPCC, Read Cycle Counter.

There is a "builtin" for DEC C that will give you
access to the counter, defined in builtin.h

At the moment I'm drawing a blank on which manual has
the documentation on this: I think it's in the
PAL code (I think I loaned the manual to someone).

Note that if you are running on a multi-processor
system you can get very strange results if you aren't
careful to check to see that the various counts you
pulled out and compared came from the same processor.
The counters are not synchronized between processors.

-- 
 B. Z. Lederman   Personal Opinions Only

 Posting to a News group does NOT give anyone permission
 to send me advertising by E-mail or put me on a mailing
 list of any kind.

 Please remove the "DISABLE-JUNK-EMAIL" if you have a
 legitimate reason to E-mail a response to this post.



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2001-04-04 12:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-04-03 16:59 High resolution clock on Alpha Adrian Wong
2001-04-03 19:47 ` Bob Koehler
2001-04-04 12:48 ` Bart Z. Lederman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox