From 887865fcfab05939dabec78f5ad358d0283602d3 Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Thu, 10 Jul 2014 10:57:57 -0700 Subject: Get rid of lll_robust_trylock. --- nptl/pthread_mutex_trylock.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'nptl/pthread_mutex_trylock.c') diff --git a/nptl/pthread_mutex_trylock.c b/nptl/pthread_mutex_trylock.c index e46f22ca2c..0867b06533 100644 --- a/nptl/pthread_mutex_trylock.c +++ b/nptl/pthread_mutex_trylock.c @@ -72,7 +72,7 @@ __pthread_mutex_trylock (mutex) elision: if (lll_trylock_elision (mutex->__data.__lock, mutex->__data.__elision) != 0) - break; + break; /* Don't record the ownership. */ return 0; @@ -159,7 +159,8 @@ __pthread_mutex_trylock (mutex) } } - oldval = lll_robust_trylock (mutex->__data.__lock, id); + oldval = atomic_compare_and_exchange_val_acq (&mutex->__data.__lock, + id, 0); if (oldval != 0 && (oldval & FUTEX_OWNER_DIED) == 0) { THREAD_SETMEM (THREAD_SELF, robust_head.list_op_pending, NULL); -- cgit 1.4.1