lkml.org 
[lkml]   [1996]   [May]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Pentium microtime & SMP: A bug?
On Thu, 2 May 1996, Ulrich Windl wrote:

> If I understand SMP in Linux right (I have only a single-processor
> board), each processor can handle kernel requests (that is serve
> them). The fast timing routine for the Pentium uses the cycle counter
> in the processor (in the current one). Now I assume that both
> processors do not start with the same cycle counter; that way the
> clock offset will jump depending which processor's cycle count is
> read. (I don't know if it's possible to reset a single processor)
>
> The solution (if the problem exists) seems to be to have a cycle
> counter per processor (#ifdef SMP) instead of a single one.

i think the timer interrupts are handled by one CPU only (the master?).
That CPU's counter should be used (and is used now).

This whole issue gets messy if different CPUs get interrupts, one CPU cant
(or only with too much overhead) read the other CPUs clock counter. Btw,
the clocks syncronized, arent they? (if yes then this is only an offset
problem which can be neglected since the error is 1/jiffies => fading away
pretty quickly.)

-- mingo

ps. any news on the gettimeofday() monotonity problem? i can see it on
all systems i have. (though it's cool to go back in time 8)



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