7#ifndef ZEPHYR_INCLUDE_TOOLCHAIN_XCC_H_
8#define ZEPHYR_INCLUDE_TOOLCHAIN_XCC_H_
34#define INT8_C(x) __INT8_C(x)
38#define __UINT8_C(x) x ## U
42#define UINT8_C(x) __UINT8_C(x)
50#define INT16_C(x) __INT16_C(x)
54#define __UINT16_C(x) x ## U
58#define UINT16_C(x) __UINT16_C(x)
66#define INT32_C(x) __INT32_C(x)
70#define __UINT32_C(x) x ## U
74#define UINT32_C(x) __UINT32_C(x)
82#define INT64_C(x) __INT64_C(x)
86#define __UINT64_C(x) x ## ULL
90#define UINT64_C(x) __UINT64_C(x)
94#define __INTMAX_C(x) x
98#define INTMAX_C(x) __INTMAX_C(x)
102#define __UINTMAX_C(x) x ## ULL
106#define UINTMAX_C(x) __UINTMAX_C(x)
113#define __COUNTER__ __LINE__
116#undef __in_section_unique
117#define __in_section_unique(seg) \
118 __attribute__((section("." STRINGIFY(seg) "." STRINGIFY(__COUNTER__))))
120#undef __in_section_unique_named
121#define __in_section_unique_named(seg, name) \
122 __attribute__((section("." STRINGIFY(seg) \
123 "." STRINGIFY(__COUNTER__) \
124 "." STRINGIFY(name))))
126#ifndef __GCC_LINKER_CMD__
127#include <xtensa/config/core.h>
134#if XCHAL_MEMORY_ORDER == XTHAL_BIGENDIAN
135#define __BYTE_ORDER__ __ORDER_BIG_ENDIAN__
136#elif XCHAL_MEMORY_ORDER == XTHAL_LITTLEENDIAN
137#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__
139#error "Cannot determine __BYTE_ORDER__"
144#define __builtin_unreachable() __builtin_trap()
147#define __sync_synchronize() do { __asm__ __volatile__ ("" ::: "memory"); } \
GCC toolchain abstraction.