Re: [patch] x86, mm: pass in 'total' to __copy_from_user_*nocache()

From: Ingo Molnar
Date: Mon Mar 02 2009 - 16:26:15 EST



* Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx> wrote:

> We can play games in the kernel. We do know how many sockets
> there are. We do know the cache size. We _could_ try to make
> an educated guess at whether the next user of the data will be
> DMA or not. So there are unquestionably heuristics we could
> apply, but I also do suspect that they'd inevitably be pretty
> arbitrary.

There's a higher-level meta-code argument to consider as well,
and i find it equally important: finding this rather obvious and
easy to measure performance regression caused by the
introduction of MOVNT took us two years.

That's _way_ too long - and adding more heuristics and more
complexity will just increase this latency. (as we will create
small niches of special cases with special workloads where we
might or might not regress)

So, if any such change is done, we can only do it if we have the
latency of performance-regression-finding on the order of days
or at most weaks - not years.

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