elf.h: add PPC64_OPT_LOCALENTRY
[musl] / include / elf.h
1 #ifndef _ELF_H
2 #define _ELF_H
3
4 #ifdef __cplusplus
5 extern "C" {
6 #endif
7
8 #include <stdint.h>
9
10 typedef uint16_t Elf32_Half;
11 typedef uint16_t Elf64_Half;
12
13 typedef uint32_t Elf32_Word;
14 typedef int32_t  Elf32_Sword;
15 typedef uint32_t Elf64_Word;
16 typedef int32_t  Elf64_Sword;
17
18 typedef uint64_t Elf32_Xword;
19 typedef int64_t  Elf32_Sxword;
20 typedef uint64_t Elf64_Xword;
21 typedef int64_t  Elf64_Sxword;
22
23 typedef uint32_t Elf32_Addr;
24 typedef uint64_t Elf64_Addr;
25
26 typedef uint32_t Elf32_Off;
27 typedef uint64_t Elf64_Off;
28
29 typedef uint16_t Elf32_Section;
30 typedef uint16_t Elf64_Section;
31
32 typedef Elf32_Half Elf32_Versym;
33 typedef Elf64_Half Elf64_Versym;
34
35 #define EI_NIDENT (16)
36
37 typedef struct {
38   unsigned char e_ident[EI_NIDENT];
39   Elf32_Half    e_type;
40   Elf32_Half    e_machine;
41   Elf32_Word    e_version;
42   Elf32_Addr    e_entry;
43   Elf32_Off     e_phoff;
44   Elf32_Off     e_shoff;
45   Elf32_Word    e_flags;
46   Elf32_Half    e_ehsize;
47   Elf32_Half    e_phentsize;
48   Elf32_Half    e_phnum;
49   Elf32_Half    e_shentsize;
50   Elf32_Half    e_shnum;
51   Elf32_Half    e_shstrndx;
52 } Elf32_Ehdr;
53
54 typedef struct {
55   unsigned char e_ident[EI_NIDENT];
56   Elf64_Half    e_type;
57   Elf64_Half    e_machine;
58   Elf64_Word    e_version;
59   Elf64_Addr    e_entry;
60   Elf64_Off     e_phoff;
61   Elf64_Off     e_shoff;
62   Elf64_Word    e_flags;
63   Elf64_Half    e_ehsize;
64   Elf64_Half    e_phentsize;
65   Elf64_Half    e_phnum;
66   Elf64_Half    e_shentsize;
67   Elf64_Half    e_shnum;
68   Elf64_Half    e_shstrndx;
69 } Elf64_Ehdr;
70
71 #define EI_MAG0         0
72 #define ELFMAG0         0x7f
73
74 #define EI_MAG1         1
75 #define ELFMAG1         'E'
76
77 #define EI_MAG2         2
78 #define ELFMAG2         'L'
79
80 #define EI_MAG3         3
81 #define ELFMAG3         'F'
82
83
84 #define ELFMAG          "\177ELF"
85 #define SELFMAG         4
86
87 #define EI_CLASS        4
88 #define ELFCLASSNONE    0
89 #define ELFCLASS32      1
90 #define ELFCLASS64      2
91 #define ELFCLASSNUM     3
92
93 #define EI_DATA         5
94 #define ELFDATANONE     0
95 #define ELFDATA2LSB     1
96 #define ELFDATA2MSB     2
97 #define ELFDATANUM      3
98
99 #define EI_VERSION      6
100
101
102 #define EI_OSABI        7
103 #define ELFOSABI_NONE           0
104 #define ELFOSABI_SYSV           0
105 #define ELFOSABI_HPUX           1
106 #define ELFOSABI_NETBSD         2
107 #define ELFOSABI_LINUX          3
108 #define ELFOSABI_GNU            3
109 #define ELFOSABI_SOLARIS        6
110 #define ELFOSABI_AIX            7
111 #define ELFOSABI_IRIX           8
112 #define ELFOSABI_FREEBSD        9
113 #define ELFOSABI_TRU64          10
114 #define ELFOSABI_MODESTO        11
115 #define ELFOSABI_OPENBSD        12
116 #define ELFOSABI_ARM            97
117 #define ELFOSABI_STANDALONE     255
118
119 #define EI_ABIVERSION   8
120
121 #define EI_PAD          9
122
123
124
125 #define ET_NONE         0
126 #define ET_REL          1
127 #define ET_EXEC         2
128 #define ET_DYN          3
129 #define ET_CORE         4
130 #define ET_NUM          5
131 #define ET_LOOS         0xfe00
132 #define ET_HIOS         0xfeff
133 #define ET_LOPROC       0xff00
134 #define ET_HIPROC       0xffff
135
136
137
138 #define EM_NONE          0
139 #define EM_M32           1
140 #define EM_SPARC         2
141 #define EM_386           3
142 #define EM_68K           4
143 #define EM_88K           5
144 #define EM_860           7
145 #define EM_MIPS          8
146 #define EM_S370          9
147 #define EM_MIPS_RS3_LE  10
148
149 #define EM_PARISC       15
150 #define EM_VPP500       17
151 #define EM_SPARC32PLUS  18
152 #define EM_960          19
153 #define EM_PPC          20
154 #define EM_PPC64        21
155 #define EM_S390         22
156
157 #define EM_V800         36
158 #define EM_FR20         37
159 #define EM_RH32         38
160 #define EM_RCE          39
161 #define EM_ARM          40
162 #define EM_FAKE_ALPHA   41
163 #define EM_SH           42
164 #define EM_SPARCV9      43
165 #define EM_TRICORE      44
166 #define EM_ARC          45
167 #define EM_H8_300       46
168 #define EM_H8_300H      47
169 #define EM_H8S          48
170 #define EM_H8_500       49
171 #define EM_IA_64        50
172 #define EM_MIPS_X       51
173 #define EM_COLDFIRE     52
174 #define EM_68HC12       53
175 #define EM_MMA          54
176 #define EM_PCP          55
177 #define EM_NCPU         56
178 #define EM_NDR1         57
179 #define EM_STARCORE     58
180 #define EM_ME16         59
181 #define EM_ST100        60
182 #define EM_TINYJ        61
183 #define EM_X86_64       62
184 #define EM_PDSP         63
185
186 #define EM_FX66         66
187 #define EM_ST9PLUS      67
188 #define EM_ST7          68
189 #define EM_68HC16       69
190 #define EM_68HC11       70
191 #define EM_68HC08       71
192 #define EM_68HC05       72
193 #define EM_SVX          73
194 #define EM_ST19         74
195 #define EM_VAX          75
196 #define EM_CRIS         76
197 #define EM_JAVELIN      77
198 #define EM_FIREPATH     78
199 #define EM_ZSP          79
200 #define EM_MMIX         80
201 #define EM_HUANY        81
202 #define EM_PRISM        82
203 #define EM_AVR          83
204 #define EM_FR30         84
205 #define EM_D10V         85
206 #define EM_D30V         86
207 #define EM_V850         87
208 #define EM_M32R         88
209 #define EM_MN10300      89
210 #define EM_MN10200      90
211 #define EM_PJ           91
212 #define EM_OR1K         92
213 #define EM_OPENRISC     92
214 #define EM_ARC_A5       93
215 #define EM_ARC_COMPACT  93
216 #define EM_XTENSA       94
217 #define EM_VIDEOCORE    95
218 #define EM_TMM_GPP      96
219 #define EM_NS32K        97
220 #define EM_TPC          98
221 #define EM_SNP1K        99
222 #define EM_ST200        100
223 #define EM_IP2K         101
224 #define EM_MAX          102
225 #define EM_CR           103
226 #define EM_F2MC16       104
227 #define EM_MSP430       105
228 #define EM_BLACKFIN     106
229 #define EM_SE_C33       107
230 #define EM_SEP          108
231 #define EM_ARCA         109
232 #define EM_UNICORE      110
233 #define EM_EXCESS       111
234 #define EM_DXP          112
235 #define EM_ALTERA_NIOS2 113
236 #define EM_CRX          114
237 #define EM_XGATE        115
238 #define EM_C166         116
239 #define EM_M16C         117
240 #define EM_DSPIC30F     118
241 #define EM_CE           119
242 #define EM_M32C         120
243 #define EM_TSK3000      131
244 #define EM_RS08         132
245 #define EM_SHARC        133
246 #define EM_ECOG2        134
247 #define EM_SCORE7       135
248 #define EM_DSP24        136
249 #define EM_VIDEOCORE3   137
250 #define EM_LATTICEMICO32 138
251 #define EM_SE_C17       139
252 #define EM_TI_C6000     140
253 #define EM_TI_C2000     141
254 #define EM_TI_C5500     142
255 #define EM_TI_ARP32     143
256 #define EM_TI_PRU       144
257 #define EM_MMDSP_PLUS   160
258 #define EM_CYPRESS_M8C  161
259 #define EM_R32C         162
260 #define EM_TRIMEDIA     163
261 #define EM_QDSP6        164
262 #define EM_8051         165
263 #define EM_STXP7X       166
264 #define EM_NDS32        167
265 #define EM_ECOG1X       168
266 #define EM_MAXQ30       169
267 #define EM_XIMO16       170
268 #define EM_MANIK        171
269 #define EM_CRAYNV2      172
270 #define EM_RX           173
271 #define EM_METAG        174
272 #define EM_MCST_ELBRUS  175
273 #define EM_ECOG16       176
274 #define EM_CR16         177
275 #define EM_ETPU         178
276 #define EM_SLE9X        179
277 #define EM_L10M         180
278 #define EM_K10M         181
279 #define EM_AARCH64      183
280 #define EM_AVR32        185
281 #define EM_STM8         186
282 #define EM_TILE64       187
283 #define EM_TILEPRO      188
284 #define EM_MICROBLAZE   189
285 #define EM_CUDA         190
286 #define EM_TILEGX       191
287 #define EM_CLOUDSHIELD  192
288 #define EM_COREA_1ST    193
289 #define EM_COREA_2ND    194
290 #define EM_ARC_COMPACT2 195
291 #define EM_OPEN8        196
292 #define EM_RL78         197
293 #define EM_VIDEOCORE5   198
294 #define EM_78KOR        199
295 #define EM_56800EX      200
296 #define EM_BA1          201
297 #define EM_BA2          202
298 #define EM_XCORE        203
299 #define EM_MCHP_PIC     204
300 #define EM_KM32         210
301 #define EM_KMX32        211
302 #define EM_EMX16        212
303 #define EM_EMX8         213
304 #define EM_KVARC        214
305 #define EM_CDP          215
306 #define EM_COGE         216
307 #define EM_COOL         217
308 #define EM_NORC         218
309 #define EM_CSR_KALIMBA  219
310 #define EM_Z80          220
311 #define EM_VISIUM       221
312 #define EM_FT32         222
313 #define EM_MOXIE        223
314 #define EM_AMDGPU       224
315 #define EM_RISCV        243
316 #define EM_BPF          247
317 #define EM_NUM          248
318
319 #define EM_ALPHA        0x9026
320
321 #define EV_NONE         0
322 #define EV_CURRENT      1
323 #define EV_NUM          2
324
325 typedef struct {
326   Elf32_Word    sh_name;
327   Elf32_Word    sh_type;
328   Elf32_Word    sh_flags;
329   Elf32_Addr    sh_addr;
330   Elf32_Off     sh_offset;
331   Elf32_Word    sh_size;
332   Elf32_Word    sh_link;
333   Elf32_Word    sh_info;
334   Elf32_Word    sh_addralign;
335   Elf32_Word    sh_entsize;
336 } Elf32_Shdr;
337
338 typedef struct {
339   Elf64_Word    sh_name;
340   Elf64_Word    sh_type;
341   Elf64_Xword   sh_flags;
342   Elf64_Addr    sh_addr;
343   Elf64_Off     sh_offset;
344   Elf64_Xword   sh_size;
345   Elf64_Word    sh_link;
346   Elf64_Word    sh_info;
347   Elf64_Xword   sh_addralign;
348   Elf64_Xword   sh_entsize;
349 } Elf64_Shdr;
350
351
352
353 #define SHN_UNDEF       0
354 #define SHN_LORESERVE   0xff00
355 #define SHN_LOPROC      0xff00
356 #define SHN_BEFORE      0xff00
357
358 #define SHN_AFTER       0xff01
359
360 #define SHN_HIPROC      0xff1f
361 #define SHN_LOOS        0xff20
362 #define SHN_HIOS        0xff3f
363 #define SHN_ABS         0xfff1
364 #define SHN_COMMON      0xfff2
365 #define SHN_XINDEX      0xffff
366 #define SHN_HIRESERVE   0xffff
367
368
369
370 #define SHT_NULL          0
371 #define SHT_PROGBITS      1
372 #define SHT_SYMTAB        2
373 #define SHT_STRTAB        3
374 #define SHT_RELA          4
375 #define SHT_HASH          5
376 #define SHT_DYNAMIC       6
377 #define SHT_NOTE          7
378 #define SHT_NOBITS        8
379 #define SHT_REL           9
380 #define SHT_SHLIB         10
381 #define SHT_DYNSYM        11
382 #define SHT_INIT_ARRAY    14
383 #define SHT_FINI_ARRAY    15
384 #define SHT_PREINIT_ARRAY 16
385 #define SHT_GROUP         17
386 #define SHT_SYMTAB_SHNDX  18
387 #define SHT_NUM           19
388 #define SHT_LOOS          0x60000000
389 #define SHT_GNU_ATTRIBUTES 0x6ffffff5
390 #define SHT_GNU_HASH      0x6ffffff6
391 #define SHT_GNU_LIBLIST   0x6ffffff7
392 #define SHT_CHECKSUM      0x6ffffff8
393 #define SHT_LOSUNW        0x6ffffffa
394 #define SHT_SUNW_move     0x6ffffffa
395 #define SHT_SUNW_COMDAT   0x6ffffffb
396 #define SHT_SUNW_syminfo  0x6ffffffc
397 #define SHT_GNU_verdef    0x6ffffffd
398 #define SHT_GNU_verneed   0x6ffffffe
399 #define SHT_GNU_versym    0x6fffffff
400 #define SHT_HISUNW        0x6fffffff
401 #define SHT_HIOS          0x6fffffff
402 #define SHT_LOPROC        0x70000000
403 #define SHT_HIPROC        0x7fffffff
404 #define SHT_LOUSER        0x80000000
405 #define SHT_HIUSER        0x8fffffff
406
407 #define SHF_WRITE            (1 << 0)
408 #define SHF_ALLOC            (1 << 1)
409 #define SHF_EXECINSTR        (1 << 2)
410 #define SHF_MERGE            (1 << 4)
411 #define SHF_STRINGS          (1 << 5)
412 #define SHF_INFO_LINK        (1 << 6)
413 #define SHF_LINK_ORDER       (1 << 7)
414 #define SHF_OS_NONCONFORMING (1 << 8)
415
416 #define SHF_GROUP            (1 << 9)
417 #define SHF_TLS              (1 << 10)
418 #define SHF_COMPRESSED       (1 << 11)
419 #define SHF_MASKOS           0x0ff00000
420 #define SHF_MASKPROC         0xf0000000
421 #define SHF_ORDERED          (1 << 30)
422 #define SHF_EXCLUDE          (1U << 31)
423
424 typedef struct {
425   Elf32_Word    ch_type;
426   Elf32_Word    ch_size;
427   Elf32_Word    ch_addralign;
428 } Elf32_Chdr;
429
430 typedef struct {
431   Elf64_Word    ch_type;
432   Elf64_Word    ch_reserved;
433   Elf64_Xword   ch_size;
434   Elf64_Xword   ch_addralign;
435 } Elf64_Chdr;
436
437 #define ELFCOMPRESS_ZLIB        1
438 #define ELFCOMPRESS_LOOS        0x60000000
439 #define ELFCOMPRESS_HIOS        0x6fffffff
440 #define ELFCOMPRESS_LOPROC      0x70000000
441 #define ELFCOMPRESS_HIPROC      0x7fffffff
442
443
444 #define GRP_COMDAT      0x1
445
446 typedef struct {
447   Elf32_Word    st_name;
448   Elf32_Addr    st_value;
449   Elf32_Word    st_size;
450   unsigned char st_info;
451   unsigned char st_other;
452   Elf32_Section st_shndx;
453 } Elf32_Sym;
454
455 typedef struct {
456   Elf64_Word    st_name;
457   unsigned char st_info;
458   unsigned char st_other;
459   Elf64_Section st_shndx;
460   Elf64_Addr    st_value;
461   Elf64_Xword   st_size;
462 } Elf64_Sym;
463
464 typedef struct {
465   Elf32_Half si_boundto;
466   Elf32_Half si_flags;
467 } Elf32_Syminfo;
468
469 typedef struct {
470   Elf64_Half si_boundto;
471   Elf64_Half si_flags;
472 } Elf64_Syminfo;
473
474 #define SYMINFO_BT_SELF         0xffff
475 #define SYMINFO_BT_PARENT       0xfffe
476 #define SYMINFO_BT_LOWRESERVE   0xff00
477
478 #define SYMINFO_FLG_DIRECT      0x0001
479 #define SYMINFO_FLG_PASSTHRU    0x0002
480 #define SYMINFO_FLG_COPY        0x0004
481 #define SYMINFO_FLG_LAZYLOAD    0x0008
482
483 #define SYMINFO_NONE            0
484 #define SYMINFO_CURRENT         1
485 #define SYMINFO_NUM             2
486
487 #define ELF32_ST_BIND(val)              (((unsigned char) (val)) >> 4)
488 #define ELF32_ST_TYPE(val)              ((val) & 0xf)
489 #define ELF32_ST_INFO(bind, type)       (((bind) << 4) + ((type) & 0xf))
490
491 #define ELF64_ST_BIND(val)              ELF32_ST_BIND (val)
492 #define ELF64_ST_TYPE(val)              ELF32_ST_TYPE (val)
493 #define ELF64_ST_INFO(bind, type)       ELF32_ST_INFO ((bind), (type))
494
495 #define STB_LOCAL       0
496 #define STB_GLOBAL      1
497 #define STB_WEAK        2
498 #define STB_NUM         3
499 #define STB_LOOS        10
500 #define STB_GNU_UNIQUE  10
501 #define STB_HIOS        12
502 #define STB_LOPROC      13
503 #define STB_HIPROC      15
504
505 #define STT_NOTYPE      0
506 #define STT_OBJECT      1
507 #define STT_FUNC        2
508 #define STT_SECTION     3
509 #define STT_FILE        4
510 #define STT_COMMON      5
511 #define STT_TLS         6
512 #define STT_NUM         7
513 #define STT_LOOS        10
514 #define STT_GNU_IFUNC   10
515 #define STT_HIOS        12
516 #define STT_LOPROC      13
517 #define STT_HIPROC      15
518
519 #define STN_UNDEF       0
520
521 #define ELF32_ST_VISIBILITY(o)  ((o) & 0x03)
522 #define ELF64_ST_VISIBILITY(o)  ELF32_ST_VISIBILITY (o)
523
524 #define STV_DEFAULT     0
525 #define STV_INTERNAL    1
526 #define STV_HIDDEN      2
527 #define STV_PROTECTED   3
528
529
530
531
532 typedef struct {
533   Elf32_Addr    r_offset;
534   Elf32_Word    r_info;
535 } Elf32_Rel;
536
537 typedef struct {
538   Elf64_Addr    r_offset;
539   Elf64_Xword   r_info;
540 } Elf64_Rel;
541
542
543
544 typedef struct {
545   Elf32_Addr    r_offset;
546   Elf32_Word    r_info;
547   Elf32_Sword   r_addend;
548 } Elf32_Rela;
549
550 typedef struct {
551   Elf64_Addr    r_offset;
552   Elf64_Xword   r_info;
553   Elf64_Sxword  r_addend;
554 } Elf64_Rela;
555
556
557
558 #define ELF32_R_SYM(val)                ((val) >> 8)
559 #define ELF32_R_TYPE(val)               ((val) & 0xff)
560 #define ELF32_R_INFO(sym, type)         (((sym) << 8) + ((type) & 0xff))
561
562 #define ELF64_R_SYM(i)                  ((i) >> 32)
563 #define ELF64_R_TYPE(i)                 ((i) & 0xffffffff)
564 #define ELF64_R_INFO(sym,type)          ((((Elf64_Xword) (sym)) << 32) + (type))
565
566
567
568 typedef struct {
569   Elf32_Word    p_type;
570   Elf32_Off     p_offset;
571   Elf32_Addr    p_vaddr;
572   Elf32_Addr    p_paddr;
573   Elf32_Word    p_filesz;
574   Elf32_Word    p_memsz;
575   Elf32_Word    p_flags;
576   Elf32_Word    p_align;
577 } Elf32_Phdr;
578
579 typedef struct {
580   Elf64_Word    p_type;
581   Elf64_Word    p_flags;
582   Elf64_Off     p_offset;
583   Elf64_Addr    p_vaddr;
584   Elf64_Addr    p_paddr;
585   Elf64_Xword   p_filesz;
586   Elf64_Xword   p_memsz;
587   Elf64_Xword   p_align;
588 } Elf64_Phdr;
589
590
591
592 #define PT_NULL         0
593 #define PT_LOAD         1
594 #define PT_DYNAMIC      2
595 #define PT_INTERP       3
596 #define PT_NOTE         4
597 #define PT_SHLIB        5
598 #define PT_PHDR         6
599 #define PT_TLS          7
600 #define PT_NUM          8
601 #define PT_LOOS         0x60000000
602 #define PT_GNU_EH_FRAME 0x6474e550
603 #define PT_GNU_STACK    0x6474e551
604 #define PT_GNU_RELRO    0x6474e552
605 #define PT_LOSUNW       0x6ffffffa
606 #define PT_SUNWBSS      0x6ffffffa
607 #define PT_SUNWSTACK    0x6ffffffb
608 #define PT_HISUNW       0x6fffffff
609 #define PT_HIOS         0x6fffffff
610 #define PT_LOPROC       0x70000000
611 #define PT_HIPROC       0x7fffffff
612
613
614 #define PN_XNUM 0xffff
615
616
617 #define PF_X            (1 << 0)
618 #define PF_W            (1 << 1)
619 #define PF_R            (1 << 2)
620 #define PF_MASKOS       0x0ff00000
621 #define PF_MASKPROC     0xf0000000
622
623
624
625 #define NT_PRSTATUS     1
626 #define NT_FPREGSET     2
627 #define NT_PRPSINFO     3
628 #define NT_PRXREG       4
629 #define NT_TASKSTRUCT   4
630 #define NT_PLATFORM     5
631 #define NT_AUXV         6
632 #define NT_GWINDOWS     7
633 #define NT_ASRS         8
634 #define NT_PSTATUS      10
635 #define NT_PSINFO       13
636 #define NT_PRCRED       14
637 #define NT_UTSNAME      15
638 #define NT_LWPSTATUS    16
639 #define NT_LWPSINFO     17
640 #define NT_PRFPXREG     20
641 #define NT_SIGINFO      0x53494749
642 #define NT_FILE         0x46494c45
643 #define NT_PRXFPREG     0x46e62b7f
644 #define NT_PPC_VMX      0x100
645 #define NT_PPC_SPE      0x101
646 #define NT_PPC_VSX      0x102
647 #define NT_386_TLS      0x200
648 #define NT_386_IOPERM   0x201
649 #define NT_X86_XSTATE   0x202
650 #define NT_S390_HIGH_GPRS       0x300
651 #define NT_S390_TIMER   0x301
652 #define NT_S390_TODCMP  0x302
653 #define NT_S390_TODPREG 0x303
654 #define NT_S390_CTRS    0x304
655 #define NT_S390_PREFIX  0x305
656 #define NT_S390_LAST_BREAK      0x306
657 #define NT_S390_SYSTEM_CALL     0x307
658 #define NT_S390_TDB     0x308
659 #define NT_ARM_VFP      0x400
660 #define NT_ARM_TLS      0x401
661 #define NT_ARM_HW_BREAK 0x402
662 #define NT_ARM_HW_WATCH 0x403
663 #define NT_ARM_SYSTEM_CALL      0x404
664 #define NT_METAG_CBUF   0x500
665 #define NT_METAG_RPIPE  0x501
666 #define NT_METAG_TLS    0x502
667 #define NT_VERSION      1
668
669
670
671
672 typedef struct {
673   Elf32_Sword d_tag;
674   union {
675       Elf32_Word d_val;
676       Elf32_Addr d_ptr;
677   } d_un;
678 } Elf32_Dyn;
679
680 typedef struct {
681   Elf64_Sxword d_tag;
682   union {
683       Elf64_Xword d_val;
684       Elf64_Addr d_ptr;
685   } d_un;
686 } Elf64_Dyn;
687
688
689
690 #define DT_NULL         0
691 #define DT_NEEDED       1
692 #define DT_PLTRELSZ     2
693 #define DT_PLTGOT       3
694 #define DT_HASH         4
695 #define DT_STRTAB       5
696 #define DT_SYMTAB       6
697 #define DT_RELA         7
698 #define DT_RELASZ       8
699 #define DT_RELAENT      9
700 #define DT_STRSZ        10
701 #define DT_SYMENT       11
702 #define DT_INIT         12
703 #define DT_FINI         13
704 #define DT_SONAME       14
705 #define DT_RPATH        15
706 #define DT_SYMBOLIC     16
707 #define DT_REL          17
708 #define DT_RELSZ        18
709 #define DT_RELENT       19
710 #define DT_PLTREL       20
711 #define DT_DEBUG        21
712 #define DT_TEXTREL      22
713 #define DT_JMPREL       23
714 #define DT_BIND_NOW     24
715 #define DT_INIT_ARRAY   25
716 #define DT_FINI_ARRAY   26
717 #define DT_INIT_ARRAYSZ 27
718 #define DT_FINI_ARRAYSZ 28
719 #define DT_RUNPATH      29
720 #define DT_FLAGS        30
721 #define DT_ENCODING     32
722 #define DT_PREINIT_ARRAY 32
723 #define DT_PREINIT_ARRAYSZ 33
724 #define DT_NUM          34
725 #define DT_LOOS         0x6000000d
726 #define DT_HIOS         0x6ffff000
727 #define DT_LOPROC       0x70000000
728 #define DT_HIPROC       0x7fffffff
729 #define DT_PROCNUM      DT_MIPS_NUM
730
731 #define DT_VALRNGLO     0x6ffffd00
732 #define DT_GNU_PRELINKED 0x6ffffdf5
733 #define DT_GNU_CONFLICTSZ 0x6ffffdf6
734 #define DT_GNU_LIBLISTSZ 0x6ffffdf7
735 #define DT_CHECKSUM     0x6ffffdf8
736 #define DT_PLTPADSZ     0x6ffffdf9
737 #define DT_MOVEENT      0x6ffffdfa
738 #define DT_MOVESZ       0x6ffffdfb
739 #define DT_FEATURE_1    0x6ffffdfc
740 #define DT_POSFLAG_1    0x6ffffdfd
741
742 #define DT_SYMINSZ      0x6ffffdfe
743 #define DT_SYMINENT     0x6ffffdff
744 #define DT_VALRNGHI     0x6ffffdff
745 #define DT_VALTAGIDX(tag)       (DT_VALRNGHI - (tag))
746 #define DT_VALNUM 12
747
748 #define DT_ADDRRNGLO    0x6ffffe00
749 #define DT_GNU_HASH     0x6ffffef5
750 #define DT_TLSDESC_PLT  0x6ffffef6
751 #define DT_TLSDESC_GOT  0x6ffffef7
752 #define DT_GNU_CONFLICT 0x6ffffef8
753 #define DT_GNU_LIBLIST  0x6ffffef9
754 #define DT_CONFIG       0x6ffffefa
755 #define DT_DEPAUDIT     0x6ffffefb
756 #define DT_AUDIT        0x6ffffefc
757 #define DT_PLTPAD       0x6ffffefd
758 #define DT_MOVETAB      0x6ffffefe
759 #define DT_SYMINFO      0x6ffffeff
760 #define DT_ADDRRNGHI    0x6ffffeff
761 #define DT_ADDRTAGIDX(tag)      (DT_ADDRRNGHI - (tag))
762 #define DT_ADDRNUM 11
763
764
765
766 #define DT_VERSYM       0x6ffffff0
767
768 #define DT_RELACOUNT    0x6ffffff9
769 #define DT_RELCOUNT     0x6ffffffa
770
771
772 #define DT_FLAGS_1      0x6ffffffb
773 #define DT_VERDEF       0x6ffffffc
774
775 #define DT_VERDEFNUM    0x6ffffffd
776 #define DT_VERNEED      0x6ffffffe
777
778 #define DT_VERNEEDNUM   0x6fffffff
779 #define DT_VERSIONTAGIDX(tag)   (DT_VERNEEDNUM - (tag))
780 #define DT_VERSIONTAGNUM 16
781
782
783
784 #define DT_AUXILIARY    0x7ffffffd
785 #define DT_FILTER       0x7fffffff
786 #define DT_EXTRATAGIDX(tag)     ((Elf32_Word)-((Elf32_Sword) (tag) <<1>>1)-1)
787 #define DT_EXTRANUM     3
788
789
790 #define DF_ORIGIN       0x00000001
791 #define DF_SYMBOLIC     0x00000002
792 #define DF_TEXTREL      0x00000004
793 #define DF_BIND_NOW     0x00000008
794 #define DF_STATIC_TLS   0x00000010
795
796
797
798 #define DF_1_NOW        0x00000001
799 #define DF_1_GLOBAL     0x00000002
800 #define DF_1_GROUP      0x00000004
801 #define DF_1_NODELETE   0x00000008
802 #define DF_1_LOADFLTR   0x00000010
803 #define DF_1_INITFIRST  0x00000020
804 #define DF_1_NOOPEN     0x00000040
805 #define DF_1_ORIGIN     0x00000080
806 #define DF_1_DIRECT     0x00000100
807 #define DF_1_TRANS      0x00000200
808 #define DF_1_INTERPOSE  0x00000400
809 #define DF_1_NODEFLIB   0x00000800
810 #define DF_1_NODUMP     0x00001000
811 #define DF_1_CONFALT    0x00002000
812 #define DF_1_ENDFILTEE  0x00004000
813 #define DF_1_DISPRELDNE 0x00008000
814 #define DF_1_DISPRELPND 0x00010000
815 #define DF_1_NODIRECT   0x00020000
816 #define DF_1_IGNMULDEF  0x00040000
817 #define DF_1_NOKSYMS    0x00080000
818 #define DF_1_NOHDR      0x00100000
819 #define DF_1_EDITED     0x00200000
820 #define DF_1_NORELOC    0x00400000
821 #define DF_1_SYMINTPOSE 0x00800000
822 #define DF_1_GLOBAUDIT  0x01000000
823 #define DF_1_SINGLETON  0x02000000
824
825 #define DTF_1_PARINIT   0x00000001
826 #define DTF_1_CONFEXP   0x00000002
827
828
829 #define DF_P1_LAZYLOAD  0x00000001
830 #define DF_P1_GROUPPERM 0x00000002
831
832
833
834
835 typedef struct {
836   Elf32_Half    vd_version;
837   Elf32_Half    vd_flags;
838   Elf32_Half    vd_ndx;
839   Elf32_Half    vd_cnt;
840   Elf32_Word    vd_hash;
841   Elf32_Word    vd_aux;
842   Elf32_Word    vd_next;
843 } Elf32_Verdef;
844
845 typedef struct {
846   Elf64_Half    vd_version;
847   Elf64_Half    vd_flags;
848   Elf64_Half    vd_ndx;
849   Elf64_Half    vd_cnt;
850   Elf64_Word    vd_hash;
851   Elf64_Word    vd_aux;
852   Elf64_Word    vd_next;
853 } Elf64_Verdef;
854
855
856
857 #define VER_DEF_NONE    0
858 #define VER_DEF_CURRENT 1
859 #define VER_DEF_NUM     2
860
861
862 #define VER_FLG_BASE    0x1
863 #define VER_FLG_WEAK    0x2
864
865
866 #define VER_NDX_LOCAL           0
867 #define VER_NDX_GLOBAL          1
868 #define VER_NDX_LORESERVE       0xff00
869 #define VER_NDX_ELIMINATE       0xff01
870
871
872
873 typedef struct {
874   Elf32_Word    vda_name;
875   Elf32_Word    vda_next;
876 } Elf32_Verdaux;
877
878 typedef struct {
879   Elf64_Word    vda_name;
880   Elf64_Word    vda_next;
881 } Elf64_Verdaux;
882
883
884
885
886 typedef struct {
887   Elf32_Half    vn_version;
888   Elf32_Half    vn_cnt;
889   Elf32_Word    vn_file;
890   Elf32_Word    vn_aux;
891   Elf32_Word    vn_next;
892 } Elf32_Verneed;
893
894 typedef struct {
895   Elf64_Half    vn_version;
896   Elf64_Half    vn_cnt;
897   Elf64_Word    vn_file;
898   Elf64_Word    vn_aux;
899   Elf64_Word    vn_next;
900 } Elf64_Verneed;
901
902
903
904 #define VER_NEED_NONE    0
905 #define VER_NEED_CURRENT 1
906 #define VER_NEED_NUM     2
907
908
909
910 typedef struct {
911   Elf32_Word    vna_hash;
912   Elf32_Half    vna_flags;
913   Elf32_Half    vna_other;
914   Elf32_Word    vna_name;
915   Elf32_Word    vna_next;
916 } Elf32_Vernaux;
917
918 typedef struct {
919   Elf64_Word    vna_hash;
920   Elf64_Half    vna_flags;
921   Elf64_Half    vna_other;
922   Elf64_Word    vna_name;
923   Elf64_Word    vna_next;
924 } Elf64_Vernaux;
925
926
927
928 #define VER_FLG_WEAK    0x2
929
930
931
932 typedef struct {
933   uint32_t a_type;
934   union {
935       uint32_t a_val;
936   } a_un;
937 } Elf32_auxv_t;
938
939 typedef struct {
940   uint64_t a_type;
941   union {
942       uint64_t a_val;
943   } a_un;
944 } Elf64_auxv_t;
945
946
947
948 #define AT_NULL         0
949 #define AT_IGNORE       1
950 #define AT_EXECFD       2
951 #define AT_PHDR         3
952 #define AT_PHENT        4
953 #define AT_PHNUM        5
954 #define AT_PAGESZ       6
955 #define AT_BASE         7
956 #define AT_FLAGS        8
957 #define AT_ENTRY        9
958 #define AT_NOTELF       10
959 #define AT_UID          11
960 #define AT_EUID         12
961 #define AT_GID          13
962 #define AT_EGID         14
963 #define AT_CLKTCK       17
964
965
966 #define AT_PLATFORM     15
967 #define AT_HWCAP        16
968
969
970
971
972 #define AT_FPUCW        18
973
974
975 #define AT_DCACHEBSIZE  19
976 #define AT_ICACHEBSIZE  20
977 #define AT_UCACHEBSIZE  21
978
979
980
981 #define AT_IGNOREPPC    22
982
983 #define AT_SECURE       23
984
985 #define AT_BASE_PLATFORM 24
986
987 #define AT_RANDOM       25
988
989 #define AT_HWCAP2       26
990
991 #define AT_EXECFN       31
992
993
994
995 #define AT_SYSINFO      32
996 #define AT_SYSINFO_EHDR 33
997
998
999
1000 #define AT_L1I_CACHESHAPE       34
1001 #define AT_L1D_CACHESHAPE       35
1002 #define AT_L2_CACHESHAPE        36
1003 #define AT_L3_CACHESHAPE        37
1004
1005 #define AT_L1I_CACHESIZE        40
1006 #define AT_L1I_CACHEGEOMETRY    41
1007 #define AT_L1D_CACHESIZE        42
1008 #define AT_L1D_CACHEGEOMETRY    43
1009 #define AT_L2_CACHESIZE         44
1010 #define AT_L2_CACHEGEOMETRY     45
1011 #define AT_L3_CACHESIZE         46
1012 #define AT_L3_CACHEGEOMETRY     47
1013
1014
1015
1016 typedef struct {
1017   Elf32_Word n_namesz;
1018   Elf32_Word n_descsz;
1019   Elf32_Word n_type;
1020 } Elf32_Nhdr;
1021
1022 typedef struct {
1023   Elf64_Word n_namesz;
1024   Elf64_Word n_descsz;
1025   Elf64_Word n_type;
1026 } Elf64_Nhdr;
1027
1028
1029
1030
1031 #define ELF_NOTE_SOLARIS        "SUNW Solaris"
1032
1033
1034 #define ELF_NOTE_GNU            "GNU"
1035
1036
1037
1038
1039
1040 #define ELF_NOTE_PAGESIZE_HINT  1
1041
1042
1043 #define NT_GNU_ABI_TAG  1
1044 #define ELF_NOTE_ABI    NT_GNU_ABI_TAG
1045
1046
1047
1048 #define ELF_NOTE_OS_LINUX       0
1049 #define ELF_NOTE_OS_GNU         1
1050 #define ELF_NOTE_OS_SOLARIS2    2
1051 #define ELF_NOTE_OS_FREEBSD     3
1052
1053 #define NT_GNU_BUILD_ID 3
1054 #define NT_GNU_GOLD_VERSION     4
1055
1056
1057
1058 typedef struct {
1059   Elf32_Xword m_value;
1060   Elf32_Word m_info;
1061   Elf32_Word m_poffset;
1062   Elf32_Half m_repeat;
1063   Elf32_Half m_stride;
1064 } Elf32_Move;
1065
1066 typedef struct {
1067   Elf64_Xword m_value;
1068   Elf64_Xword m_info;
1069   Elf64_Xword m_poffset;
1070   Elf64_Half m_repeat;
1071   Elf64_Half m_stride;
1072 } Elf64_Move;
1073
1074
1075 #define ELF32_M_SYM(info)       ((info) >> 8)
1076 #define ELF32_M_SIZE(info)      ((unsigned char) (info))
1077 #define ELF32_M_INFO(sym, size) (((sym) << 8) + (unsigned char) (size))
1078
1079 #define ELF64_M_SYM(info)       ELF32_M_SYM (info)
1080 #define ELF64_M_SIZE(info)      ELF32_M_SIZE (info)
1081 #define ELF64_M_INFO(sym, size) ELF32_M_INFO (sym, size)
1082
1083 #define EF_CPU32        0x00810000
1084
1085 #define R_68K_NONE      0
1086 #define R_68K_32        1
1087 #define R_68K_16        2
1088 #define R_68K_8         3
1089 #define R_68K_PC32      4
1090 #define R_68K_PC16      5
1091 #define R_68K_PC8       6
1092 #define R_68K_GOT32     7
1093 #define R_68K_GOT16     8
1094 #define R_68K_GOT8      9
1095 #define R_68K_GOT32O    10
1096 #define R_68K_GOT16O    11
1097 #define R_68K_GOT8O     12
1098 #define R_68K_PLT32     13
1099 #define R_68K_PLT16     14
1100 #define R_68K_PLT8      15
1101 #define R_68K_PLT32O    16
1102 #define R_68K_PLT16O    17
1103 #define R_68K_PLT8O     18
1104 #define R_68K_COPY      19
1105 #define R_68K_GLOB_DAT  20
1106 #define R_68K_JMP_SLOT  21
1107 #define R_68K_RELATIVE  22
1108 #define R_68K_NUM       23
1109
1110 #define R_386_NONE         0
1111 #define R_386_32           1
1112 #define R_386_PC32         2
1113 #define R_386_GOT32        3
1114 #define R_386_PLT32        4
1115 #define R_386_COPY         5
1116 #define R_386_GLOB_DAT     6
1117 #define R_386_JMP_SLOT     7
1118 #define R_386_RELATIVE     8
1119 #define R_386_GOTOFF       9
1120 #define R_386_GOTPC        10
1121 #define R_386_32PLT        11
1122 #define R_386_TLS_TPOFF    14
1123 #define R_386_TLS_IE       15
1124 #define R_386_TLS_GOTIE    16
1125 #define R_386_TLS_LE       17
1126 #define R_386_TLS_GD       18
1127 #define R_386_TLS_LDM      19
1128 #define R_386_16           20
1129 #define R_386_PC16         21
1130 #define R_386_8            22
1131 #define R_386_PC8          23
1132 #define R_386_TLS_GD_32    24
1133 #define R_386_TLS_GD_PUSH  25
1134 #define R_386_TLS_GD_CALL  26
1135 #define R_386_TLS_GD_POP   27
1136 #define R_386_TLS_LDM_32   28
1137 #define R_386_TLS_LDM_PUSH 29
1138 #define R_386_TLS_LDM_CALL 30
1139 #define R_386_TLS_LDM_POP  31
1140 #define R_386_TLS_LDO_32   32
1141 #define R_386_TLS_IE_32    33
1142 #define R_386_TLS_LE_32    34
1143 #define R_386_TLS_DTPMOD32 35
1144 #define R_386_TLS_DTPOFF32 36
1145 #define R_386_TLS_TPOFF32  37
1146 #define R_386_SIZE32       38
1147 #define R_386_TLS_GOTDESC  39
1148 #define R_386_TLS_DESC_CALL 40
1149 #define R_386_TLS_DESC     41
1150 #define R_386_IRELATIVE    42
1151 #define R_386_GOT32X       43
1152 #define R_386_NUM          44
1153
1154
1155
1156
1157
1158 #define STT_SPARC_REGISTER      13
1159
1160
1161
1162 #define EF_SPARCV9_MM           3
1163 #define EF_SPARCV9_TSO          0
1164 #define EF_SPARCV9_PSO          1
1165 #define EF_SPARCV9_RMO          2
1166 #define EF_SPARC_LEDATA         0x800000
1167 #define EF_SPARC_EXT_MASK       0xFFFF00
1168 #define EF_SPARC_32PLUS         0x000100
1169 #define EF_SPARC_SUN_US1        0x000200
1170 #define EF_SPARC_HAL_R1         0x000400
1171 #define EF_SPARC_SUN_US3        0x000800
1172
1173
1174
1175 #define R_SPARC_NONE            0
1176 #define R_SPARC_8               1
1177 #define R_SPARC_16              2
1178 #define R_SPARC_32              3
1179 #define R_SPARC_DISP8           4
1180 #define R_SPARC_DISP16          5
1181 #define R_SPARC_DISP32          6
1182 #define R_SPARC_WDISP30         7
1183 #define R_SPARC_WDISP22         8
1184 #define R_SPARC_HI22            9
1185 #define R_SPARC_22              10
1186 #define R_SPARC_13              11
1187 #define R_SPARC_LO10            12
1188 #define R_SPARC_GOT10           13
1189 #define R_SPARC_GOT13           14
1190 #define R_SPARC_GOT22           15
1191 #define R_SPARC_PC10            16
1192 #define R_SPARC_PC22            17
1193 #define R_SPARC_WPLT30          18
1194 #define R_SPARC_COPY            19
1195 #define R_SPARC_GLOB_DAT        20
1196 #define R_SPARC_JMP_SLOT        21
1197 #define R_SPARC_RELATIVE        22
1198 #define R_SPARC_UA32            23
1199
1200
1201
1202 #define R_SPARC_PLT32           24
1203 #define R_SPARC_HIPLT22         25
1204 #define R_SPARC_LOPLT10         26
1205 #define R_SPARC_PCPLT32         27
1206 #define R_SPARC_PCPLT22         28
1207 #define R_SPARC_PCPLT10         29
1208 #define R_SPARC_10              30
1209 #define R_SPARC_11              31
1210 #define R_SPARC_64              32
1211 #define R_SPARC_OLO10           33
1212 #define R_SPARC_HH22            34
1213 #define R_SPARC_HM10            35
1214 #define R_SPARC_LM22            36
1215 #define R_SPARC_PC_HH22         37
1216 #define R_SPARC_PC_HM10         38
1217 #define R_SPARC_PC_LM22         39
1218 #define R_SPARC_WDISP16         40
1219 #define R_SPARC_WDISP19         41
1220 #define R_SPARC_GLOB_JMP        42
1221 #define R_SPARC_7               43
1222 #define R_SPARC_5               44
1223 #define R_SPARC_6               45
1224 #define R_SPARC_DISP64          46
1225 #define R_SPARC_PLT64           47
1226 #define R_SPARC_HIX22           48
1227 #define R_SPARC_LOX10           49
1228 #define R_SPARC_H44             50
1229 #define R_SPARC_M44             51
1230 #define R_SPARC_L44             52
1231 #define R_SPARC_REGISTER        53
1232 #define R_SPARC_UA64            54
1233 #define R_SPARC_UA16            55
1234 #define R_SPARC_TLS_GD_HI22     56
1235 #define R_SPARC_TLS_GD_LO10     57
1236 #define R_SPARC_TLS_GD_ADD      58
1237 #define R_SPARC_TLS_GD_CALL     59
1238 #define R_SPARC_TLS_LDM_HI22    60
1239 #define R_SPARC_TLS_LDM_LO10    61
1240 #define R_SPARC_TLS_LDM_ADD     62
1241 #define R_SPARC_TLS_LDM_CALL    63
1242 #define R_SPARC_TLS_LDO_HIX22   64
1243 #define R_SPARC_TLS_LDO_LOX10   65
1244 #define R_SPARC_TLS_LDO_ADD     66
1245 #define R_SPARC_TLS_IE_HI22     67
1246 #define R_SPARC_TLS_IE_LO10     68
1247 #define R_SPARC_TLS_IE_LD       69
1248 #define R_SPARC_TLS_IE_LDX      70
1249 #define R_SPARC_TLS_IE_ADD      71
1250 #define R_SPARC_TLS_LE_HIX22    72
1251 #define R_SPARC_TLS_LE_LOX10    73
1252 #define R_SPARC_TLS_DTPMOD32    74
1253 #define R_SPARC_TLS_DTPMOD64    75
1254 #define R_SPARC_TLS_DTPOFF32    76
1255 #define R_SPARC_TLS_DTPOFF64    77
1256 #define R_SPARC_TLS_TPOFF32     78
1257 #define R_SPARC_TLS_TPOFF64     79
1258 #define R_SPARC_GOTDATA_HIX22   80
1259 #define R_SPARC_GOTDATA_LOX10   81
1260 #define R_SPARC_GOTDATA_OP_HIX22        82
1261 #define R_SPARC_GOTDATA_OP_LOX10        83
1262 #define R_SPARC_GOTDATA_OP      84
1263 #define R_SPARC_H34             85
1264 #define R_SPARC_SIZE32          86
1265 #define R_SPARC_SIZE64          87
1266 #define R_SPARC_GNU_VTINHERIT   250
1267 #define R_SPARC_GNU_VTENTRY     251
1268 #define R_SPARC_REV32           252
1269
1270 #define R_SPARC_NUM             253
1271
1272
1273
1274 #define DT_SPARC_REGISTER 0x70000001
1275 #define DT_SPARC_NUM    2
1276
1277
1278 #define EF_MIPS_NOREORDER   1
1279 #define EF_MIPS_PIC         2
1280 #define EF_MIPS_CPIC        4
1281 #define EF_MIPS_XGOT        8
1282 #define EF_MIPS_64BIT_WHIRL 16
1283 #define EF_MIPS_ABI2        32
1284 #define EF_MIPS_ABI_ON32    64
1285 #define EF_MIPS_FP64        512
1286 #define EF_MIPS_NAN2008     1024
1287 #define EF_MIPS_ARCH        0xf0000000
1288
1289
1290
1291 #define EF_MIPS_ARCH_1      0x00000000
1292 #define EF_MIPS_ARCH_2      0x10000000
1293 #define EF_MIPS_ARCH_3      0x20000000
1294 #define EF_MIPS_ARCH_4      0x30000000
1295 #define EF_MIPS_ARCH_5      0x40000000
1296 #define EF_MIPS_ARCH_32     0x50000000
1297 #define EF_MIPS_ARCH_64     0x60000000
1298 #define EF_MIPS_ARCH_32R2   0x70000000
1299 #define EF_MIPS_ARCH_64R2   0x80000000
1300
1301
1302 #define E_MIPS_ARCH_1     0x00000000
1303 #define E_MIPS_ARCH_2     0x10000000
1304 #define E_MIPS_ARCH_3     0x20000000
1305 #define E_MIPS_ARCH_4     0x30000000
1306 #define E_MIPS_ARCH_5     0x40000000
1307 #define E_MIPS_ARCH_32    0x50000000
1308 #define E_MIPS_ARCH_64    0x60000000
1309
1310
1311
1312 #define SHN_MIPS_ACOMMON    0xff00
1313 #define SHN_MIPS_TEXT       0xff01
1314 #define SHN_MIPS_DATA       0xff02
1315 #define SHN_MIPS_SCOMMON    0xff03
1316 #define SHN_MIPS_SUNDEFINED 0xff04
1317
1318
1319
1320 #define SHT_MIPS_LIBLIST       0x70000000
1321 #define SHT_MIPS_MSYM          0x70000001
1322 #define SHT_MIPS_CONFLICT      0x70000002
1323 #define SHT_MIPS_GPTAB         0x70000003
1324 #define SHT_MIPS_UCODE         0x70000004
1325 #define SHT_MIPS_DEBUG         0x70000005
1326 #define SHT_MIPS_REGINFO       0x70000006
1327 #define SHT_MIPS_PACKAGE       0x70000007
1328 #define SHT_MIPS_PACKSYM       0x70000008
1329 #define SHT_MIPS_RELD          0x70000009
1330 #define SHT_MIPS_IFACE         0x7000000b
1331 #define SHT_MIPS_CONTENT       0x7000000c
1332 #define SHT_MIPS_OPTIONS       0x7000000d
1333 #define SHT_MIPS_SHDR          0x70000010
1334 #define SHT_MIPS_FDESC         0x70000011
1335 #define SHT_MIPS_EXTSYM        0x70000012
1336 #define SHT_MIPS_DENSE         0x70000013
1337 #define SHT_MIPS_PDESC         0x70000014
1338 #define SHT_MIPS_LOCSYM        0x70000015
1339 #define SHT_MIPS_AUXSYM        0x70000016
1340 #define SHT_MIPS_OPTSYM        0x70000017
1341 #define SHT_MIPS_LOCSTR        0x70000018
1342 #define SHT_MIPS_LINE          0x70000019
1343 #define SHT_MIPS_RFDESC        0x7000001a
1344 #define SHT_MIPS_DELTASYM      0x7000001b
1345 #define SHT_MIPS_DELTAINST     0x7000001c
1346 #define SHT_MIPS_DELTACLASS    0x7000001d
1347 #define SHT_MIPS_DWARF         0x7000001e
1348 #define SHT_MIPS_DELTADECL     0x7000001f
1349 #define SHT_MIPS_SYMBOL_LIB    0x70000020
1350 #define SHT_MIPS_EVENTS        0x70000021
1351 #define SHT_MIPS_TRANSLATE     0x70000022
1352 #define SHT_MIPS_PIXIE         0x70000023
1353 #define SHT_MIPS_XLATE         0x70000024
1354 #define SHT_MIPS_XLATE_DEBUG   0x70000025
1355 #define SHT_MIPS_WHIRL         0x70000026
1356 #define SHT_MIPS_EH_REGION     0x70000027
1357 #define SHT_MIPS_XLATE_OLD     0x70000028
1358 #define SHT_MIPS_PDR_EXCEPTION 0x70000029
1359
1360
1361
1362 #define SHF_MIPS_GPREL   0x10000000
1363 #define SHF_MIPS_MERGE   0x20000000
1364 #define SHF_MIPS_ADDR    0x40000000
1365 #define SHF_MIPS_STRINGS 0x80000000
1366 #define SHF_MIPS_NOSTRIP 0x08000000
1367 #define SHF_MIPS_LOCAL   0x04000000
1368 #define SHF_MIPS_NAMES   0x02000000
1369 #define SHF_MIPS_NODUPE  0x01000000
1370
1371
1372
1373
1374
1375 #define STO_MIPS_DEFAULT                0x0
1376 #define STO_MIPS_INTERNAL               0x1
1377 #define STO_MIPS_HIDDEN                 0x2
1378 #define STO_MIPS_PROTECTED              0x3
1379 #define STO_MIPS_PLT                    0x8
1380 #define STO_MIPS_SC_ALIGN_UNUSED        0xff
1381
1382
1383 #define STB_MIPS_SPLIT_COMMON           13
1384
1385
1386
1387 typedef union {
1388   struct {
1389       Elf32_Word gt_current_g_value;
1390       Elf32_Word gt_unused;
1391   } gt_header;
1392   struct {
1393       Elf32_Word gt_g_value;
1394       Elf32_Word gt_bytes;
1395   } gt_entry;
1396 } Elf32_gptab;
1397
1398
1399
1400 typedef struct {
1401   Elf32_Word    ri_gprmask;
1402   Elf32_Word    ri_cprmask[4];
1403   Elf32_Sword   ri_gp_value;
1404 } Elf32_RegInfo;
1405
1406
1407
1408 typedef struct {
1409   unsigned char kind;
1410
1411   unsigned char size;
1412   Elf32_Section section;
1413
1414   Elf32_Word info;
1415 } Elf_Options;
1416
1417
1418
1419 #define ODK_NULL        0
1420 #define ODK_REGINFO     1
1421 #define ODK_EXCEPTIONS  2
1422 #define ODK_PAD         3
1423 #define ODK_HWPATCH     4
1424 #define ODK_FILL        5
1425 #define ODK_TAGS        6
1426 #define ODK_HWAND       7
1427 #define ODK_HWOR        8
1428
1429
1430
1431 #define OEX_FPU_MIN     0x1f
1432 #define OEX_FPU_MAX     0x1f00
1433 #define OEX_PAGE0       0x10000
1434 #define OEX_SMM         0x20000
1435 #define OEX_FPDBUG      0x40000
1436 #define OEX_PRECISEFP   OEX_FPDBUG
1437 #define OEX_DISMISS     0x80000
1438
1439 #define OEX_FPU_INVAL   0x10
1440 #define OEX_FPU_DIV0    0x08
1441 #define OEX_FPU_OFLO    0x04
1442 #define OEX_FPU_UFLO    0x02
1443 #define OEX_FPU_INEX    0x01
1444
1445
1446
1447 #define OHW_R4KEOP      0x1
1448 #define OHW_R8KPFETCH   0x2
1449 #define OHW_R5KEOP      0x4
1450 #define OHW_R5KCVTL     0x8
1451
1452 #define OPAD_PREFIX     0x1
1453 #define OPAD_POSTFIX    0x2
1454 #define OPAD_SYMBOL     0x4
1455
1456
1457
1458 typedef struct {
1459   Elf32_Word hwp_flags1;
1460   Elf32_Word hwp_flags2;
1461 } Elf_Options_Hw;
1462
1463
1464
1465 #define OHWA0_R4KEOP_CHECKED    0x00000001
1466 #define OHWA1_R4KEOP_CLEAN      0x00000002
1467
1468
1469
1470 #define R_MIPS_NONE             0
1471 #define R_MIPS_16               1
1472 #define R_MIPS_32               2
1473 #define R_MIPS_REL32            3
1474 #define R_MIPS_26               4
1475 #define R_MIPS_HI16             5
1476 #define R_MIPS_LO16             6
1477 #define R_MIPS_GPREL16          7
1478 #define R_MIPS_LITERAL          8
1479 #define R_MIPS_GOT16            9
1480 #define R_MIPS_PC16             10
1481 #define R_MIPS_CALL16           11
1482 #define R_MIPS_GPREL32          12
1483
1484 #define R_MIPS_SHIFT5           16
1485 #define R_MIPS_SHIFT6           17
1486 #define R_MIPS_64               18
1487 #define R_MIPS_GOT_DISP         19
1488 #define R_MIPS_GOT_PAGE         20
1489 #define R_MIPS_GOT_OFST         21
1490 #define R_MIPS_GOT_HI16         22
1491 #define R_MIPS_GOT_LO16         23
1492 #define R_MIPS_SUB              24
1493 #define R_MIPS_INSERT_A         25
1494 #define R_MIPS_INSERT_B         26
1495 #define R_MIPS_DELETE           27
1496 #define R_MIPS_HIGHER           28
1497 #define R_MIPS_HIGHEST          29
1498 #define R_MIPS_CALL_HI16        30
1499 #define R_MIPS_CALL_LO16        31
1500 #define R_MIPS_SCN_DISP         32
1501 #define R_MIPS_REL16            33
1502 #define R_MIPS_ADD_IMMEDIATE    34
1503 #define R_MIPS_PJUMP            35
1504 #define R_MIPS_RELGOT           36
1505 #define R_MIPS_JALR             37
1506 #define R_MIPS_TLS_DTPMOD32     38
1507 #define R_MIPS_TLS_DTPREL32     39
1508 #define R_MIPS_TLS_DTPMOD64     40
1509 #define R_MIPS_TLS_DTPREL64     41
1510 #define R_MIPS_TLS_GD           42
1511 #define R_MIPS_TLS_LDM          43
1512 #define R_MIPS_TLS_DTPREL_HI16  44
1513 #define R_MIPS_TLS_DTPREL_LO16  45
1514 #define R_MIPS_TLS_GOTTPREL     46
1515 #define R_MIPS_TLS_TPREL32      47
1516 #define R_MIPS_TLS_TPREL64      48
1517 #define R_MIPS_TLS_TPREL_HI16   49
1518 #define R_MIPS_TLS_TPREL_LO16   50
1519 #define R_MIPS_GLOB_DAT         51
1520 #define R_MIPS_COPY             126
1521 #define R_MIPS_JUMP_SLOT        127
1522
1523 #define R_MIPS_NUM              128
1524
1525
1526
1527 #define PT_MIPS_REGINFO 0x70000000
1528 #define PT_MIPS_RTPROC  0x70000001
1529 #define PT_MIPS_OPTIONS 0x70000002
1530 #define PT_MIPS_ABIFLAGS 0x70000003
1531
1532
1533
1534 #define PF_MIPS_LOCAL   0x10000000
1535
1536
1537
1538 #define DT_MIPS_RLD_VERSION  0x70000001
1539 #define DT_MIPS_TIME_STAMP   0x70000002
1540 #define DT_MIPS_ICHECKSUM    0x70000003
1541 #define DT_MIPS_IVERSION     0x70000004
1542 #define DT_MIPS_FLAGS        0x70000005
1543 #define DT_MIPS_BASE_ADDRESS 0x70000006
1544 #define DT_MIPS_MSYM         0x70000007
1545 #define DT_MIPS_CONFLICT     0x70000008
1546 #define DT_MIPS_LIBLIST      0x70000009
1547 #define DT_MIPS_LOCAL_GOTNO  0x7000000a
1548 #define DT_MIPS_CONFLICTNO   0x7000000b
1549 #define DT_MIPS_LIBLISTNO    0x70000010
1550 #define DT_MIPS_SYMTABNO     0x70000011
1551 #define DT_MIPS_UNREFEXTNO   0x70000012
1552 #define DT_MIPS_GOTSYM       0x70000013
1553 #define DT_MIPS_HIPAGENO     0x70000014
1554 #define DT_MIPS_RLD_MAP      0x70000016
1555 #define DT_MIPS_DELTA_CLASS  0x70000017
1556 #define DT_MIPS_DELTA_CLASS_NO    0x70000018
1557
1558 #define DT_MIPS_DELTA_INSTANCE    0x70000019
1559 #define DT_MIPS_DELTA_INSTANCE_NO 0x7000001a
1560
1561 #define DT_MIPS_DELTA_RELOC  0x7000001b
1562 #define DT_MIPS_DELTA_RELOC_NO 0x7000001c
1563
1564 #define DT_MIPS_DELTA_SYM    0x7000001d
1565
1566 #define DT_MIPS_DELTA_SYM_NO 0x7000001e
1567
1568 #define DT_MIPS_DELTA_CLASSSYM 0x70000020
1569
1570 #define DT_MIPS_DELTA_CLASSSYM_NO 0x70000021
1571
1572 #define DT_MIPS_CXX_FLAGS    0x70000022
1573 #define DT_MIPS_PIXIE_INIT   0x70000023
1574 #define DT_MIPS_SYMBOL_LIB   0x70000024
1575 #define DT_MIPS_LOCALPAGE_GOTIDX 0x70000025
1576 #define DT_MIPS_LOCAL_GOTIDX 0x70000026
1577 #define DT_MIPS_HIDDEN_GOTIDX 0x70000027
1578 #define DT_MIPS_PROTECTED_GOTIDX 0x70000028
1579 #define DT_MIPS_OPTIONS      0x70000029
1580 #define DT_MIPS_INTERFACE    0x7000002a
1581 #define DT_MIPS_DYNSTR_ALIGN 0x7000002b
1582 #define DT_MIPS_INTERFACE_SIZE 0x7000002c
1583 #define DT_MIPS_RLD_TEXT_RESOLVE_ADDR 0x7000002d
1584
1585 #define DT_MIPS_PERF_SUFFIX  0x7000002e
1586
1587 #define DT_MIPS_COMPACT_SIZE 0x7000002f
1588 #define DT_MIPS_GP_VALUE     0x70000030
1589 #define DT_MIPS_AUX_DYNAMIC  0x70000031
1590
1591 #define DT_MIPS_PLTGOT       0x70000032
1592
1593 #define DT_MIPS_RWPLT        0x70000034
1594 #define DT_MIPS_RLD_MAP_REL  0x70000035
1595 #define DT_MIPS_NUM          0x36
1596
1597
1598
1599 #define RHF_NONE                   0
1600 #define RHF_QUICKSTART             (1 << 0)
1601 #define RHF_NOTPOT                 (1 << 1)
1602 #define RHF_NO_LIBRARY_REPLACEMENT (1 << 2)
1603 #define RHF_NO_MOVE                (1 << 3)
1604 #define RHF_SGI_ONLY               (1 << 4)
1605 #define RHF_GUARANTEE_INIT         (1 << 5)
1606 #define RHF_DELTA_C_PLUS_PLUS      (1 << 6)
1607 #define RHF_GUARANTEE_START_INIT   (1 << 7)
1608 #define RHF_PIXIE                  (1 << 8)
1609 #define RHF_DEFAULT_DELAY_LOAD     (1 << 9)
1610 #define RHF_REQUICKSTART           (1 << 10)
1611 #define RHF_REQUICKSTARTED         (1 << 11)
1612 #define RHF_CORD                   (1 << 12)
1613 #define RHF_NO_UNRES_UNDEF         (1 << 13)
1614 #define RHF_RLD_ORDER_SAFE         (1 << 14)
1615
1616
1617
1618 typedef struct {
1619   Elf32_Word l_name;
1620   Elf32_Word l_time_stamp;
1621   Elf32_Word l_checksum;
1622   Elf32_Word l_version;
1623   Elf32_Word l_flags;
1624 } Elf32_Lib;
1625
1626 typedef struct {
1627   Elf64_Word l_name;
1628   Elf64_Word l_time_stamp;
1629   Elf64_Word l_checksum;
1630   Elf64_Word l_version;
1631   Elf64_Word l_flags;
1632 } Elf64_Lib;
1633
1634
1635
1636
1637 #define LL_NONE           0
1638 #define LL_EXACT_MATCH    (1 << 0)
1639 #define LL_IGNORE_INT_VER (1 << 1)
1640 #define LL_REQUIRE_MINOR  (1 << 2)
1641 #define LL_EXPORTS        (1 << 3)
1642 #define LL_DELAY_LOAD     (1 << 4)
1643 #define LL_DELTA          (1 << 5)
1644
1645
1646
1647 typedef Elf32_Addr Elf32_Conflict;
1648
1649 typedef struct {
1650   Elf32_Half version;
1651   unsigned char isa_level;
1652   unsigned char isa_rev;
1653   unsigned char gpr_size;
1654   unsigned char cpr1_size;
1655   unsigned char cpr2_size;
1656   unsigned char fp_abi;
1657   Elf32_Word isa_ext;
1658   Elf32_Word ases;
1659   Elf32_Word flags1;
1660   Elf32_Word flags2;
1661 } Elf_MIPS_ABIFlags_v0;
1662
1663 #define MIPS_AFL_REG_NONE       0x00
1664 #define MIPS_AFL_REG_32         0x01
1665 #define MIPS_AFL_REG_64         0x02
1666 #define MIPS_AFL_REG_128        0x03
1667
1668 #define MIPS_AFL_ASE_DSP        0x00000001
1669 #define MIPS_AFL_ASE_DSPR2      0x00000002
1670 #define MIPS_AFL_ASE_EVA        0x00000004
1671 #define MIPS_AFL_ASE_MCU        0x00000008
1672 #define MIPS_AFL_ASE_MDMX       0x00000010
1673 #define MIPS_AFL_ASE_MIPS3D     0x00000020
1674 #define MIPS_AFL_ASE_MT         0x00000040
1675 #define MIPS_AFL_ASE_SMARTMIPS  0x00000080
1676 #define MIPS_AFL_ASE_VIRT       0x00000100
1677 #define MIPS_AFL_ASE_MSA        0x00000200
1678 #define MIPS_AFL_ASE_MIPS16     0x00000400
1679 #define MIPS_AFL_ASE_MICROMIPS  0x00000800
1680 #define MIPS_AFL_ASE_XPA        0x00001000
1681 #define MIPS_AFL_ASE_MASK       0x00001fff
1682
1683 #define MIPS_AFL_EXT_XLR          1
1684 #define MIPS_AFL_EXT_OCTEON2      2
1685 #define MIPS_AFL_EXT_OCTEONP      3
1686 #define MIPS_AFL_EXT_LOONGSON_3A  4
1687 #define MIPS_AFL_EXT_OCTEON       5
1688 #define MIPS_AFL_EXT_5900         6
1689 #define MIPS_AFL_EXT_4650         7
1690 #define MIPS_AFL_EXT_4010         8
1691 #define MIPS_AFL_EXT_4100         9
1692 #define MIPS_AFL_EXT_3900         10
1693 #define MIPS_AFL_EXT_10000        11
1694 #define MIPS_AFL_EXT_SB1          12
1695 #define MIPS_AFL_EXT_4111         13
1696 #define MIPS_AFL_EXT_4120         14
1697 #define MIPS_AFL_EXT_5400         15
1698 #define MIPS_AFL_EXT_5500         16
1699 #define MIPS_AFL_EXT_LOONGSON_2E  17
1700 #define MIPS_AFL_EXT_LOONGSON_2F  18
1701
1702 #define MIPS_AFL_FLAGS1_ODDSPREG  1
1703
1704 enum
1705 {
1706   Val_GNU_MIPS_ABI_FP_ANY = 0,
1707   Val_GNU_MIPS_ABI_FP_DOUBLE = 1,
1708   Val_GNU_MIPS_ABI_FP_SINGLE = 2,
1709   Val_GNU_MIPS_ABI_FP_SOFT = 3,
1710   Val_GNU_MIPS_ABI_FP_OLD_64 = 4,
1711   Val_GNU_MIPS_ABI_FP_XX = 5,
1712   Val_GNU_MIPS_ABI_FP_64 = 6,
1713   Val_GNU_MIPS_ABI_FP_64A = 7,
1714   Val_GNU_MIPS_ABI_FP_MAX = 7
1715 };
1716
1717
1718
1719
1720 #define EF_PARISC_TRAPNIL       0x00010000
1721 #define EF_PARISC_EXT           0x00020000
1722 #define EF_PARISC_LSB           0x00040000
1723 #define EF_PARISC_WIDE          0x00080000
1724 #define EF_PARISC_NO_KABP       0x00100000
1725
1726 #define EF_PARISC_LAZYSWAP      0x00400000
1727 #define EF_PARISC_ARCH          0x0000ffff
1728
1729
1730
1731 #define EFA_PARISC_1_0              0x020b
1732 #define EFA_PARISC_1_1              0x0210
1733 #define EFA_PARISC_2_0              0x0214
1734
1735
1736
1737 #define SHN_PARISC_ANSI_COMMON  0xff00
1738
1739 #define SHN_PARISC_HUGE_COMMON  0xff01
1740
1741
1742
1743 #define SHT_PARISC_EXT          0x70000000
1744 #define SHT_PARISC_UNWIND       0x70000001
1745 #define SHT_PARISC_DOC          0x70000002
1746
1747
1748
1749 #define SHF_PARISC_SHORT        0x20000000
1750 #define SHF_PARISC_HUGE         0x40000000
1751 #define SHF_PARISC_SBP          0x80000000
1752
1753
1754
1755 #define STT_PARISC_MILLICODE    13
1756
1757 #define STT_HP_OPAQUE           (STT_LOOS + 0x1)
1758 #define STT_HP_STUB             (STT_LOOS + 0x2)
1759
1760
1761
1762 #define R_PARISC_NONE           0
1763 #define R_PARISC_DIR32          1
1764 #define R_PARISC_DIR21L         2
1765 #define R_PARISC_DIR17R         3
1766 #define R_PARISC_DIR17F         4
1767 #define R_PARISC_DIR14R         6
1768 #define R_PARISC_PCREL32        9
1769 #define R_PARISC_PCREL21L       10
1770 #define R_PARISC_PCREL17R       11
1771 #define R_PARISC_PCREL17F       12
1772 #define R_PARISC_PCREL14R       14
1773 #define R_PARISC_DPREL21L       18
1774 #define R_PARISC_DPREL14R       22
1775 #define R_PARISC_GPREL21L       26
1776 #define R_PARISC_GPREL14R       30
1777 #define R_PARISC_LTOFF21L       34
1778 #define R_PARISC_LTOFF14R       38
1779 #define R_PARISC_SECREL32       41
1780 #define R_PARISC_SEGBASE        48
1781 #define R_PARISC_SEGREL32       49
1782 #define R_PARISC_PLTOFF21L      50
1783 #define R_PARISC_PLTOFF14R      54
1784 #define R_PARISC_LTOFF_FPTR32   57
1785 #define R_PARISC_LTOFF_FPTR21L  58
1786 #define R_PARISC_LTOFF_FPTR14R  62
1787 #define R_PARISC_FPTR64         64
1788 #define R_PARISC_PLABEL32       65
1789 #define R_PARISC_PLABEL21L      66
1790 #define R_PARISC_PLABEL14R      70
1791 #define R_PARISC_PCREL64        72
1792 #define R_PARISC_PCREL22F       74
1793 #define R_PARISC_PCREL14WR      75
1794 #define R_PARISC_PCREL14DR      76
1795 #define R_PARISC_PCREL16F       77
1796 #define R_PARISC_PCREL16WF      78
1797 #define R_PARISC_PCREL16DF      79
1798 #define R_PARISC_DIR64          80
1799 #define R_PARISC_DIR14WR        83
1800 #define R_PARISC_DIR14DR        84
1801 #define R_PARISC_DIR16F         85
1802 #define R_PARISC_DIR16WF        86
1803 #define R_PARISC_DIR16DF        87
1804 #define R_PARISC_GPREL64        88
1805 #define R_PARISC_GPREL14WR      91
1806 #define R_PARISC_GPREL14DR      92
1807 #define R_PARISC_GPREL16F       93
1808 #define R_PARISC_GPREL16WF      94
1809 #define R_PARISC_GPREL16DF      95
1810 #define R_PARISC_LTOFF64        96
1811 #define R_PARISC_LTOFF14WR      99
1812 #define R_PARISC_LTOFF14DR      100
1813 #define R_PARISC_LTOFF16F       101
1814 #define R_PARISC_LTOFF16WF      102
1815 #define R_PARISC_LTOFF16DF      103
1816 #define R_PARISC_SECREL64       104
1817 #define R_PARISC_SEGREL64       112
1818 #define R_PARISC_PLTOFF14WR     115
1819 #define R_PARISC_PLTOFF14DR     116
1820 #define R_PARISC_PLTOFF16F      117
1821 #define R_PARISC_PLTOFF16WF     118
1822 #define R_PARISC_PLTOFF16DF     119
1823 #define R_PARISC_LTOFF_FPTR64   120
1824 #define R_PARISC_LTOFF_FPTR14WR 123
1825 #define R_PARISC_LTOFF_FPTR14DR 124
1826 #define R_PARISC_LTOFF_FPTR16F  125
1827 #define R_PARISC_LTOFF_FPTR16WF 126
1828 #define R_PARISC_LTOFF_FPTR16DF 127
1829 #define R_PARISC_LORESERVE      128
1830 #define R_PARISC_COPY           128
1831 #define R_PARISC_IPLT           129
1832 #define R_PARISC_EPLT           130
1833 #define R_PARISC_TPREL32        153
1834 #define R_PARISC_TPREL21L       154
1835 #define R_PARISC_TPREL14R       158
1836 #define R_PARISC_LTOFF_TP21L    162
1837 #define R_PARISC_LTOFF_TP14R    166
1838 #define R_PARISC_LTOFF_TP14F    167
1839 #define R_PARISC_TPREL64        216
1840 #define R_PARISC_TPREL14WR      219
1841 #define R_PARISC_TPREL14DR      220
1842 #define R_PARISC_TPREL16F       221
1843 #define R_PARISC_TPREL16WF      222
1844 #define R_PARISC_TPREL16DF      223
1845 #define R_PARISC_LTOFF_TP64     224
1846 #define R_PARISC_LTOFF_TP14WR   227
1847 #define R_PARISC_LTOFF_TP14DR   228
1848 #define R_PARISC_LTOFF_TP16F    229
1849 #define R_PARISC_LTOFF_TP16WF   230
1850 #define R_PARISC_LTOFF_TP16DF   231
1851 #define R_PARISC_GNU_VTENTRY    232
1852 #define R_PARISC_GNU_VTINHERIT  233
1853 #define R_PARISC_TLS_GD21L      234
1854 #define R_PARISC_TLS_GD14R      235
1855 #define R_PARISC_TLS_GDCALL     236
1856 #define R_PARISC_TLS_LDM21L     237
1857 #define R_PARISC_TLS_LDM14R     238
1858 #define R_PARISC_TLS_LDMCALL    239
1859 #define R_PARISC_TLS_LDO21L     240
1860 #define R_PARISC_TLS_LDO14R     241
1861 #define R_PARISC_TLS_DTPMOD32   242
1862 #define R_PARISC_TLS_DTPMOD64   243
1863 #define R_PARISC_TLS_DTPOFF32   244
1864 #define R_PARISC_TLS_DTPOFF64   245
1865 #define R_PARISC_TLS_LE21L      R_PARISC_TPREL21L
1866 #define R_PARISC_TLS_LE14R      R_PARISC_TPREL14R
1867 #define R_PARISC_TLS_IE21L      R_PARISC_LTOFF_TP21L
1868 #define R_PARISC_TLS_IE14R      R_PARISC_LTOFF_TP14R
1869 #define R_PARISC_TLS_TPREL32    R_PARISC_TPREL32
1870 #define R_PARISC_TLS_TPREL64    R_PARISC_TPREL64
1871 #define R_PARISC_HIRESERVE      255
1872
1873
1874
1875 #define PT_HP_TLS               (PT_LOOS + 0x0)
1876 #define PT_HP_CORE_NONE         (PT_LOOS + 0x1)
1877 #define PT_HP_CORE_VERSION      (PT_LOOS + 0x2)
1878 #define PT_HP_CORE_KERNEL       (PT_LOOS + 0x3)
1879 #define PT_HP_CORE_COMM         (PT_LOOS + 0x4)
1880 #define PT_HP_CORE_PROC         (PT_LOOS + 0x5)
1881 #define PT_HP_CORE_LOADABLE     (PT_LOOS + 0x6)
1882 #define PT_HP_CORE_STACK        (PT_LOOS + 0x7)
1883 #define PT_HP_CORE_SHM          (PT_LOOS + 0x8)
1884 #define PT_HP_CORE_MMF          (PT_LOOS + 0x9)
1885 #define PT_HP_PARALLEL          (PT_LOOS + 0x10)
1886 #define PT_HP_FASTBIND          (PT_LOOS + 0x11)
1887 #define PT_HP_OPT_ANNOT         (PT_LOOS + 0x12)
1888 #define PT_HP_HSL_ANNOT         (PT_LOOS + 0x13)
1889 #define PT_HP_STACK             (PT_LOOS + 0x14)
1890
1891 #define PT_PARISC_ARCHEXT       0x70000000
1892 #define PT_PARISC_UNWIND        0x70000001
1893
1894
1895
1896 #define PF_PARISC_SBP           0x08000000
1897
1898 #define PF_HP_PAGE_SIZE         0x00100000
1899 #define PF_HP_FAR_SHARED        0x00200000
1900 #define PF_HP_NEAR_SHARED       0x00400000
1901 #define PF_HP_CODE              0x01000000
1902 #define PF_HP_MODIFY            0x02000000
1903 #define PF_HP_LAZYSWAP          0x04000000
1904 #define PF_HP_SBP               0x08000000
1905
1906
1907
1908
1909
1910
1911 #define EF_ALPHA_32BIT          1
1912 #define EF_ALPHA_CANRELAX       2
1913
1914
1915
1916
1917 #define SHT_ALPHA_DEBUG         0x70000001
1918 #define SHT_ALPHA_REGINFO       0x70000002
1919
1920
1921
1922 #define SHF_ALPHA_GPREL         0x10000000
1923
1924
1925 #define STO_ALPHA_NOPV          0x80
1926 #define STO_ALPHA_STD_GPLOAD    0x88
1927
1928
1929
1930 #define R_ALPHA_NONE            0
1931 #define R_ALPHA_REFLONG         1
1932 #define R_ALPHA_REFQUAD         2
1933 #define R_ALPHA_GPREL32         3
1934 #define R_ALPHA_LITERAL         4
1935 #define R_ALPHA_LITUSE          5
1936 #define R_ALPHA_GPDISP          6
1937 #define R_ALPHA_BRADDR          7
1938 #define R_ALPHA_HINT            8
1939 #define R_ALPHA_SREL16          9
1940 #define R_ALPHA_SREL32          10
1941 #define R_ALPHA_SREL64          11
1942 #define R_ALPHA_GPRELHIGH       17
1943 #define R_ALPHA_GPRELLOW        18
1944 #define R_ALPHA_GPREL16         19
1945 #define R_ALPHA_COPY            24
1946 #define R_ALPHA_GLOB_DAT        25
1947 #define R_ALPHA_JMP_SLOT        26
1948 #define R_ALPHA_RELATIVE        27
1949 #define R_ALPHA_TLS_GD_HI       28
1950 #define R_ALPHA_TLSGD           29
1951 #define R_ALPHA_TLS_LDM         30
1952 #define R_ALPHA_DTPMOD64        31
1953 #define R_ALPHA_GOTDTPREL       32
1954 #define R_ALPHA_DTPREL64        33
1955 #define R_ALPHA_DTPRELHI        34
1956 #define R_ALPHA_DTPRELLO        35
1957 #define R_ALPHA_DTPREL16        36
1958 #define R_ALPHA_GOTTPREL        37
1959 #define R_ALPHA_TPREL64         38
1960 #define R_ALPHA_TPRELHI         39
1961 #define R_ALPHA_TPRELLO         40
1962 #define R_ALPHA_TPREL16         41
1963
1964 #define R_ALPHA_NUM             46
1965
1966
1967 #define LITUSE_ALPHA_ADDR       0
1968 #define LITUSE_ALPHA_BASE       1
1969 #define LITUSE_ALPHA_BYTOFF     2
1970 #define LITUSE_ALPHA_JSR        3
1971 #define LITUSE_ALPHA_TLS_GD     4
1972 #define LITUSE_ALPHA_TLS_LDM    5
1973
1974
1975 #define DT_ALPHA_PLTRO          (DT_LOPROC + 0)
1976 #define DT_ALPHA_NUM            1
1977
1978
1979
1980
1981 #define EF_PPC_EMB              0x80000000
1982
1983
1984 #define EF_PPC_RELOCATABLE      0x00010000
1985 #define EF_PPC_RELOCATABLE_LIB  0x00008000
1986
1987
1988
1989 #define R_PPC_NONE              0
1990 #define R_PPC_ADDR32            1
1991 #define R_PPC_ADDR24            2
1992 #define R_PPC_ADDR16            3
1993 #define R_PPC_ADDR16_LO         4
1994 #define R_PPC_ADDR16_HI         5
1995 #define R_PPC_ADDR16_HA         6
1996 #define R_PPC_ADDR14            7
1997 #define R_PPC_ADDR14_BRTAKEN    8
1998 #define R_PPC_ADDR14_BRNTAKEN   9
1999 #define R_PPC_REL24             10
2000 #define R_PPC_REL14             11
2001 #define R_PPC_REL14_BRTAKEN     12
2002 #define R_PPC_REL14_BRNTAKEN    13
2003 #define R_PPC_GOT16             14
2004 #define R_PPC_GOT16_LO          15
2005 #define R_PPC_GOT16_HI          16
2006 #define R_PPC_GOT16_HA          17
2007 #define R_PPC_PLTREL24          18
2008 #define R_PPC_COPY              19
2009 #define R_PPC_GLOB_DAT          20
2010 #define R_PPC_JMP_SLOT          21
2011 #define R_PPC_RELATIVE          22
2012 #define R_PPC_LOCAL24PC         23
2013 #define R_PPC_UADDR32           24
2014 #define R_PPC_UADDR16           25
2015 #define R_PPC_REL32             26
2016 #define R_PPC_PLT32             27
2017 #define R_PPC_PLTREL32          28
2018 #define R_PPC_PLT16_LO          29
2019 #define R_PPC_PLT16_HI          30
2020 #define R_PPC_PLT16_HA          31
2021 #define R_PPC_SDAREL16          32
2022 #define R_PPC_SECTOFF           33
2023 #define R_PPC_SECTOFF_LO        34
2024 #define R_PPC_SECTOFF_HI        35
2025 #define R_PPC_SECTOFF_HA        36
2026
2027
2028 #define R_PPC_TLS               67
2029 #define R_PPC_DTPMOD32          68
2030 #define R_PPC_TPREL16           69
2031 #define R_PPC_TPREL16_LO        70
2032 #define R_PPC_TPREL16_HI        71
2033 #define R_PPC_TPREL16_HA        72
2034 #define R_PPC_TPREL32           73
2035 #define R_PPC_DTPREL16          74
2036 #define R_PPC_DTPREL16_LO       75
2037 #define R_PPC_DTPREL16_HI       76
2038 #define R_PPC_DTPREL16_HA       77
2039 #define R_PPC_DTPREL32          78
2040 #define R_PPC_GOT_TLSGD16       79
2041 #define R_PPC_GOT_TLSGD16_LO    80
2042 #define R_PPC_GOT_TLSGD16_HI    81
2043 #define R_PPC_GOT_TLSGD16_HA    82
2044 #define R_PPC_GOT_TLSLD16       83
2045 #define R_PPC_GOT_TLSLD16_LO    84
2046 #define R_PPC_GOT_TLSLD16_HI    85
2047 #define R_PPC_GOT_TLSLD16_HA    86
2048 #define R_PPC_GOT_TPREL16       87
2049 #define R_PPC_GOT_TPREL16_LO    88
2050 #define R_PPC_GOT_TPREL16_HI    89
2051 #define R_PPC_GOT_TPREL16_HA    90
2052 #define R_PPC_GOT_DTPREL16      91
2053 #define R_PPC_GOT_DTPREL16_LO   92
2054 #define R_PPC_GOT_DTPREL16_HI   93
2055 #define R_PPC_GOT_DTPREL16_HA   94
2056 #define R_PPC_TLSGD             95
2057 #define R_PPC_TLSLD             96
2058
2059
2060 #define R_PPC_EMB_NADDR32       101
2061 #define R_PPC_EMB_NADDR16       102
2062 #define R_PPC_EMB_NADDR16_LO    103
2063 #define R_PPC_EMB_NADDR16_HI    104
2064 #define R_PPC_EMB_NADDR16_HA    105
2065 #define R_PPC_EMB_SDAI16        106
2066 #define R_PPC_EMB_SDA2I16       107
2067 #define R_PPC_EMB_SDA2REL       108
2068 #define R_PPC_EMB_SDA21         109
2069 #define R_PPC_EMB_MRKREF        110
2070 #define R_PPC_EMB_RELSEC16      111
2071 #define R_PPC_EMB_RELST_LO      112
2072 #define R_PPC_EMB_RELST_HI      113
2073 #define R_PPC_EMB_RELST_HA      114
2074 #define R_PPC_EMB_BIT_FLD       115
2075 #define R_PPC_EMB_RELSDA        116
2076
2077
2078 #define R_PPC_DIAB_SDA21_LO     180
2079 #define R_PPC_DIAB_SDA21_HI     181
2080 #define R_PPC_DIAB_SDA21_HA     182
2081 #define R_PPC_DIAB_RELSDA_LO    183
2082 #define R_PPC_DIAB_RELSDA_HI    184
2083 #define R_PPC_DIAB_RELSDA_HA    185
2084
2085
2086 #define R_PPC_IRELATIVE         248
2087
2088
2089 #define R_PPC_REL16             249
2090 #define R_PPC_REL16_LO          250
2091 #define R_PPC_REL16_HI          251
2092 #define R_PPC_REL16_HA          252
2093
2094
2095
2096 #define R_PPC_TOC16             255
2097
2098
2099 #define DT_PPC_GOT              (DT_LOPROC + 0)
2100 #define DT_PPC_OPT              (DT_LOPROC + 1)
2101 #define DT_PPC_NUM              2
2102
2103 #define PPC_OPT_TLS             1
2104
2105
2106 #define R_PPC64_NONE            R_PPC_NONE
2107 #define R_PPC64_ADDR32          R_PPC_ADDR32
2108 #define R_PPC64_ADDR24          R_PPC_ADDR24
2109 #define R_PPC64_ADDR16          R_PPC_ADDR16
2110 #define R_PPC64_ADDR16_LO       R_PPC_ADDR16_LO
2111 #define R_PPC64_ADDR16_HI       R_PPC_ADDR16_HI
2112 #define R_PPC64_ADDR16_HA       R_PPC_ADDR16_HA
2113 #define R_PPC64_ADDR14          R_PPC_ADDR14
2114 #define R_PPC64_ADDR14_BRTAKEN  R_PPC_ADDR14_BRTAKEN
2115 #define R_PPC64_ADDR14_BRNTAKEN R_PPC_ADDR14_BRNTAKEN
2116 #define R_PPC64_REL24           R_PPC_REL24
2117 #define R_PPC64_REL14           R_PPC_REL14
2118 #define R_PPC64_REL14_BRTAKEN   R_PPC_REL14_BRTAKEN
2119 #define R_PPC64_REL14_BRNTAKEN  R_PPC_REL14_BRNTAKEN
2120 #define R_PPC64_GOT16           R_PPC_GOT16
2121 #define R_PPC64_GOT16_LO        R_PPC_GOT16_LO
2122 #define R_PPC64_GOT16_HI        R_PPC_GOT16_HI
2123 #define R_PPC64_GOT16_HA        R_PPC_GOT16_HA
2124
2125 #define R_PPC64_COPY            R_PPC_COPY
2126 #define R_PPC64_GLOB_DAT        R_PPC_GLOB_DAT
2127 #define R_PPC64_JMP_SLOT        R_PPC_JMP_SLOT
2128 #define R_PPC64_RELATIVE        R_PPC_RELATIVE
2129
2130 #define R_PPC64_UADDR32         R_PPC_UADDR32
2131 #define R_PPC64_UADDR16         R_PPC_UADDR16
2132 #define R_PPC64_REL32           R_PPC_REL32
2133 #define R_PPC64_PLT32           R_PPC_PLT32
2134 #define R_PPC64_PLTREL32        R_PPC_PLTREL32
2135 #define R_PPC64_PLT16_LO        R_PPC_PLT16_LO
2136 #define R_PPC64_PLT16_HI        R_PPC_PLT16_HI
2137 #define R_PPC64_PLT16_HA        R_PPC_PLT16_HA
2138
2139 #define R_PPC64_SECTOFF         R_PPC_SECTOFF
2140 #define R_PPC64_SECTOFF_LO      R_PPC_SECTOFF_LO
2141 #define R_PPC64_SECTOFF_HI      R_PPC_SECTOFF_HI
2142 #define R_PPC64_SECTOFF_HA      R_PPC_SECTOFF_HA
2143 #define R_PPC64_ADDR30          37
2144 #define R_PPC64_ADDR64          38
2145 #define R_PPC64_ADDR16_HIGHER   39
2146 #define R_PPC64_ADDR16_HIGHERA  40
2147 #define R_PPC64_ADDR16_HIGHEST  41
2148 #define R_PPC64_ADDR16_HIGHESTA 42
2149 #define R_PPC64_UADDR64         43
2150 #define R_PPC64_REL64           44
2151 #define R_PPC64_PLT64           45
2152 #define R_PPC64_PLTREL64        46
2153 #define R_PPC64_TOC16           47
2154 #define R_PPC64_TOC16_LO        48
2155 #define R_PPC64_TOC16_HI        49
2156 #define R_PPC64_TOC16_HA        50
2157 #define R_PPC64_TOC             51
2158 #define R_PPC64_PLTGOT16        52
2159 #define R_PPC64_PLTGOT16_LO     53
2160 #define R_PPC64_PLTGOT16_HI     54
2161 #define R_PPC64_PLTGOT16_HA     55
2162
2163 #define R_PPC64_ADDR16_DS       56
2164 #define R_PPC64_ADDR16_LO_DS    57
2165 #define R_PPC64_GOT16_DS        58
2166 #define R_PPC64_GOT16_LO_DS     59
2167 #define R_PPC64_PLT16_LO_DS     60
2168 #define R_PPC64_SECTOFF_DS      61
2169 #define R_PPC64_SECTOFF_LO_DS   62
2170 #define R_PPC64_TOC16_DS        63
2171 #define R_PPC64_TOC16_LO_DS     64
2172 #define R_PPC64_PLTGOT16_DS     65
2173 #define R_PPC64_PLTGOT16_LO_DS  66
2174
2175
2176 #define R_PPC64_TLS             67
2177 #define R_PPC64_DTPMOD64        68
2178 #define R_PPC64_TPREL16         69
2179 #define R_PPC64_TPREL16_LO      70
2180 #define R_PPC64_TPREL16_HI      71
2181 #define R_PPC64_TPREL16_HA      72
2182 #define R_PPC64_TPREL64         73
2183 #define R_PPC64_DTPREL16        74
2184 #define R_PPC64_DTPREL16_LO     75
2185 #define R_PPC64_DTPREL16_HI     76
2186 #define R_PPC64_DTPREL16_HA     77
2187 #define R_PPC64_DTPREL64        78
2188 #define R_PPC64_GOT_TLSGD16     79
2189 #define R_PPC64_GOT_TLSGD16_LO  80
2190 #define R_PPC64_GOT_TLSGD16_HI  81
2191 #define R_PPC64_GOT_TLSGD16_HA  82
2192 #define R_PPC64_GOT_TLSLD16     83
2193 #define R_PPC64_GOT_TLSLD16_LO  84
2194 #define R_PPC64_GOT_TLSLD16_HI  85
2195 #define R_PPC64_GOT_TLSLD16_HA  86
2196 #define R_PPC64_GOT_TPREL16_DS  87
2197 #define R_PPC64_GOT_TPREL16_LO_DS 88
2198 #define R_PPC64_GOT_TPREL16_HI  89
2199 #define R_PPC64_GOT_TPREL16_HA  90
2200 #define R_PPC64_GOT_DTPREL16_DS 91
2201 #define R_PPC64_GOT_DTPREL16_LO_DS 92
2202 #define R_PPC64_GOT_DTPREL16_HI 93
2203 #define R_PPC64_GOT_DTPREL16_HA 94
2204 #define R_PPC64_TPREL16_DS      95
2205 #define R_PPC64_TPREL16_LO_DS   96
2206 #define R_PPC64_TPREL16_HIGHER  97
2207 #define R_PPC64_TPREL16_HIGHERA 98
2208 #define R_PPC64_TPREL16_HIGHEST 99
2209 #define R_PPC64_TPREL16_HIGHESTA 100
2210 #define R_PPC64_DTPREL16_DS     101
2211 #define R_PPC64_DTPREL16_LO_DS  102
2212 #define R_PPC64_DTPREL16_HIGHER 103
2213 #define R_PPC64_DTPREL16_HIGHERA 104
2214 #define R_PPC64_DTPREL16_HIGHEST 105
2215 #define R_PPC64_DTPREL16_HIGHESTA 106
2216 #define R_PPC64_TLSGD           107
2217 #define R_PPC64_TLSLD           108
2218 #define R_PPC64_TOCSAVE         109
2219 #define R_PPC64_ADDR16_HIGH     110
2220 #define R_PPC64_ADDR16_HIGHA    111
2221 #define R_PPC64_TPREL16_HIGH    112
2222 #define R_PPC64_TPREL16_HIGHA   113
2223 #define R_PPC64_DTPREL16_HIGH   114
2224 #define R_PPC64_DTPREL16_HIGHA  115
2225
2226
2227 #define R_PPC64_JMP_IREL        247
2228 #define R_PPC64_IRELATIVE       248
2229 #define R_PPC64_REL16           249
2230 #define R_PPC64_REL16_LO        250
2231 #define R_PPC64_REL16_HI        251
2232 #define R_PPC64_REL16_HA        252
2233
2234 #define EF_PPC64_ABI    3
2235
2236 #define DT_PPC64_GLINK  (DT_LOPROC + 0)
2237 #define DT_PPC64_OPD    (DT_LOPROC + 1)
2238 #define DT_PPC64_OPDSZ  (DT_LOPROC + 2)
2239 #define DT_PPC64_OPT    (DT_LOPROC + 3)
2240 #define DT_PPC64_NUM    4
2241
2242 #define PPC64_OPT_TLS           1
2243 #define PPC64_OPT_MULTI_TOC     2
2244 #define PPC64_OPT_LOCALENTRY    4
2245
2246 #define STO_PPC64_LOCAL_BIT     5
2247 #define STO_PPC64_LOCAL_MASK    0xe0
2248 #define PPC64_LOCAL_ENTRY_OFFSET(x) (1 << (((x)&0xe0)>>5) & 0xfc)
2249
2250
2251 #define EF_ARM_RELEXEC          0x01
2252 #define EF_ARM_HASENTRY         0x02
2253 #define EF_ARM_INTERWORK        0x04
2254 #define EF_ARM_APCS_26          0x08
2255 #define EF_ARM_APCS_FLOAT       0x10
2256 #define EF_ARM_PIC              0x20
2257 #define EF_ARM_ALIGN8           0x40
2258 #define EF_ARM_NEW_ABI          0x80
2259 #define EF_ARM_OLD_ABI          0x100
2260 #define EF_ARM_SOFT_FLOAT       0x200
2261 #define EF_ARM_VFP_FLOAT        0x400
2262 #define EF_ARM_MAVERICK_FLOAT   0x800
2263
2264 #define EF_ARM_ABI_FLOAT_SOFT   0x200
2265 #define EF_ARM_ABI_FLOAT_HARD   0x400
2266
2267
2268 #define EF_ARM_SYMSARESORTED    0x04
2269 #define EF_ARM_DYNSYMSUSESEGIDX 0x08
2270 #define EF_ARM_MAPSYMSFIRST     0x10
2271 #define EF_ARM_EABIMASK         0XFF000000
2272
2273
2274 #define EF_ARM_BE8          0x00800000
2275 #define EF_ARM_LE8          0x00400000
2276
2277 #define EF_ARM_EABI_VERSION(flags)      ((flags) & EF_ARM_EABIMASK)
2278 #define EF_ARM_EABI_UNKNOWN     0x00000000
2279 #define EF_ARM_EABI_VER1        0x01000000
2280 #define EF_ARM_EABI_VER2        0x02000000
2281 #define EF_ARM_EABI_VER3        0x03000000
2282 #define EF_ARM_EABI_VER4        0x04000000
2283 #define EF_ARM_EABI_VER5        0x05000000
2284
2285
2286 #define STT_ARM_TFUNC           STT_LOPROC
2287 #define STT_ARM_16BIT           STT_HIPROC
2288
2289
2290 #define SHF_ARM_ENTRYSECT       0x10000000
2291 #define SHF_ARM_COMDEF          0x80000000
2292
2293
2294
2295 #define PF_ARM_SB               0x10000000
2296
2297 #define PF_ARM_PI               0x20000000
2298 #define PF_ARM_ABS              0x40000000
2299
2300
2301 #define PT_ARM_EXIDX            (PT_LOPROC + 1)
2302
2303
2304 #define SHT_ARM_EXIDX           (SHT_LOPROC + 1)
2305 #define SHT_ARM_PREEMPTMAP      (SHT_LOPROC + 2)
2306 #define SHT_ARM_ATTRIBUTES      (SHT_LOPROC + 3)
2307
2308 #define R_AARCH64_NONE            0
2309 #define R_AARCH64_P32_ABS32     1
2310 #define R_AARCH64_P32_COPY      180
2311 #define R_AARCH64_P32_GLOB_DAT  181
2312 #define R_AARCH64_P32_JUMP_SLOT 182
2313 #define R_AARCH64_P32_RELATIVE  183
2314 #define R_AARCH64_P32_TLS_DTPMOD 184
2315 #define R_AARCH64_P32_TLS_DTPREL 185
2316 #define R_AARCH64_P32_TLS_TPREL 186
2317 #define R_AARCH64_P32_TLSDESC   187
2318 #define R_AARCH64_P32_IRELATIVE 188
2319 #define R_AARCH64_ABS64         257
2320 #define R_AARCH64_ABS32         258
2321 #define R_AARCH64_ABS16         259
2322 #define R_AARCH64_PREL64        260
2323 #define R_AARCH64_PREL32        261
2324 #define R_AARCH64_PREL16        262
2325 #define R_AARCH64_MOVW_UABS_G0  263
2326 #define R_AARCH64_MOVW_UABS_G0_NC 264
2327 #define R_AARCH64_MOVW_UABS_G1  265
2328 #define R_AARCH64_MOVW_UABS_G1_NC 266
2329 #define R_AARCH64_MOVW_UABS_G2  267
2330 #define R_AARCH64_MOVW_UABS_G2_NC 268
2331 #define R_AARCH64_MOVW_UABS_G3  269
2332 #define R_AARCH64_MOVW_SABS_G0  270
2333 #define R_AARCH64_MOVW_SABS_G1  271
2334 #define R_AARCH64_MOVW_SABS_G2  272
2335 #define R_AARCH64_LD_PREL_LO19  273
2336 #define R_AARCH64_ADR_PREL_LO21 274
2337 #define R_AARCH64_ADR_PREL_PG_HI21 275
2338 #define R_AARCH64_ADR_PREL_PG_HI21_NC 276
2339 #define R_AARCH64_ADD_ABS_LO12_NC 277
2340 #define R_AARCH64_LDST8_ABS_LO12_NC 278
2341 #define R_AARCH64_TSTBR14       279
2342 #define R_AARCH64_CONDBR19      280
2343 #define R_AARCH64_JUMP26        282
2344 #define R_AARCH64_CALL26        283
2345 #define R_AARCH64_LDST16_ABS_LO12_NC 284
2346 #define R_AARCH64_LDST32_ABS_LO12_NC 285
2347 #define R_AARCH64_LDST64_ABS_LO12_NC 286
2348 #define R_AARCH64_MOVW_PREL_G0  287
2349 #define R_AARCH64_MOVW_PREL_G0_NC 288
2350 #define R_AARCH64_MOVW_PREL_G1  289
2351 #define R_AARCH64_MOVW_PREL_G1_NC 290
2352 #define R_AARCH64_MOVW_PREL_G2  291
2353 #define R_AARCH64_MOVW_PREL_G2_NC 292
2354 #define R_AARCH64_MOVW_PREL_G3  293
2355 #define R_AARCH64_LDST128_ABS_LO12_NC 299
2356 #define R_AARCH64_MOVW_GOTOFF_G0 300
2357 #define R_AARCH64_MOVW_GOTOFF_G0_NC 301
2358 #define R_AARCH64_MOVW_GOTOFF_G1 302
2359 #define R_AARCH64_MOVW_GOTOFF_G1_NC 303
2360 #define R_AARCH64_MOVW_GOTOFF_G2 304
2361 #define R_AARCH64_MOVW_GOTOFF_G2_NC 305
2362 #define R_AARCH64_MOVW_GOTOFF_G3 306
2363 #define R_AARCH64_GOTREL64      307
2364 #define R_AARCH64_GOTREL32      308
2365 #define R_AARCH64_GOT_LD_PREL19 309
2366 #define R_AARCH64_LD64_GOTOFF_LO15 310
2367 #define R_AARCH64_ADR_GOT_PAGE  311
2368 #define R_AARCH64_LD64_GOT_LO12_NC 312
2369 #define R_AARCH64_LD64_GOTPAGE_LO15 313
2370 #define R_AARCH64_TLSGD_ADR_PREL21 512
2371 #define R_AARCH64_TLSGD_ADR_PAGE21 513
2372 #define R_AARCH64_TLSGD_ADD_LO12_NC 514
2373 #define R_AARCH64_TLSGD_MOVW_G1 515
2374 #define R_AARCH64_TLSGD_MOVW_G0_NC 516
2375 #define R_AARCH64_TLSLD_ADR_PREL21 517
2376 #define R_AARCH64_TLSLD_ADR_PAGE21 518
2377 #define R_AARCH64_TLSLD_ADD_LO12_NC 519
2378 #define R_AARCH64_TLSLD_MOVW_G1 520
2379 #define R_AARCH64_TLSLD_MOVW_G0_NC 521
2380 #define R_AARCH64_TLSLD_LD_PREL19 522
2381 #define R_AARCH64_TLSLD_MOVW_DTPREL_G2 523
2382 #define R_AARCH64_TLSLD_MOVW_DTPREL_G1 524
2383 #define R_AARCH64_TLSLD_MOVW_DTPREL_G1_NC 525
2384 #define R_AARCH64_TLSLD_MOVW_DTPREL_G0 526
2385 #define R_AARCH64_TLSLD_MOVW_DTPREL_G0_NC 527
2386 #define R_AARCH64_TLSLD_ADD_DTPREL_HI12 528
2387 #define R_AARCH64_TLSLD_ADD_DTPREL_LO12 529
2388 #define R_AARCH64_TLSLD_ADD_DTPREL_LO12_NC 530
2389 #define R_AARCH64_TLSLD_LDST8_DTPREL_LO12 531
2390 #define R_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC 532
2391 #define R_AARCH64_TLSLD_LDST16_DTPREL_LO12 533
2392 #define R_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC 534
2393 #define R_AARCH64_TLSLD_LDST32_DTPREL_LO12 535
2394 #define R_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC 536
2395 #define R_AARCH64_TLSLD_LDST64_DTPREL_LO12 537
2396 #define R_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC 538
2397 #define R_AARCH64_TLSIE_MOVW_GOTTPREL_G1 539
2398 #define R_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC 540
2399 #define R_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21 541
2400 #define R_AARCH64_TLSIE_LD64_GOTTPREL_LO12_NC 542
2401 #define R_AARCH64_TLSIE_LD_GOTTPREL_PREL19 543
2402 #define R_AARCH64_TLSLE_MOVW_TPREL_G2 544
2403 #define R_AARCH64_TLSLE_MOVW_TPREL_G1 545
2404 #define R_AARCH64_TLSLE_MOVW_TPREL_G1_NC 546
2405 #define R_AARCH64_TLSLE_MOVW_TPREL_G0 547
2406 #define R_AARCH64_TLSLE_MOVW_TPREL_G0_NC 548
2407 #define R_AARCH64_TLSLE_ADD_TPREL_HI12 549
2408 #define R_AARCH64_TLSLE_ADD_TPREL_LO12 550
2409 #define R_AARCH64_TLSLE_ADD_TPREL_LO12_NC 551
2410 #define R_AARCH64_TLSLE_LDST8_TPREL_LO12 552
2411 #define R_AARCH64_TLSLE_LDST8_TPREL_LO12_NC 553
2412 #define R_AARCH64_TLSLE_LDST16_TPREL_LO12 554
2413 #define R_AARCH64_TLSLE_LDST16_TPREL_LO12_NC 555
2414 #define R_AARCH64_TLSLE_LDST32_TPREL_LO12 556
2415 #define R_AARCH64_TLSLE_LDST32_TPREL_LO12_NC 557
2416 #define R_AARCH64_TLSLE_LDST64_TPREL_LO12 558
2417 #define R_AARCH64_TLSLE_LDST64_TPREL_LO12_NC 559
2418 #define R_AARCH64_TLSDESC_LD_PREL19 560
2419 #define R_AARCH64_TLSDESC_ADR_PREL21 561
2420 #define R_AARCH64_TLSDESC_ADR_PAGE21 562
2421 #define R_AARCH64_TLSDESC_LD64_LO12 563
2422 #define R_AARCH64_TLSDESC_ADD_LO12 564
2423 #define R_AARCH64_TLSDESC_OFF_G1 565
2424 #define R_AARCH64_TLSDESC_OFF_G0_NC 566
2425 #define R_AARCH64_TLSDESC_LDR   567
2426 #define R_AARCH64_TLSDESC_ADD   568
2427 #define R_AARCH64_TLSDESC_CALL  569
2428 #define R_AARCH64_TLSLE_LDST128_TPREL_LO12 570
2429 #define R_AARCH64_TLSLE_LDST128_TPREL_LO12_NC 571
2430 #define R_AARCH64_TLSLD_LDST128_DTPREL_LO12 572
2431 #define R_AARCH64_TLSLD_LDST128_DTPREL_LO12_NC 573
2432 #define R_AARCH64_COPY         1024
2433 #define R_AARCH64_GLOB_DAT     1025
2434 #define R_AARCH64_JUMP_SLOT    1026
2435 #define R_AARCH64_RELATIVE     1027
2436 #define R_AARCH64_TLS_DTPMOD   1028
2437 #define R_AARCH64_TLS_DTPMOD64 1028
2438 #define R_AARCH64_TLS_DTPREL   1029
2439 #define R_AARCH64_TLS_DTPREL64 1029
2440 #define R_AARCH64_TLS_TPREL    1030
2441 #define R_AARCH64_TLS_TPREL64  1030
2442 #define R_AARCH64_TLSDESC      1031
2443
2444
2445 #define R_ARM_NONE              0
2446 #define R_ARM_PC24              1
2447 #define R_ARM_ABS32             2
2448 #define R_ARM_REL32             3
2449 #define R_ARM_PC13              4
2450 #define R_ARM_ABS16             5
2451 #define R_ARM_ABS12             6
2452 #define R_ARM_THM_ABS5          7
2453 #define R_ARM_ABS8              8
2454 #define R_ARM_SBREL32           9
2455 #define R_ARM_THM_PC22          10
2456 #define R_ARM_THM_PC8           11
2457 #define R_ARM_AMP_VCALL9        12
2458 #define R_ARM_TLS_DESC          13
2459 #define R_ARM_THM_SWI8          14
2460 #define R_ARM_XPC25             15
2461 #define R_ARM_THM_XPC22         16
2462 #define R_ARM_TLS_DTPMOD32      17
2463 #define R_ARM_TLS_DTPOFF32      18
2464 #define R_ARM_TLS_TPOFF32       19
2465 #define R_ARM_COPY              20
2466 #define R_ARM_GLOB_DAT          21
2467 #define R_ARM_JUMP_SLOT         22
2468 #define R_ARM_RELATIVE          23
2469 #define R_ARM_GOTOFF            24
2470 #define R_ARM_GOTPC             25
2471 #define R_ARM_GOT32             26
2472 #define R_ARM_PLT32             27
2473 #define R_ARM_CALL              28
2474 #define R_ARM_JUMP24            29
2475 #define R_ARM_THM_JUMP24        30
2476 #define R_ARM_BASE_ABS          31
2477 #define R_ARM_ALU_PCREL_7_0     32
2478 #define R_ARM_ALU_PCREL_15_8    33
2479 #define R_ARM_ALU_PCREL_23_15   34
2480 #define R_ARM_LDR_SBREL_11_0    35
2481 #define R_ARM_ALU_SBREL_19_12   36
2482 #define R_ARM_ALU_SBREL_27_20   37
2483 #define R_ARM_TARGET1           38
2484 #define R_ARM_SBREL31           39
2485 #define R_ARM_V4BX              40
2486 #define R_ARM_TARGET2           41
2487 #define R_ARM_PREL31            42
2488 #define R_ARM_MOVW_ABS_NC       43
2489 #define R_ARM_MOVT_ABS          44
2490 #define R_ARM_MOVW_PREL_NC      45
2491 #define R_ARM_MOVT_PREL         46
2492 #define R_ARM_THM_MOVW_ABS_NC   47
2493 #define R_ARM_THM_MOVT_ABS      48
2494 #define R_ARM_THM_MOVW_PREL_NC  49
2495 #define R_ARM_THM_MOVT_PREL     50
2496 #define R_ARM_THM_JUMP19        51
2497 #define R_ARM_THM_JUMP6         52
2498 #define R_ARM_THM_ALU_PREL_11_0 53
2499 #define R_ARM_THM_PC12          54
2500 #define R_ARM_ABS32_NOI         55
2501 #define R_ARM_REL32_NOI         56
2502 #define R_ARM_ALU_PC_G0_NC      57
2503 #define R_ARM_ALU_PC_G0         58
2504 #define R_ARM_ALU_PC_G1_NC      59
2505 #define R_ARM_ALU_PC_G1         60
2506 #define R_ARM_ALU_PC_G2         61
2507 #define R_ARM_LDR_PC_G1         62
2508 #define R_ARM_LDR_PC_G2         63
2509 #define R_ARM_LDRS_PC_G0        64
2510 #define R_ARM_LDRS_PC_G1        65
2511 #define R_ARM_LDRS_PC_G2        66
2512 #define R_ARM_LDC_PC_G0         67
2513 #define R_ARM_LDC_PC_G1         68
2514 #define R_ARM_LDC_PC_G2         69
2515 #define R_ARM_ALU_SB_G0_NC      70
2516 #define R_ARM_ALU_SB_G0         71
2517 #define R_ARM_ALU_SB_G1_NC      72
2518 #define R_ARM_ALU_SB_G1         73
2519 #define R_ARM_ALU_SB_G2         74
2520 #define R_ARM_LDR_SB_G0         75
2521 #define R_ARM_LDR_SB_G1         76
2522 #define R_ARM_LDR_SB_G2         77
2523 #define R_ARM_LDRS_SB_G0        78
2524 #define R_ARM_LDRS_SB_G1        79
2525 #define R_ARM_LDRS_SB_G2        80
2526 #define R_ARM_LDC_SB_G0         81
2527 #define R_ARM_LDC_SB_G1         82
2528 #define R_ARM_LDC_SB_G2         83
2529 #define R_ARM_MOVW_BREL_NC      84
2530 #define R_ARM_MOVT_BREL         85
2531 #define R_ARM_MOVW_BREL         86
2532 #define R_ARM_THM_MOVW_BREL_NC  87
2533 #define R_ARM_THM_MOVT_BREL     88
2534 #define R_ARM_THM_MOVW_BREL     89
2535 #define R_ARM_TLS_GOTDESC       90
2536 #define R_ARM_TLS_CALL          91
2537 #define R_ARM_TLS_DESCSEQ       92
2538 #define R_ARM_THM_TLS_CALL      93
2539 #define R_ARM_PLT32_ABS         94
2540 #define R_ARM_GOT_ABS           95
2541 #define R_ARM_GOT_PREL          96
2542 #define R_ARM_GOT_BREL12        97
2543 #define R_ARM_GOTOFF12          98
2544 #define R_ARM_GOTRELAX          99
2545 #define R_ARM_GNU_VTENTRY       100
2546 #define R_ARM_GNU_VTINHERIT     101
2547 #define R_ARM_THM_PC11          102
2548 #define R_ARM_THM_PC9           103
2549 #define R_ARM_TLS_GD32          104
2550
2551 #define R_ARM_TLS_LDM32         105
2552
2553 #define R_ARM_TLS_LDO32         106
2554
2555 #define R_ARM_TLS_IE32          107
2556
2557 #define R_ARM_TLS_LE32          108
2558 #define R_ARM_TLS_LDO12         109
2559 #define R_ARM_TLS_LE12          110
2560 #define R_ARM_TLS_IE12GP        111
2561 #define R_ARM_ME_TOO            128
2562 #define R_ARM_THM_TLS_DESCSEQ   129
2563 #define R_ARM_THM_TLS_DESCSEQ16 129
2564 #define R_ARM_THM_TLS_DESCSEQ32 130
2565 #define R_ARM_THM_GOT_BREL12    131
2566 #define R_ARM_IRELATIVE         160
2567 #define R_ARM_RXPC25            249
2568 #define R_ARM_RSBREL32          250
2569 #define R_ARM_THM_RPC22         251
2570 #define R_ARM_RREL32            252
2571 #define R_ARM_RABS22            253
2572 #define R_ARM_RPC24             254
2573 #define R_ARM_RBASE             255
2574
2575 #define R_ARM_NUM               256
2576
2577
2578
2579
2580 #define EF_IA_64_MASKOS         0x0000000f
2581 #define EF_IA_64_ABI64          0x00000010
2582 #define EF_IA_64_ARCH           0xff000000
2583
2584
2585 #define PT_IA_64_ARCHEXT        (PT_LOPROC + 0)
2586 #define PT_IA_64_UNWIND         (PT_LOPROC + 1)
2587 #define PT_IA_64_HP_OPT_ANOT    (PT_LOOS + 0x12)
2588 #define PT_IA_64_HP_HSL_ANOT    (PT_LOOS + 0x13)
2589 #define PT_IA_64_HP_STACK       (PT_LOOS + 0x14)
2590
2591
2592 #define PF_IA_64_NORECOV        0x80000000
2593
2594
2595 #define SHT_IA_64_EXT           (SHT_LOPROC + 0)
2596 #define SHT_IA_64_UNWIND        (SHT_LOPROC + 1)
2597
2598
2599 #define SHF_IA_64_SHORT         0x10000000
2600 #define SHF_IA_64_NORECOV       0x20000000
2601
2602
2603 #define DT_IA_64_PLT_RESERVE    (DT_LOPROC + 0)
2604 #define DT_IA_64_NUM            1
2605
2606
2607 #define R_IA64_NONE             0x00
2608 #define R_IA64_IMM14            0x21
2609 #define R_IA64_IMM22            0x22
2610 #define R_IA64_IMM64            0x23
2611 #define R_IA64_DIR32MSB         0x24
2612 #define R_IA64_DIR32LSB         0x25
2613 #define R_IA64_DIR64MSB         0x26
2614 #define R_IA64_DIR64LSB         0x27
2615 #define R_IA64_GPREL22          0x2a
2616 #define R_IA64_GPREL64I         0x2b
2617 #define R_IA64_GPREL32MSB       0x2c
2618 #define R_IA64_GPREL32LSB       0x2d
2619 #define R_IA64_GPREL64MSB       0x2e
2620 #define R_IA64_GPREL64LSB       0x2f
2621 #define R_IA64_LTOFF22          0x32
2622 #define R_IA64_LTOFF64I         0x33
2623 #define R_IA64_PLTOFF22         0x3a
2624 #define R_IA64_PLTOFF64I        0x3b
2625 #define R_IA64_PLTOFF64MSB      0x3e
2626 #define R_IA64_PLTOFF64LSB      0x3f
2627 #define R_IA64_FPTR64I          0x43
2628 #define R_IA64_FPTR32MSB        0x44
2629 #define R_IA64_FPTR32LSB        0x45
2630 #define R_IA64_FPTR64MSB        0x46
2631 #define R_IA64_FPTR64LSB        0x47
2632 #define R_IA64_PCREL60B         0x48
2633 #define R_IA64_PCREL21B         0x49
2634 #define R_IA64_PCREL21M         0x4a
2635 #define R_IA64_PCREL21F         0x4b
2636 #define R_IA64_PCREL32MSB       0x4c
2637 #define R_IA64_PCREL32LSB       0x4d
2638 #define R_IA64_PCREL64MSB       0x4e
2639 #define R_IA64_PCREL64LSB       0x4f
2640 #define R_IA64_LTOFF_FPTR22     0x52
2641 #define R_IA64_LTOFF_FPTR64I    0x53
2642 #define R_IA64_LTOFF_FPTR32MSB  0x54
2643 #define R_IA64_LTOFF_FPTR32LSB  0x55
2644 #define R_IA64_LTOFF_FPTR64MSB  0x56
2645 #define R_IA64_LTOFF_FPTR64LSB  0x57
2646 #define R_IA64_SEGREL32MSB      0x5c
2647 #define R_IA64_SEGREL32LSB      0x5d
2648 #define R_IA64_SEGREL64MSB      0x5e
2649 #define R_IA64_SEGREL64LSB      0x5f
2650 #define R_IA64_SECREL32MSB      0x64
2651 #define R_IA64_SECREL32LSB      0x65
2652 #define R_IA64_SECREL64MSB      0x66
2653 #define R_IA64_SECREL64LSB      0x67
2654 #define R_IA64_REL32MSB         0x6c
2655 #define R_IA64_REL32LSB         0x6d
2656 #define R_IA64_REL64MSB         0x6e
2657 #define R_IA64_REL64LSB         0x6f
2658 #define R_IA64_LTV32MSB         0x74
2659 #define R_IA64_LTV32LSB         0x75
2660 #define R_IA64_LTV64MSB         0x76
2661 #define R_IA64_LTV64LSB         0x77
2662 #define R_IA64_PCREL21BI        0x79
2663 #define R_IA64_PCREL22          0x7a
2664 #define R_IA64_PCREL64I         0x7b
2665 #define R_IA64_IPLTMSB          0x80
2666 #define R_IA64_IPLTLSB          0x81
2667 #define R_IA64_COPY             0x84
2668 #define R_IA64_SUB              0x85
2669 #define R_IA64_LTOFF22X         0x86
2670 #define R_IA64_LDXMOV           0x87
2671 #define R_IA64_TPREL14          0x91
2672 #define R_IA64_TPREL22          0x92
2673 #define R_IA64_TPREL64I         0x93
2674 #define R_IA64_TPREL64MSB       0x96
2675 #define R_IA64_TPREL64LSB       0x97
2676 #define R_IA64_LTOFF_TPREL22    0x9a
2677 #define R_IA64_DTPMOD64MSB      0xa6
2678 #define R_IA64_DTPMOD64LSB      0xa7
2679 #define R_IA64_LTOFF_DTPMOD22   0xaa
2680 #define R_IA64_DTPREL14         0xb1
2681 #define R_IA64_DTPREL22         0xb2
2682 #define R_IA64_DTPREL64I        0xb3
2683 #define R_IA64_DTPREL32MSB      0xb4
2684 #define R_IA64_DTPREL32LSB      0xb5
2685 #define R_IA64_DTPREL64MSB      0xb6
2686 #define R_IA64_DTPREL64LSB      0xb7
2687 #define R_IA64_LTOFF_DTPREL22   0xba
2688
2689
2690 #define EF_SH_MACH_MASK         0x1f
2691 #define EF_SH_UNKNOWN           0x0
2692 #define EF_SH1                  0x1
2693 #define EF_SH2                  0x2
2694 #define EF_SH3                  0x3
2695 #define EF_SH_DSP               0x4
2696 #define EF_SH3_DSP              0x5
2697 #define EF_SH4AL_DSP            0x6
2698 #define EF_SH3E                 0x8
2699 #define EF_SH4                  0x9
2700 #define EF_SH2E                 0xb
2701 #define EF_SH4A                 0xc
2702 #define EF_SH2A                 0xd
2703 #define EF_SH4_NOFPU            0x10
2704 #define EF_SH4A_NOFPU           0x11
2705 #define EF_SH4_NOMMU_NOFPU      0x12
2706 #define EF_SH2A_NOFPU           0x13
2707 #define EF_SH3_NOMMU            0x14
2708 #define EF_SH2A_SH4_NOFPU       0x15
2709 #define EF_SH2A_SH3_NOFPU       0x16
2710 #define EF_SH2A_SH4             0x17
2711 #define EF_SH2A_SH3E            0x18
2712
2713 #define R_SH_NONE               0
2714 #define R_SH_DIR32              1
2715 #define R_SH_REL32              2
2716 #define R_SH_DIR8WPN            3
2717 #define R_SH_IND12W             4
2718 #define R_SH_DIR8WPL            5
2719 #define R_SH_DIR8WPZ            6
2720 #define R_SH_DIR8BP             7
2721 #define R_SH_DIR8W              8
2722 #define R_SH_DIR8L              9
2723 #define R_SH_SWITCH16           25
2724 #define R_SH_SWITCH32           26
2725 #define R_SH_USES               27
2726 #define R_SH_COUNT              28
2727 #define R_SH_ALIGN              29
2728 #define R_SH_CODE               30
2729 #define R_SH_DATA               31
2730 #define R_SH_LABEL              32
2731 #define R_SH_SWITCH8            33
2732 #define R_SH_GNU_VTINHERIT      34
2733 #define R_SH_GNU_VTENTRY        35
2734 #define R_SH_TLS_GD_32          144
2735 #define R_SH_TLS_LD_32          145
2736 #define R_SH_TLS_LDO_32         146
2737 #define R_SH_TLS_IE_32          147
2738 #define R_SH_TLS_LE_32          148
2739 #define R_SH_TLS_DTPMOD32       149
2740 #define R_SH_TLS_DTPOFF32       150
2741 #define R_SH_TLS_TPOFF32        151
2742 #define R_SH_GOT32              160
2743 #define R_SH_PLT32              161
2744 #define R_SH_COPY               162
2745 #define R_SH_GLOB_DAT           163
2746 #define R_SH_JMP_SLOT           164
2747 #define R_SH_RELATIVE           165
2748 #define R_SH_GOTOFF             166
2749 #define R_SH_GOTPC              167
2750 #define R_SH_GOT20              201
2751 #define R_SH_GOTOFF20           202
2752 #define R_SH_GOTFUNCDESC        203
2753 #define R_SH_GOTFUNCDEST20      204
2754 #define R_SH_GOTOFFFUNCDESC     205
2755 #define R_SH_GOTOFFFUNCDEST20   206
2756 #define R_SH_FUNCDESC           207
2757 #define R_SH_FUNCDESC_VALUE     208
2758
2759 #define R_SH_NUM                256
2760
2761
2762
2763 #define R_390_NONE              0
2764 #define R_390_8                 1
2765 #define R_390_12                2
2766 #define R_390_16                3
2767 #define R_390_32                4
2768 #define R_390_PC32              5
2769 #define R_390_GOT12             6
2770 #define R_390_GOT32             7
2771 #define R_390_PLT32             8
2772 #define R_390_COPY              9
2773 #define R_390_GLOB_DAT          10
2774 #define R_390_JMP_SLOT          11
2775 #define R_390_RELATIVE          12
2776 #define R_390_GOTOFF32          13
2777 #define R_390_GOTPC             14
2778 #define R_390_GOT16             15
2779 #define R_390_PC16              16
2780 #define R_390_PC16DBL           17
2781 #define R_390_PLT16DBL          18
2782 #define R_390_PC32DBL           19
2783 #define R_390_PLT32DBL          20
2784 #define R_390_GOTPCDBL          21
2785 #define R_390_64                22
2786 #define R_390_PC64              23
2787 #define R_390_GOT64             24
2788 #define R_390_PLT64             25
2789 #define R_390_GOTENT            26
2790 #define R_390_GOTOFF16          27
2791 #define R_390_GOTOFF64          28
2792 #define R_390_GOTPLT12          29
2793 #define R_390_GOTPLT16          30
2794 #define R_390_GOTPLT32          31
2795 #define R_390_GOTPLT64          32
2796 #define R_390_GOTPLTENT         33
2797 #define R_390_PLTOFF16          34
2798 #define R_390_PLTOFF32          35
2799 #define R_390_PLTOFF64          36
2800 #define R_390_TLS_LOAD          37
2801 #define R_390_TLS_GDCALL        38
2802
2803 #define R_390_TLS_LDCALL        39
2804
2805 #define R_390_TLS_GD32          40
2806
2807 #define R_390_TLS_GD64          41
2808
2809 #define R_390_TLS_GOTIE12       42
2810
2811 #define R_390_TLS_GOTIE32       43
2812
2813 #define R_390_TLS_GOTIE64       44
2814
2815 #define R_390_TLS_LDM32         45
2816
2817 #define R_390_TLS_LDM64         46
2818
2819 #define R_390_TLS_IE32          47
2820
2821 #define R_390_TLS_IE64          48
2822
2823 #define R_390_TLS_IEENT         49
2824
2825 #define R_390_TLS_LE32          50
2826
2827 #define R_390_TLS_LE64          51
2828
2829 #define R_390_TLS_LDO32         52
2830
2831 #define R_390_TLS_LDO64         53
2832
2833 #define R_390_TLS_DTPMOD        54
2834 #define R_390_TLS_DTPOFF        55
2835 #define R_390_TLS_TPOFF         56
2836
2837 #define R_390_20                57
2838 #define R_390_GOT20             58
2839 #define R_390_GOTPLT20          59
2840 #define R_390_TLS_GOTIE20       60
2841
2842
2843 #define R_390_NUM               61
2844
2845
2846
2847 #define R_CRIS_NONE             0
2848 #define R_CRIS_8                1
2849 #define R_CRIS_16               2
2850 #define R_CRIS_32               3
2851 #define R_CRIS_8_PCREL          4
2852 #define R_CRIS_16_PCREL         5
2853 #define R_CRIS_32_PCREL         6
2854 #define R_CRIS_GNU_VTINHERIT    7
2855 #define R_CRIS_GNU_VTENTRY      8
2856 #define R_CRIS_COPY             9
2857 #define R_CRIS_GLOB_DAT         10
2858 #define R_CRIS_JUMP_SLOT        11
2859 #define R_CRIS_RELATIVE         12
2860 #define R_CRIS_16_GOT           13
2861 #define R_CRIS_32_GOT           14
2862 #define R_CRIS_16_GOTPLT        15
2863 #define R_CRIS_32_GOTPLT        16
2864 #define R_CRIS_32_GOTREL        17
2865 #define R_CRIS_32_PLT_GOTREL    18
2866 #define R_CRIS_32_PLT_PCREL     19
2867
2868 #define R_CRIS_NUM              20
2869
2870
2871
2872 #define R_X86_64_NONE           0
2873 #define R_X86_64_64             1
2874 #define R_X86_64_PC32           2
2875 #define R_X86_64_GOT32          3
2876 #define R_X86_64_PLT32          4
2877 #define R_X86_64_COPY           5
2878 #define R_X86_64_GLOB_DAT       6
2879 #define R_X86_64_JUMP_SLOT      7
2880 #define R_X86_64_RELATIVE       8
2881 #define R_X86_64_GOTPCREL       9
2882
2883 #define R_X86_64_32             10
2884 #define R_X86_64_32S            11
2885 #define R_X86_64_16             12
2886 #define R_X86_64_PC16           13
2887 #define R_X86_64_8              14
2888 #define R_X86_64_PC8            15
2889 #define R_X86_64_DTPMOD64       16
2890 #define R_X86_64_DTPOFF64       17
2891 #define R_X86_64_TPOFF64        18
2892 #define R_X86_64_TLSGD          19
2893
2894 #define R_X86_64_TLSLD          20
2895
2896 #define R_X86_64_DTPOFF32       21
2897 #define R_X86_64_GOTTPOFF       22
2898
2899 #define R_X86_64_TPOFF32        23
2900 #define R_X86_64_PC64           24
2901 #define R_X86_64_GOTOFF64       25
2902 #define R_X86_64_GOTPC32        26
2903 #define R_X86_64_GOT64          27
2904 #define R_X86_64_GOTPCREL64     28
2905 #define R_X86_64_GOTPC64        29
2906 #define R_X86_64_GOTPLT64       30
2907 #define R_X86_64_PLTOFF64       31
2908 #define R_X86_64_SIZE32         32
2909 #define R_X86_64_SIZE64         33
2910
2911 #define R_X86_64_GOTPC32_TLSDESC 34
2912 #define R_X86_64_TLSDESC_CALL   35
2913
2914 #define R_X86_64_TLSDESC        36
2915 #define R_X86_64_IRELATIVE      37
2916 #define R_X86_64_RELATIVE64     38
2917 #define R_X86_64_GOTPCRELX      41
2918 #define R_X86_64_REX_GOTPCRELX  42
2919 #define R_X86_64_NUM            43
2920
2921
2922
2923 #define R_MN10300_NONE          0
2924 #define R_MN10300_32            1
2925 #define R_MN10300_16            2
2926 #define R_MN10300_8             3
2927 #define R_MN10300_PCREL32       4
2928 #define R_MN10300_PCREL16       5
2929 #define R_MN10300_PCREL8        6
2930 #define R_MN10300_GNU_VTINHERIT 7
2931 #define R_MN10300_GNU_VTENTRY   8
2932 #define R_MN10300_24            9
2933 #define R_MN10300_GOTPC32       10
2934 #define R_MN10300_GOTPC16       11
2935 #define R_MN10300_GOTOFF32      12
2936 #define R_MN10300_GOTOFF24      13
2937 #define R_MN10300_GOTOFF16      14
2938 #define R_MN10300_PLT32         15
2939 #define R_MN10300_PLT16         16
2940 #define R_MN10300_GOT32         17
2941 #define R_MN10300_GOT24         18
2942 #define R_MN10300_GOT16         19
2943 #define R_MN10300_COPY          20
2944 #define R_MN10300_GLOB_DAT      21
2945 #define R_MN10300_JMP_SLOT      22
2946 #define R_MN10300_RELATIVE      23
2947
2948 #define R_MN10300_NUM           24
2949
2950
2951
2952 #define R_M32R_NONE             0
2953 #define R_M32R_16               1
2954 #define R_M32R_32               2
2955 #define R_M32R_24               3
2956 #define R_M32R_10_PCREL         4
2957 #define R_M32R_18_PCREL         5
2958 #define R_M32R_26_PCREL         6
2959 #define R_M32R_HI16_ULO         7
2960 #define R_M32R_HI16_SLO         8
2961 #define R_M32R_LO16             9
2962 #define R_M32R_SDA16            10
2963 #define R_M32R_GNU_VTINHERIT    11
2964 #define R_M32R_GNU_VTENTRY      12
2965
2966 #define R_M32R_16_RELA          33
2967 #define R_M32R_32_RELA          34
2968 #define R_M32R_24_RELA          35
2969 #define R_M32R_10_PCREL_RELA    36
2970 #define R_M32R_18_PCREL_RELA    37
2971 #define R_M32R_26_PCREL_RELA    38
2972 #define R_M32R_HI16_ULO_RELA    39
2973 #define R_M32R_HI16_SLO_RELA    40
2974 #define R_M32R_LO16_RELA        41
2975 #define R_M32R_SDA16_RELA       42
2976 #define R_M32R_RELA_GNU_VTINHERIT       43
2977 #define R_M32R_RELA_GNU_VTENTRY 44
2978 #define R_M32R_REL32            45
2979
2980 #define R_M32R_GOT24            48
2981 #define R_M32R_26_PLTREL        49
2982 #define R_M32R_COPY             50
2983 #define R_M32R_GLOB_DAT         51
2984 #define R_M32R_JMP_SLOT         52
2985 #define R_M32R_RELATIVE         53
2986 #define R_M32R_GOTOFF           54
2987 #define R_M32R_GOTPC24          55
2988 #define R_M32R_GOT16_HI_ULO     56
2989
2990 #define R_M32R_GOT16_HI_SLO     57
2991
2992 #define R_M32R_GOT16_LO         58
2993 #define R_M32R_GOTPC_HI_ULO     59
2994
2995 #define R_M32R_GOTPC_HI_SLO     60
2996
2997 #define R_M32R_GOTPC_LO         61
2998
2999 #define R_M32R_GOTOFF_HI_ULO    62
3000
3001 #define R_M32R_GOTOFF_HI_SLO    63
3002
3003 #define R_M32R_GOTOFF_LO        64
3004 #define R_M32R_NUM              256
3005
3006 #define R_MICROBLAZE_NONE 0
3007 #define R_MICROBLAZE_32 1
3008 #define R_MICROBLAZE_32_PCREL 2
3009 #define R_MICROBLAZE_64_PCREL 3
3010 #define R_MICROBLAZE_32_PCREL_LO 4
3011 #define R_MICROBLAZE_64 5
3012 #define R_MICROBLAZE_32_LO 6
3013 #define R_MICROBLAZE_SRO32 7
3014 #define R_MICROBLAZE_SRW32 8
3015 #define R_MICROBLAZE_64_NONE 9
3016 #define R_MICROBLAZE_32_SYM_OP_SYM 10
3017 #define R_MICROBLAZE_GNU_VTINHERIT 11
3018 #define R_MICROBLAZE_GNU_VTENTRY 12
3019 #define R_MICROBLAZE_GOTPC_64 13
3020 #define R_MICROBLAZE_GOT_64 14
3021 #define R_MICROBLAZE_PLT_64 15
3022 #define R_MICROBLAZE_REL 16
3023 #define R_MICROBLAZE_JUMP_SLOT 17
3024 #define R_MICROBLAZE_GLOB_DAT 18
3025 #define R_MICROBLAZE_GOTOFF_64 19
3026 #define R_MICROBLAZE_GOTOFF_32 20
3027 #define R_MICROBLAZE_COPY 21
3028 #define R_MICROBLAZE_TLS 22
3029 #define R_MICROBLAZE_TLSGD 23
3030 #define R_MICROBLAZE_TLSLD 24
3031 #define R_MICROBLAZE_TLSDTPMOD32 25
3032 #define R_MICROBLAZE_TLSDTPREL32 26
3033 #define R_MICROBLAZE_TLSDTPREL64 27
3034 #define R_MICROBLAZE_TLSGOTTPREL32 28
3035 #define R_MICROBLAZE_TLSTPREL32  29
3036
3037 #define DT_NIOS2_GP             0x70000002
3038
3039 #define R_NIOS2_NONE            0
3040 #define R_NIOS2_S16             1
3041 #define R_NIOS2_U16             2
3042 #define R_NIOS2_PCREL16         3
3043 #define R_NIOS2_CALL26          4
3044 #define R_NIOS2_IMM5            5
3045 #define R_NIOS2_CACHE_OPX       6
3046 #define R_NIOS2_IMM6            7
3047 #define R_NIOS2_IMM8            8
3048 #define R_NIOS2_HI16            9
3049 #define R_NIOS2_LO16            10
3050 #define R_NIOS2_HIADJ16         11
3051 #define R_NIOS2_BFD_RELOC_32    12
3052 #define R_NIOS2_BFD_RELOC_16    13
3053 #define R_NIOS2_BFD_RELOC_8     14
3054 #define R_NIOS2_GPREL           15
3055 #define R_NIOS2_GNU_VTINHERIT   16
3056 #define R_NIOS2_GNU_VTENTRY     17
3057 #define R_NIOS2_UJMP            18
3058 #define R_NIOS2_CJMP            19
3059 #define R_NIOS2_CALLR           20
3060 #define R_NIOS2_ALIGN           21
3061 #define R_NIOS2_GOT16           22
3062 #define R_NIOS2_CALL16          23
3063 #define R_NIOS2_GOTOFF_LO       24
3064 #define R_NIOS2_GOTOFF_HA       25
3065 #define R_NIOS2_PCREL_LO        26
3066 #define R_NIOS2_PCREL_HA        27
3067 #define R_NIOS2_TLS_GD16        28
3068 #define R_NIOS2_TLS_LDM16       29
3069 #define R_NIOS2_TLS_LDO16       30
3070 #define R_NIOS2_TLS_IE16        31
3071 #define R_NIOS2_TLS_LE16        32
3072 #define R_NIOS2_TLS_DTPMOD      33
3073 #define R_NIOS2_TLS_DTPREL      34
3074 #define R_NIOS2_TLS_TPREL       35
3075 #define R_NIOS2_COPY            36
3076 #define R_NIOS2_GLOB_DAT        37
3077 #define R_NIOS2_JUMP_SLOT       38
3078 #define R_NIOS2_RELATIVE        39
3079 #define R_NIOS2_GOTOFF          40
3080 #define R_NIOS2_CALL26_NOAT     41
3081 #define R_NIOS2_GOT_LO          42
3082 #define R_NIOS2_GOT_HA          43
3083 #define R_NIOS2_CALL_LO         44
3084 #define R_NIOS2_CALL_HA         45
3085
3086 #define R_OR1K_NONE             0
3087 #define R_OR1K_32               1
3088 #define R_OR1K_16               2
3089 #define R_OR1K_8                3
3090 #define R_OR1K_LO_16_IN_INSN    4
3091 #define R_OR1K_HI_16_IN_INSN    5
3092 #define R_OR1K_INSN_REL_26      6
3093 #define R_OR1K_GNU_VTENTRY      7
3094 #define R_OR1K_GNU_VTINHERIT    8
3095 #define R_OR1K_32_PCREL         9
3096 #define R_OR1K_16_PCREL         10
3097 #define R_OR1K_8_PCREL          11
3098 #define R_OR1K_GOTPC_HI16       12
3099 #define R_OR1K_GOTPC_LO16       13
3100 #define R_OR1K_GOT16            14
3101 #define R_OR1K_PLT26            15
3102 #define R_OR1K_GOTOFF_HI16      16
3103 #define R_OR1K_GOTOFF_LO16      17
3104 #define R_OR1K_COPY             18
3105 #define R_OR1K_GLOB_DAT         19
3106 #define R_OR1K_JMP_SLOT         20
3107 #define R_OR1K_RELATIVE         21
3108 #define R_OR1K_TLS_GD_HI16      22
3109 #define R_OR1K_TLS_GD_LO16      23
3110 #define R_OR1K_TLS_LDM_HI16     24
3111 #define R_OR1K_TLS_LDM_LO16     25
3112 #define R_OR1K_TLS_LDO_HI16     26
3113 #define R_OR1K_TLS_LDO_LO16     27
3114 #define R_OR1K_TLS_IE_HI16      28
3115 #define R_OR1K_TLS_IE_LO16      29
3116 #define R_OR1K_TLS_LE_HI16      30
3117 #define R_OR1K_TLS_LE_LO16      31
3118 #define R_OR1K_TLS_TPOFF        32
3119 #define R_OR1K_TLS_DTPOFF       33
3120 #define R_OR1K_TLS_DTPMOD       34
3121
3122 #define R_BPF_NONE              0
3123 #define R_BPF_MAP_FD            1
3124
3125 #ifdef __cplusplus
3126 }
3127 #endif
3128
3129
3130 #endif