aboutsummaryrefslogtreecommitdiff
path: root/nptl/sysdeps/unix/sysv/linux/s390
diff options
context:
space:
mode:
authorOndřej Bílka <neleai@seznam.cz>2014-02-10 14:45:42 +0100
committerOndřej Bílka <neleai@seznam.cz>2014-02-10 15:07:12 +0100
commita1ffb40e32741f992c743e7b16c061fefa3747ac (patch)
tree246a29a87b26cfd5d07b17070f85eb3785018de9 /nptl/sysdeps/unix/sysv/linux/s390
parent1448f3244714a9dabb5240ec18b094f100887d5c (diff)
downloadglibc-a1ffb40e32741f992c743e7b16c061fefa3747ac.tar
glibc-a1ffb40e32741f992c743e7b16c061fefa3747ac.tar.gz
glibc-a1ffb40e32741f992c743e7b16c061fefa3747ac.tar.bz2
glibc-a1ffb40e32741f992c743e7b16c061fefa3747ac.zip
Use glibc_likely instead __builtin_expect.
Diffstat (limited to 'nptl/sysdeps/unix/sysv/linux/s390')
-rw-r--r--nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.h b/nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.h
index 80dc90543b..864dcbccc0 100644
--- a/nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.h
+++ b/nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.h
@@ -233,7 +233,7 @@ static inline void
__attribute__ ((always_inline))
__lll_lock (int *futex, int private)
{
- if (__builtin_expect (atomic_compare_and_exchange_bool_acq (futex, 1, 0), 0))
+ if (__glibc_unlikely (atomic_compare_and_exchange_bool_acq (futex, 1, 0)))
{
if (__builtin_constant_p (private) && private == LLL_PRIVATE)
__lll_lock_wait_private (futex);
@@ -260,7 +260,7 @@ static inline void
__attribute__ ((always_inline))
__lll_cond_lock (int *futex, int private)
{
- if (__builtin_expect (atomic_compare_and_exchange_bool_acq (futex, 2, 0), 0))
+ if (__glibc_unlikely (atomic_compare_and_exchange_bool_acq (futex, 2, 0)))
__lll_lock_wait (futex, private);
}
#define lll_cond_lock(futex, private) __lll_cond_lock (&(futex), private)
@@ -278,7 +278,7 @@ __attribute__ ((always_inline))
__lll_timedlock (int *futex, const struct timespec *abstime, int private)
{
int result = 0;
- if (__builtin_expect (atomic_compare_and_exchange_bool_acq (futex, 1, 0), 0))
+ if (__glibc_unlikely (atomic_compare_and_exchange_bool_acq (futex, 1, 0)))
result = __lll_timedlock_wait (futex, abstime, private);
return result;
}
@@ -307,7 +307,7 @@ __lll_robust_timedlock (int *futex, const struct timespec *abstime,
int *__futexp = (futex); \
\
lll_compare_and_swap (__futexp, __oldval, __newval, "slr %2,%2"); \
- if (__builtin_expect (__oldval > 1, 0)) \
+ if (__glibc_unlikely (__oldval > 1)) \
lll_futex_wake (__futexp, 1, private); \
})
#define lll_unlock(futex, private) __lll_unlock(&(futex), private)
@@ -320,7 +320,7 @@ __lll_robust_timedlock (int *futex, const struct timespec *abstime,
int *__futexp = (futex); \
\
lll_compare_and_swap (__futexp, __oldval, __newval, "slr %2,%2"); \
- if (__builtin_expect (__oldval & FUTEX_WAITERS, 0)) \
+ if (__glibc_unlikely (__oldval & FUTEX_WAITERS)) \
lll_futex_wake (__futexp, 1, private); \
})
#define lll_robust_unlock(futex, private) \