mirror of git://git.musl-libc.org/musl
fix broken spinlock due to miscompilation
actually this trick also seems to have made the uncontended case slower.
This commit is contained in:
parent
ef839c73d7
commit
117581ca69
|
@ -2,6 +2,6 @@
|
|||
|
||||
int pthread_spin_lock(pthread_spinlock_t *s)
|
||||
{
|
||||
while (*s || a_xchg(s, 1));
|
||||
while (a_xchg(s, 1));
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue