summaryrefslogtreecommitdiff
path: root/sysdeps/unix/sysv/linux/powerpc
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 /sysdeps/unix/sysv/linux/powerpc
parent1448f3244714a9dabb5240ec18b094f100887d5c (diff)
downloadglibc-a1ffb40e32741f992c743e7b16c061fefa3747ac.tar.gz
Use glibc_likely instead __builtin_expect.
Diffstat (limited to 'sysdeps/unix/sysv/linux/powerpc')
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/fchownat.c4
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/get_clockfreq.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/sysdeps/unix/sysv/linux/powerpc/fchownat.c b/sysdeps/unix/sysv/linux/powerpc/fchownat.c
index 61e0a4dc56..4e3767a6a0 100644
--- a/sysdeps/unix/sysv/linux/powerpc/fchownat.c
+++ b/sysdeps/unix/sysv/linux/powerpc/fchownat.c
@@ -65,7 +65,7 @@ fchownat (int fd, const char *file, uid_t owner, gid_t group, int flag)
if (fd != AT_FDCWD && file[0] != '/')
{
size_t filelen = strlen (file);
- if (__builtin_expect (filelen == 0, 0))
+ if (__glibc_unlikely (filelen == 0))
{
__set_errno (ENOENT);
return -1;
@@ -93,7 +93,7 @@ fchownat (int fd, const char *file, uid_t owner, gid_t group, int flag)
else
result = INTERNAL_SYSCALL (chown, err, 3, file, owner, group);
- if (__builtin_expect (INTERNAL_SYSCALL_ERROR_P (result, err), 0))
+ if (__glibc_unlikely (INTERNAL_SYSCALL_ERROR_P (result, err)))
{
__atfct_seterrno (INTERNAL_SYSCALL_ERRNO (result, err), fd, buf);
return -1;
diff --git a/sysdeps/unix/sysv/linux/powerpc/get_clockfreq.c b/sysdeps/unix/sysv/linux/powerpc/get_clockfreq.c
index 0a6aa81fb0..8b37943863 100644
--- a/sysdeps/unix/sysv/linux/powerpc/get_clockfreq.c
+++ b/sysdeps/unix/sysv/linux/powerpc/get_clockfreq.c
@@ -49,7 +49,7 @@ __get_clockfreq (void)
{
int fd = __open ("/proc/cpuinfo", O_RDONLY);
- if (__builtin_expect (fd != -1, 1))
+ if (__glibc_likely (fd != -1))
{
/* The timebase will be in the 1st 1024 bytes for systems with up
to 8 processors. If the first read returns less then 1024
@@ -87,7 +87,7 @@ __get_clockfreq (void)
{
char *mhz = memmem (buf, n, "timebase", 7);
- if (__builtin_expect (mhz != NULL, 1))
+ if (__glibc_likely (mhz != NULL))
{
char *endp = buf + n;