1 
2 /* Size of a pointer-to-data in bytes.  */
3 #define SIZEOF_DPTR (sizeof(void*))
4 const char info_sizeof_dptr[] = {
5   /* clang-format off */
6   'I', 'N', 'F', 'O', ':', 's', 'i', 'z', 'e', 'o', 'f', '_', 'd', 'p', 't',
7   'r', '[', ('0' + ((SIZEOF_DPTR / 10) % 10)), ('0' + (SIZEOF_DPTR % 10)), ']',
8   '\0'
9   /* clang-format on */
10 };
11 
12 /* Byte order.  Only one of these will have bytes in the right order.  */
13 static unsigned short const info_byte_order_big_endian[] = {
14   /* INFO:byte_order string for BIG_ENDIAN */
15   0x494E, 0x464F, 0x3A62, 0x7974, 0x655F, 0x6F72, 0x6465, 0x725B,
16   0x4249, 0x475F, 0x454E, 0x4449, 0x414E, 0x5D00, 0x0000
17 };
18 static unsigned short const info_byte_order_little_endian[] = {
19   /* INFO:byte_order string for LITTLE_ENDIAN */
20   0x4E49, 0x4F46, 0x623A, 0x7479, 0x5F65, 0x726F, 0x6564, 0x5B72,
21   0x494C, 0x5454, 0x454C, 0x455F, 0x444E, 0x4149, 0x5D4E, 0x0000
22 };
23 
24 /* Application Binary Interface.  */
25 
26 /* Check for (some) ARM ABIs.
27  * See e.g. http://wiki.debian.org/ArmEabiPort for some information on this. */
28 #if defined(__GNU__) && defined(__ELF__) && defined(__ARM_EABI__)
29 #  define ABI_ID "ELF ARMEABI"
30 #elif defined(__GNU__) && defined(__ELF__) && defined(__ARMEB__)
31 #  define ABI_ID "ELF ARM"
32 #elif defined(__GNU__) && defined(__ELF__) && defined(__ARMEL__)
33 #  define ABI_ID "ELF ARM"
34 
35 #elif defined(__linux__) && defined(__ELF__) && defined(__amd64__) &&         \
36   defined(__ILP32__)
37 #  define ABI_ID "ELF X32"
38 
39 #elif defined(__ELF__)
40 #  define ABI_ID "ELF"
41 #endif
42 
43 #if defined(ABI_ID)
44 static char const info_abi[] = "INFO:abi[" ABI_ID "]";
45 #endif
46