#ifndef AOM_AOM_UTIL_ENDIAN_INL_H_
#define AOM_AOM_UTIL_ENDIAN_INL_H_
#include <stdlib.h>
#include "config/aom_config.h"
#include "aom/aom_integer.h"
#if defined(__GNUC__)
#define LOCAL_GCC_VERSION …
#define LOCAL_GCC_PREREQ(maj, min) …
#else
#define LOCAL_GCC_VERSION …
#define LOCAL_GCC_PREREQ …
#endif
#ifndef __has_builtin
#define __has_builtin …
#endif
#if !defined(WORDS_BIGENDIAN) && \
(defined(__BIG_ENDIAN__) || defined(_M_PPC) || \
(defined(__BYTE_ORDER__) && (__BYTE_ORDER__ == __ORDER_BIG_ENDIAN__)))
#define WORDS_BIGENDIAN
#endif
#if defined(WORDS_BIGENDIAN)
#define HToLE32 …
#define HToLE16 …
#define HToBE64 …
#define HToBE32 …
#else
#define HToLE32(x) …
#define HToLE16(x) …
#define HToBE64(X) …
#define HToBE32(X) …
#endif
#if LOCAL_GCC_PREREQ(4, 8) || __has_builtin(__builtin_bswap16)
#define HAVE_BUILTIN_BSWAP16
#endif
#if LOCAL_GCC_PREREQ(4, 3) || __has_builtin(__builtin_bswap32)
#define HAVE_BUILTIN_BSWAP32
#endif
#if LOCAL_GCC_PREREQ(4, 3) || __has_builtin(__builtin_bswap64)
#define HAVE_BUILTIN_BSWAP64
#endif
static inline uint16_t BSwap16(uint16_t x) { … }
static inline uint32_t BSwap32(uint32_t x) { … }
static inline uint64_t BSwap64(uint64_t x) { … }
#endif