lkml.org 
[lkml]   [1999]   [Nov]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Wrong bogomips after plugging in AC powery
On Nov 02, Orin Eman wrote:

> > timer - it has 16bit counter, and runs 18 times a second
> > when 65535 is used as divider. That gives me 0.84usec precission (good
> > enough). I just wonder how long it takes to do_read_hwtimer()...
>
> It's just a few instructions at assembly level. Windows
> virtual device drivers (oh the horror) have access to a
> function which returns a 64 bit count of roughly 0.8 usec
> intervals since boot. It's nothing more than current timer
> contents + (divider * overflows since boot). Implementing
> a delay wouldn't require anywhere near as much, you just need
> to be a little careful if the current value plus delay wraps.

reading that old ISA timer is awfully slow: at least 3 in/out instructions,
usually 5-6 due to in_p/out_p which is 4-7.6 usec or 1600-3100 cycles
on my PC!.



Harald
--
All SCSI disks will from now on ___ _____
be required to send an email notice 0--,| /OOOOOOO\
24 hours prior to complete hardware failure! <_/ / /OOOOOOOOOOO\
\ \/OOOOOOOOOOOOOOO\
\ OOOOOOOOOOOOOOOOO|//
Harald Koenig, \/\/\/\/\/\/\/\/\/
Inst.f.Theoret.Astrophysik // / \\ \
koenig@tat.physik.uni-tuebingen.de ^^^^^ ^^^^^

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:0.181 / U:0.236 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site