On Tuesday 07 March 2006 02:52, Benjamin LaHaise wrote:

> Those 1-2 cycles are free if you look at how things get scheduled with the 
> execution of the surrounding code. I bet $20 that you can't find a modern 
> CPU where the cost is measurable (meaning something like a P4, Athlon).  
> If this level of cost for the common case is a concern, it's probably worth 
> making atomic_dec_and_test() inline for page_cache_release().  The overhead 
> of the function call and the PageCompound() test is probably more than what 
> we're talking about as you're increasing the cache footprint and actually 
> performing a write to memory.

The test should be essentially free at least on an out of order CPU. Not quite 
sure 
about in order though.

-Andi
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to