lkml.org 
[lkml]   [2003]   [Oct]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [2.6 patch] add a config option for -Os compilation
Martin J. Bligh wrote:
>
> But if someone with a small cache would actually *measure* the damned
> thing, I'd be more impressed ... I've never seen that, but perhaps
> I just missed it.
>
> Point is the same either way though ... we shouldn't unconditionally
> optimise for *anyone's* system. If it's faster on all systems that anyone
> can be bothered to measure, great. If it's faster on some, and slower on
> others, a config option seems more appropriate, defaulting to the majority
> of users.
>

The thing is, that in fact kernel optimization is not that important.

The goal of kernel is to provide framework for applications to the
job well. I wasn't doing any kernels measurements - since kernel docs
are saying that -O2 is the standard. And it is really hard to measure
kernel only perfomance. (And it is rather pointless - I'm not going to
sell linux kernel ;-)))

But indeed I was testing my application on embedded system with 16K
L1 cache. Results were pretty predictable: gcc 2.95.3 + -Os was giving
some (around 2-3%) performance improvements, while 2.95.3 + -O[23] and
3.2.3 with any optimization were giving aprox. the same times. (App is
bloated with third-party libraries, C++ and threads. Save God I have
killed all exceptions - they were really really really slow on target
system.)

But on other side - since embedded systems are not that overclocked
as high-end toys - cache miss is not that painful. As of docs, NatSemi
Geode@266MHz cache miss costs exactly 266/66 == 4 cycles.

--
Ihar 'Philips' Filipau / with best regards from Saarbruecken.
--
"... and for $64000 question, could you get yourself vaguely
familiar with the notion of on-topic posting?"
-- Al Viro @ LKML

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

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