Android-cuttlefish cvd tool
Macros
endian.h File Reference
#include <sys/cdefs.h>
#include <sys/param.h>
#include <winsock2.h>
Include dependency graph for endian.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define htons(x)   __builtin_bswap16(x)
 
#define htonl(x)   __builtin_bswap32(x)
 
#define ntohs(x)   __builtin_bswap16(x)
 
#define ntohl(x)   __builtin_bswap32(x)
 
#define __LITTLE_ENDIAN   1234
 
#define __BIG_ENDIAN   4321
 
#define __BYTE_ORDER   __LITTLE_ENDIAN
 
#define htonq(x)   __builtin_bswap64(x)
 
#define ntohq(x)   __builtin_bswap64(x)
 
#define htobe16(x)   __builtin_bswap16(x)
 
#define htobe32(x)   __builtin_bswap32(x)
 
#define htobe64(x)   __builtin_bswap64(x)
 
#define betoh16(x)   __builtin_bswap16(x)
 
#define betoh32(x)   __builtin_bswap32(x)
 
#define betoh64(x)   __builtin_bswap64(x)
 
#define htole16(x)   (x)
 
#define htole32(x)   (x)
 
#define htole64(x)   (x)
 
#define letoh16(x)   (x)
 
#define letoh32(x)   (x)
 
#define letoh64(x)   (x)
 
#define be16toh(x)   __builtin_bswap16(x)
 
#define be32toh(x)   __builtin_bswap32(x)
 
#define be64toh(x)   __builtin_bswap64(x)
 
#define le16toh(x)   (x)
 
#define le32toh(x)   (x)
 
#define le64toh(x)   (x)
 

Macro Definition Documentation

◆ __BIG_ENDIAN

#define __BIG_ENDIAN   4321

◆ __BYTE_ORDER

#define __BYTE_ORDER   __LITTLE_ENDIAN

◆ __LITTLE_ENDIAN

#define __LITTLE_ENDIAN   1234

◆ be16toh

#define be16toh (   x)    __builtin_bswap16(x)

◆ be32toh

#define be32toh (   x)    __builtin_bswap32(x)

◆ be64toh

#define be64toh (   x)    __builtin_bswap64(x)

◆ betoh16

#define betoh16 (   x)    __builtin_bswap16(x)

◆ betoh32

#define betoh32 (   x)    __builtin_bswap32(x)

◆ betoh64

#define betoh64 (   x)    __builtin_bswap64(x)

◆ htobe16

#define htobe16 (   x)    __builtin_bswap16(x)

◆ htobe32

#define htobe32 (   x)    __builtin_bswap32(x)

◆ htobe64

#define htobe64 (   x)    __builtin_bswap64(x)

◆ htole16

#define htole16 (   x)    (x)

◆ htole32

#define htole32 (   x)    (x)

◆ htole64

#define htole64 (   x)    (x)

◆ htonl

#define htonl (   x)    __builtin_bswap32(x)

◆ htonq

#define htonq (   x)    __builtin_bswap64(x)

◆ htons

#define htons (   x)    __builtin_bswap16(x)

◆ le16toh

#define le16toh (   x)    (x)

◆ le32toh

#define le32toh (   x)    (x)

◆ le64toh

#define le64toh (   x)    (x)

◆ letoh16

#define letoh16 (   x)    (x)

◆ letoh32

#define letoh32 (   x)    (x)

◆ letoh64

#define letoh64 (   x)    (x)

◆ ntohl

#define ntohl (   x)    __builtin_bswap32(x)

◆ ntohq

#define ntohq (   x)    __builtin_bswap64(x)

◆ ntohs

#define ntohs (   x)    __builtin_bswap16(x)