lkml.org 
[lkml]   [1999]   [Dec]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: spin_unlock optimization
On Wed, Dec 29, 1999 at 07:44:02PM +0100, Oliver Henning wrote:
> Hi,
>
> as was mentioned on Kernel Traffic, the spin_unlock optimization (movb $0,%0
> instead of lock; btrl $0,%0) is not used at last. But could there be a
> detection routine (I know this is not a completely new and innovative idea)
> for those older PPro CPUs that require the slow version so that in the sane
> cases the optimization would be used. At least, IMHO it should be a
> compile-time option (defaulting to the slow version) to activate the fast
> version.

Yes. Runtime option is not acceptable imho. movb $0,%0 can be fast but if
you need a conditional instruction to test if the fast version can be used
uses more and more cycles.

--
---[ LGB/DC ]------------[ University Of Veszprém ]------[ Lénárt Gábor ]---
"The truth is out there" "We're l{ea,i}ving together" "The future is dark."
---[ 30/2270823 ]--------[ http://lgb.hal.vein.hu ]---------[ 87/477074 ]---
finger lgb@hal2000.hal.vein.hu for more !LINUX! SMS : lgblgb@westel900.net

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

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