lkml.org 
[lkml]   [1999]   [Mar]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] recover losed timer interrupt using the TSC [Re: [patch] kstat change to see how much Linux SMP really scale well]

On Mon, 15 Mar 1999, Andrea Arcangeli wrote:

> I was in the hope of some kind of pipeline since the code in the middle in
> my case was only moving a memory address to a register or to another
> memory address. But as you said the I/O latency is so high that probably
> would obfuscate any kind of clever optimization so I agree that it's
> better to make the code cleaner.

no, even if latency was smaller, the CPU simply does not overlap inb/outb
with preceding/succeeding instructions. even worse, it 'syncs' the
pipeline basically, so by moving instructions _between_ IO instructions
you increase latency. (because we lose the integration effect otherwise
that instruction could get)

> get back a KERN_NOTICE that will tell you how much ticks you lose. Since
> we can do that with a minimal overhead, why not be robust?

this is not necessarily robust. Timekeeping so far was pretty much
independent of the cycle counter. (micro-time is not, but generic
timekeeping yes). Now with your patch if the cycle counter produces
something funny, we'd not only get a message, but also broken time.

i think Andrea you are losing the generic picture. 10 msecs is _alot_ of
time, especially on systems that have a time stamp counter. We should
_not_ block interrupts for more than 10 msecs. If we do then yes we've
lost a few ticks (we've lost them in previous Linux versions too, so this
is certainly nothing new), but now we also get a message so people can fix
it. You've just increased complexity in an already complex and hard to
maintain piece of code to 'fix' the symptom of a fundamentally broken and
rare case, instead of just detecting and fixing the real reason.

-- mingo


-
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:50    [W:0.245 / U:0.732 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site