Re: Fast path efficiency (Re: [rfc][patch] dynamic data structure switching)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Oleg Verych <[email protected]> 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 [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux