summaryrefslogtreecommitdiff
path: root/src/thread/pthread_spin_lock.c
AgeCommit message (Collapse)Author
2015-04-22minor optimization to pthread_spin_trylockRich Felker
use CAS instead of swap since it's lighter for most archs, and keep EBUSY in the lock value so that the old value obtained by CAS can be used directly as the return value for pthread_spin_trylock.
2015-04-22optimize spin lock not to dirty cache line while spinningRich Felker
2011-09-16fix more instances of old a_xchg (use new a_swap name)Rich Felker
2011-03-28revert some more spin optimizations that turned out to be pessimizationsRich Felker
2011-03-28fix broken spinlock due to miscompilationRich Felker
actually this trick also seems to have made the uncontended case slower.
2011-03-24optimize spinlock spinRich Felker
2011-02-12initial check-in, version 0.5.0v0.5.0Rich Felker