[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <p73r6lc9gd5.fsf@bingen.suse.de>
Date: 06 Sep 2007 13:35:02 +0200
From: Andi Kleen <andi@...stfloor.org>
To: Oleg Verych <olecom@...wer.upol.cz>
Cc: Nick Piggin <npiggin@...e.de>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
David Miller <davem@...emloft.net>,
Paul McKenney <paulmck@...ibm.com>
Subject: Re: Fast path efficiency (Re: [rfc][patch] dynamic data structure switching)
Oleg Verych <olecom@...wer.upol.cz> writes:
>
> What is more efficient in general sense,
> as opposed to s,3,2,1,0 Optimized?
In general it shouldn't matter at all on any reasonably
modern CPU (let's say less than 10 years old) unless you do
it tens of thousands of times in a loop. Also gcc has reasonable
default heuristics for this kind of stuff anyways
(e.g. return NULL or return negative value is predicted
unlikely by default)
Cache misses are far more important to care about because
they cost hundreds of cycles.
-Andi
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists