* Timing Facilities
@ 2001-02-22 5:24 Steve Poole
2001-02-22 6:10 ` Joseph P. Garcia
0 siblings, 1 reply; 3+ messages in thread
From: Steve Poole @ 2001-02-22 5:24 UTC (permalink / raw)
To: linuxppc-dev
I have written a small assembly fragment to read the TB register that runs
under Linux (YDL/BLL). What is the definition of a "tick" or "jiffie" under
Linux. When some code is run under MacOS (400MHz G4) the results are
*faster* (the numbers returned are lower) than when I run on a 500MHz G4. I
appreciate any input.
Steve...
Steve Poole
IS2 / PeerTechnologies
Phone 713.806.0329
eFax 240.539.7413
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Timing Facilities
2001-02-22 5:24 Steve Poole
@ 2001-02-22 6:10 ` Joseph P. Garcia
0 siblings, 0 replies; 3+ messages in thread
From: Joseph P. Garcia @ 2001-02-22 6:10 UTC (permalink / raw)
To: Steve Poole; +Cc: linuxppc-dev
On Wed, 21 Feb 2001 23:24:57 -0600, Steve Poole <sp@is2-isnot.com> wrote:
>
> I have written a small assembly fragment to read the TB register that runs
> under Linux (YDL/BLL). What is the definition of a "tick" or "jiffie" under
> Linux. When some code is run under MacOS (400MHz G4) the results are
> *faster* (the numbers returned are lower) than when I run on a 500MHz G4. I
> appreciate any input.
I beleive there are 1*HZ jiffies in one second. Used in the kernel's timer_list struct (to name one use), which basically has the kernel run a function at a specific time. ex, setting the 'expires' value to (jiffies + HZ) will cause it to run one second from now.
--
Joseph P. Garcia
http://www.execpc.com/~jpgarcia
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Timing Facilities
@ 2001-02-22 8:59 Iain Sandoe
0 siblings, 0 replies; 3+ messages in thread
From: Iain Sandoe @ 2001-02-22 8:59 UTC (permalink / raw)
To: Joseph P. Garcia, Steve Poole; +Cc: linuxppc-dev
Thu, Feb 22, 2001,Joseph P. Garcia wrote:
> On Wed, 21 Feb 2001 23:24:57 -0600, Steve Poole <sp@is2-isnot.com> wrote:
>> I have written a small assembly fragment to read the TB register that runs
>> under Linux (YDL/BLL). What is the definition of a "tick" or "jiffie" under
>> Linux. When some code is run under MacOS (400MHz G4) the results are
>> *faster* (the numbers returned are lower) than when I run on a 500MHz G4. I
>> appreciate any input.
>
> I beleive there are 1*HZ jiffies in one second. Used in the kernel's
> timer_list struct (to name one use), which basically has the kernel run a
> function at a specific time. ex, setting the 'expires' value to (jiffies +
> HZ) will cause it to run one second from now.
the VEA TB rate is not fixed to the processor clock - but is related to the
bus freq (IIRC). You can find the TB rate from OF (but beware of a report
that says the values stored are not always correct).
I did a similar thing a while ago - and, because high precision was not
required, just used gettime() and a few seconds sleep... to calibrate.
ciao,
Iain.
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2001-02-22 8:59 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-02-22 8:59 Timing Facilities Iain Sandoe
-- strict thread matches above, loose matches on Subject: below --
2001-02-22 5:24 Steve Poole
2001-02-22 6:10 ` Joseph P. Garcia
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).