+2012-10-12 H.J. Lu <hongjiu.lu@intel.com>
+
+ * sysdeps/x86/bits/byteswap.h: Include <bits/types.h>.
+ (__bswap_64): __uint64_t for unsigned 64-bit int.
+
2012-10-12 Andreas Schwab <schwab@linux-m68k.org>
* include/string.h (memmem): Declare libc hidden alias.
#define _BITS_BYTESWAP_H 1
#include <features.h>
+#include <bits/types.h>
#include <bits/wordsize.h>
/* Swap bytes in 16 bit value. */
| (((x) & 0x00000000000000ffull) << 56)))
# if __GNUC_PREREQ (4, 2)
-static __inline unsigned long long int
-__bswap_64 (unsigned long long int __bsx)
+static __inline __uint64_t
+__bswap_64 (__uint64_t __bsx)
{
return __builtin_bswap64 (__bsx);
}
# elif __WORDSIZE == 64
# define __bswap_64(x) \
(__extension__ \
- ({ register unsigned long __v, __x = (x); \
+ ({ register __uint64_t __v, __x = (x); \
if (__builtin_constant_p (__x)) \
__v = __bswap_constant_64 (__x); \
else \
# else
# define __bswap_64(x) \
(__extension__ \
- ({ union { __extension__ unsigned long long int __ll; \
+ ({ union { __extension__ __uint64_t __ll; \
unsigned int __l[2]; } __w, __r; \
if (__builtin_constant_p (x)) \
__r.__ll = __bswap_constant_64 (x); \
| (((x) & 0x000000000000ff00ull) << 40) \
| (((x) & 0x00000000000000ffull) << 56))
-static __inline unsigned long long int
-__bswap_64 (unsigned long long int __bsx)
+static __inline __uint64_t
+__bswap_64 (__uint64_t __bsx)
{
return __bswap_constant_64 (__bsx);
}