From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <199801221753.MAA10600@linux03.amt.tay1.dec.com> Date: Thu, 22 Jan 1998 12:53:52 +0500 From: Jay.Estabrook@digital.com Subject: Re: SX/PYXIS timekeeping problem In-Reply-To: <199801221714.MAA24830@rrdjazz.nist.gov> >>> Przemek Klosowski said: > > Sorry if this is naive, but doesn't alpha have a cycle counter? On Pentium, I > have done things like > cnt=RDMTR(); > sleep(1); > cnt = RDMTR() - cnt; > where RDMTR is an assembler inline reading the pentium cycle counter register. > For a 166 MHz pentium this returns pretty close to 166,000,000. Ah! Not naive at all, I'd never thought of that. It should work, I think, though it will take a bit of care (read the RPCC description in the Alpha AXP Architecture Reference Manual for details). Someone want to have a go and send me the working code? :-) :-) --Jay++ ------------------------------------------------------------------------------- American Non Sequitur Society: we don't make sense, but we do like pizza... Jay A Estabrook Alpha Migration Tools - LINUX Project Digital Equipment Corp. (978) 506-4202 or (DTN) 226-4202 151 Taylor Street - TAY1-2 enet: Jay.Estabrook@digital.com Littleton, MA 01460-1407 ------------------------------------------------------------------------------- -- To unsubscribe: send e-mail to axp-list-request@redhat.com with 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com