1 /**
2  * D header file for standard ELF types, structures, and macros.
3  *
4  * $(LINK2 http://sourceware.org/git/?p=glibc.git;a=blob;f=elf/elf.h, glibc elf/elf.h)
5  */
6 module core.sys.elf;
7 
8 extern (C):
9 pure:
10 nothrow:
11 
12 import core.stdc.stdint;
13 
14 alias uint16_t Elf32_Half;
15 alias uint16_t Elf64_Half;
16 
17 alias uint32_t Elf32_Word;
18 alias int32_t  Elf32_Sword;
19 alias uint32_t Elf64_Word;
20 alias int32_t  Elf64_Sword;
21 
22 alias uint64_t Elf32_Xword;
23 alias int64_t  Elf32_Sxword;
24 alias uint64_t Elf64_Xword;
25 alias int64_t  Elf64_Sxword;
26 
27 alias uint32_t Elf32_Addr;
28 alias uint64_t Elf64_Addr;
29 
30 alias uint32_t Elf32_Off;
31 alias uint64_t Elf64_Off;
32 
33 alias uint16_t Elf32_Section;
34 alias uint16_t Elf64_Section;
35 
36 alias Elf32_Half Elf32_Versym;
37 alias Elf64_Half Elf64_Versym;
38 
39 enum EI_NIDENT = 16;
40 
41 struct Elf32_Ehdr
42 {
43     char[EI_NIDENT] e_ident = 0;
44     Elf32_Half    e_type;
45     Elf32_Half    e_machine;
46     Elf32_Word    e_version;
47     Elf32_Addr    e_entry;
48     Elf32_Off     e_phoff;
49     Elf32_Off     e_shoff;
50     Elf32_Word    e_flags;
51     Elf32_Half    e_ehsize;
52     Elf32_Half    e_phentsize;
53     Elf32_Half    e_phnum;
54     Elf32_Half    e_shentsize;
55     Elf32_Half    e_shnum;
56     Elf32_Half    e_shstrndx;
57 }
58 
59 struct Elf64_Ehdr
60 {
61     char[EI_NIDENT] e_ident = 0;
62     Elf64_Half    e_type;
63     Elf64_Half    e_machine;
64     Elf64_Word    e_version;
65     Elf64_Addr    e_entry;
66     Elf64_Off     e_phoff;
67     Elf64_Off     e_shoff;
68     Elf64_Word    e_flags;
69     Elf64_Half    e_ehsize;
70     Elf64_Half    e_phentsize;
71     Elf64_Half    e_phnum;
72     Elf64_Half    e_shentsize;
73     Elf64_Half    e_shnum;
74     Elf64_Half    e_shstrndx;
75 }
76 
77 enum EI_MAG0 =         0;
78 enum ELFMAG0 =         0x7f;
79 
80 enum EI_MAG1 =         1;
81 enum ELFMAG1 =         'E';
82 
83 enum EI_MAG2 =         2;
84 enum ELFMAG2 =         'L';
85 
86 enum EI_MAG3 =         3;
87 enum ELFMAG3 =         'F';
88 enum ELFMAG =          "\177ELF";
89 enum SELFMAG =         4;
90 
91 enum EI_CLASS =        4;
92 enum ELFCLASSNONE =    0;
93 enum ELFCLASS32 =      1;
94 enum ELFCLASS64 =      2;
95 enum ELFCLASSNUM =     3;
96 
97 enum EI_DATA =         5;
98 enum ELFDATANONE =     0;
99 enum ELFDATA2LSB =     1;
100 enum ELFDATA2MSB =     2;
101 enum ELFDATANUM =      3;
102 
103 enum EI_VERSION =      6;
104 
105 enum EI_OSABI =        7;
106 enum ELFOSABI_NONE =           0;
107 enum ELFOSABI_SYSV =           0;
108 enum ELFOSABI_HPUX =           1;
109 enum ELFOSABI_NETBSD =         2;
110 enum ELFOSABI_GNU =            3;
111 enum ELFOSABI_LINUX =          ELFOSABI_GNU;
112 enum ELFOSABI_HURD =           4;
113 enum ELFOSABI_86OPEN =         5;
114 enum ELFOSABI_SOLARIS =        6;
115 enum ELFOSABI_AIX =            7;
116 enum ELFOSABI_MONTEREY =       7;
117 enum ELFOSABI_IRIX =           8;
118 enum ELFOSABI_FREEBSD =        9;
119 enum ELFOSABI_TRU64 =          10;
120 enum ELFOSABI_MODESTO =        11;
121 enum ELFOSABI_OPENBSD =        12;
122 enum ELFOSABI_OPENVMS =        13;
123 enum ELFOSABI_NSK =            14;
124 enum ELFOSABI_AROS =           15;
125 enum ELFOSABI_ARM_AEABI =      64;
126 enum ELFOSABI_ARM =            97;
127 enum ELFOSABI_STANDALONE =     255;
128 enum ELFOSABI_DRAGONFLYBSD =   ELFOSABI_NONE;
129 
130 enum EI_ABIVERSION =   8;
131 
132 enum EI_PAD =          9;
133 
134 enum ET_NONE =         0;
135 enum ET_REL =          1;
136 enum ET_EXEC =         2;
137 enum ET_DYN =          3;
138 enum ET_CORE =         4;
139 enum ET_NUM =          5;
140 enum ET_LOOS =         0xfe00;
141 enum ET_HIOS =         0xfeff;
142 enum ET_LOPROC =       0xff00;
143 enum ET_HIPROC =       0xffff;
144 
145 enum EM_NONE =          0;
146 enum EM_M32 =           1;
147 enum EM_SPARC =         2;
148 enum EM_386 =           3;
149 enum EM_68K =           4;
150 enum EM_88K =           5;
151 enum EM_860 =           7;
152 enum EM_MIPS =          8;
153 enum EM_S370 =          9;
154 enum EM_MIPS_RS3_LE =  10;
155 
156 enum EM_PARISC =       15;
157 enum EM_VPP500 =       17;
158 enum EM_SPARC32PLUS =  18;
159 enum EM_960 =          19;
160 enum EM_PPC =          20;
161 enum EM_PPC64 =        21;
162 enum EM_S390 =         22;
163 
164 enum EM_V800 =         36;
165 enum EM_FR20 =         37;
166 enum EM_RH32 =         38;
167 enum EM_RCE =          39;
168 enum EM_ARM =          40;
169 enum EM_FAKE_ALPHA =   41;
170 enum EM_SH =           42;
171 enum EM_SPARCV9 =      43;
172 enum EM_TRICORE =      44;
173 enum EM_ARC =          45;
174 enum EM_H8_300 =       46;
175 enum EM_H8_300H =      47;
176 enum EM_H8S =          48;
177 enum EM_H8_500 =       49;
178 enum EM_IA_64 =        50;
179 enum EM_MIPS_X =       51;
180 enum EM_COLDFIRE =     52;
181 enum EM_68HC12 =       53;
182 enum EM_MMA =          54;
183 enum EM_PCP =          55;
184 enum EM_NCPU =         56;
185 enum EM_NDR1 =         57;
186 enum EM_STARCORE =     58;
187 enum EM_ME16 =         59;
188 enum EM_ST100 =        60;
189 enum EM_TINYJ =        61;
190 enum EM_X86_64 =       62;
191 enum EM_PDSP =         63;
192 
193 enum EM_FX66 =         66;
194 enum EM_ST9PLUS =      67;
195 enum EM_ST7 =          68;
196 enum EM_68HC16 =       69;
197 enum EM_68HC11 =       70;
198 enum EM_68HC08 =       71;
199 enum EM_68HC05 =       72;
200 enum EM_SVX =          73;
201 enum EM_ST19 =         74;
202 enum EM_VAX =          75;
203 enum EM_CRIS =         76;
204 enum EM_JAVELIN =      77;
205 enum EM_FIREPATH =     78;
206 enum EM_ZSP =          79;
207 enum EM_MMIX =         80;
208 enum EM_HUANY =        81;
209 enum EM_PRISM =        82;
210 enum EM_AVR =          83;
211 enum EM_FR30 =         84;
212 enum EM_D10V =         85;
213 enum EM_D30V =         86;
214 enum EM_V850 =         87;
215 enum EM_M32R =         88;
216 enum EM_MN10300 =      89;
217 enum EM_MN10200 =      90;
218 enum EM_PJ =           91;
219 enum EM_OPENRISC =     92;
220 enum EM_ARC_A5 =       93;
221 enum EM_XTENSA =       94;
222 enum EM_VIDEOCORE =    95;
223 enum EM_TMM_GPP =      96;
224 enum EM_NS32K =        97;
225 enum EM_TPC =          98;
226 enum EM_SNP1K =        99;
227 enum EM_ST200 =       100;
228 enum EM_IP2K =        101;
229 enum EM_MAX =         102;
230 enum EM_CR =          103;
231 enum EM_F2MC16 =      104;
232 enum EM_MSP430 =      105;
233 enum EM_BLACKFIN =    106;
234 enum EM_SE_C33 =      107;
235 enum EM_SEP =         108;
236 enum EM_ARCA =        109;
237 enum EM_UNICORE =     110;
238 enum EM_DXP =         112;
239 enum EM_ALTERA_NIOS2 = 113;
240 enum EM_CRX =         114;
241 enum EM_XGATE =       115;
242 enum EM_C166  =       116;
243 enum EM_M16C  =       117;
244 enum EM_DSPIC30F =    118;
245 enum EM_CE =          119;
246 enum EM_M32C  =       120;
247 enum EM_res121 =      121;
248 enum EM_res122 =      122;
249 enum EM_res123 =      123;
250 enum EM_res124 =      124;
251 enum EM_res125 =      125;
252 enum EM_res126 =      126;
253 enum EM_res127 =      127;
254 enum EM_res128 =      128;
255 enum EM_res129 =      129;
256 enum EM_res130 =      130;
257 enum EM_TSK3000 =     131;
258 enum EM_RS08  =       132;
259 enum EM_res133 =      133;
260 enum EM_ECOG2 =       134;
261 enum EM_SCORE =       135;
262 enum EM_SCORE7 =      135;
263 enum EM_DSP24 =       136;
264 enum EM_VIDEOCORE3 =  137;
265 enum EM_LATTICEMICO32 = 138;
266 enum EM_SE_C17 =      139;
267 enum EM_TI_C6000 =    140;
268 enum EM_TI_C2000 =    141;
269 enum EM_TI_C5500 =    142;
270 enum EM_TI_ARP32 =    143;
271 enum EM_TI_PRU =      144;
272 enum EM_MMDSP_PLUS =  160;
273 enum EM_CYPRESS_M8C = 161;
274 enum EM_R32C  =       162;
275 enum EM_TRIMEDIA =    163;
276 enum EM_QDSP6 =       164;
277 enum EM_8051  =       165;
278 enum EM_STXP7X =      166;
279 enum EM_NDS32 =       167;
280 enum EM_ECOG1 =       168;
281 enum EM_ECOG1X =      168;
282 enum EM_MAXQ30 =      169;
283 enum EM_XIMO16 =      170;
284 enum EM_MANIK =       171;
285 enum EM_CRAYNV2 =     172;
286 enum EM_RX =          173;
287 enum EM_METAG =       174;
288 enum EM_MCST_ELBRUS = 175;
289 enum EM_ECOG16 =      176;
290 enum EM_CR16  =       177;
291 enum EM_ETPU  =       178;
292 enum EM_SLE9X =       179;
293 enum EM_L1OM  =       180;
294 enum EM_K1OM  =       181;
295 enum EM_INTEL182 =    182;
296 enum EM_AARCH64 =     183;
297 enum EM_AVR32 =       185;
298 enum EM_STM8  =       186;
299 enum EM_TILE64 =      187;
300 enum EM_TILEPRO =     188;
301 enum EM_MICROBLAZE =  189;
302 enum EM_CUDA  =       190;
303 enum EM_TILEGX =      191;
304 enum EM_CLOUDSHIELD = 192;
305 enum EM_COREA_1ST =   193;
306 enum EM_COREA_2ND =   194;
307 enum EM_ARCV2 =       195;
308 enum EM_OPEN8 =       196;
309 enum EM_RL78 =        197;
310 enum EM_VIDEOCORE5 =  198;
311 enum EM_78KOR =       199;
312 enum EM_56800EX =     200;
313 enum EM_BA1 =         201;
314 enum EM_BA2 =         202;
315 enum EM_XCORE =       203;
316 enum EM_MCHP_PIC =    204;
317 enum EM_INTELGT =     205;
318 
319 enum EM_KM32 =        210;
320 enum EM_KMX32 =       211;
321 enum EM_EMX16 =       212;
322 enum EM_EMX8 =        213;
323 enum EM_KVARC =       214;
324 enum EM_CDP =         215;
325 enum EM_COGE =        216;
326 enum EM_COOL =        217;
327 enum EM_NORC =        218;
328 enum EM_CSR_KALIMBA = 219;
329 enum EM_Z80 =         220;
330 enum EM_VISIUM =      221;
331 enum EM_FT32 =        222;
332 enum EM_MOXIE =       223;
333 enum EM_AMDGPU =      224;
334 
335 enum EM_RISCV =       243;
336 
337 enum EM_BPF =         247;
338 enum EM_CSKY =        252;
339 
340 enum EM_NUM =         253;
341 
342 enum EM_ALPHA =        0x9026;
343 
344 enum EV_NONE =         0;
345 enum EV_CURRENT =      1;
346 enum EV_NUM =          2;
347 
348 struct Elf32_Shdr
349 {
350   Elf32_Word    sh_name;
351   Elf32_Word    sh_type;
352   Elf32_Word    sh_flags;
353   Elf32_Addr    sh_addr;
354   Elf32_Off     sh_offset;
355   Elf32_Word    sh_size;
356   Elf32_Word    sh_link;
357   Elf32_Word    sh_info;
358   Elf32_Word    sh_addralign;
359   Elf32_Word    sh_entsize;
360 }
361 
362 struct Elf64_Shdr
363 {
364   Elf64_Word    sh_name;
365   Elf64_Word    sh_type;
366   Elf64_Xword   sh_flags;
367   Elf64_Addr    sh_addr;
368   Elf64_Off     sh_offset;
369   Elf64_Xword   sh_size;
370   Elf64_Word    sh_link;
371   Elf64_Word    sh_info;
372   Elf64_Xword   sh_addralign;
373   Elf64_Xword   sh_entsize;
374 }
375 
376 enum SHN_UNDEF =       0;
377 enum SHN_LORESERVE =   0xff00;
378 enum SHN_LOPROC =      0xff00;
379 enum SHN_BEFORE =      0xff00;
380 enum SHN_AFTER =       0xff01;
381 enum SHN_HIPROC =      0xff1f;
382 enum SHN_LOOS =        0xff20;
383 enum SHN_HIOS =        0xff3f;
384 enum SHN_ABS =         0xfff1;
385 enum SHN_COMMON =      0xfff2;
386 enum SHN_XINDEX =      0xffff;
387 enum SHN_HIRESERVE =   0xffff;
388 
389 enum SHT_NULL =          0;
390 enum SHT_PROGBITS =      1;
391 enum SHT_SYMTAB =        2;
392 enum SHT_STRTAB =        3;
393 enum SHT_RELA =          4;
394 enum SHT_HASH =          5;
395 enum SHT_DYNAMIC =       6;
396 enum SHT_NOTE =          7;
397 enum SHT_NOBITS =        8;
398 enum SHT_REL =           9;
399 enum SHT_SHLIB =         10;
400 enum SHT_DYNSYM =        11;
401 enum SHT_INIT_ARRAY =    14;
402 enum SHT_FINI_ARRAY =    15;
403 enum SHT_PREINIT_ARRAY = 16;
404 enum SHT_GROUP =         17;
405 enum SHT_SYMTAB_SHNDX =  18;
406 enum SHT_NUM =           19;
407 enum SHT_LOOS =          0x60000000;
408 enum SHT_GNU_ATTRIBUTES = 0x6ffffff5;
409 enum SHT_GNU_HASH =      0x6ffffff6;
410 enum SHT_GNU_LIBLIST =   0x6ffffff7;
411 enum SHT_CHECKSUM =      0x6ffffff8;
412 enum SHT_LOSUNW =        0x6ffffffa;
413 enum SHT_SUNW_move =     0x6ffffffa;
414 enum SHT_SUNW_COMDAT =   0x6ffffffb;
415 enum SHT_SUNW_syminfo =  0x6ffffffc;
416 enum SHT_GNU_verdef =    0x6ffffffd;
417 enum SHT_GNU_verneed =   0x6ffffffe;
418 enum SHT_GNU_versym =    0x6fffffff;
419 enum SHT_HISUNW =        0x6fffffff;
420 enum SHT_HIOS =          0x6fffffff;
421 enum SHT_LOPROC =        0x70000000;
422 enum SHT_HIPROC =        0x7fffffff;
423 enum SHT_LOUSER =        0x80000000;
424 enum SHT_HIUSER =        0x8fffffff;
425 
426 enum SHF_WRITE =            (1 << 0);
427 enum SHF_ALLOC =            (1 << 1);
428 enum SHF_EXECINSTR =        (1 << 2);
429 enum SHF_MERGE =            (1 << 4);
430 enum SHF_STRINGS =          (1 << 5);
431 enum SHF_INFO_LINK =        (1 << 6);
432 enum SHF_LINK_ORDER =       (1 << 7);
433 enum SHF_OS_NONCONFORMING = (1 << 8);
434 enum SHF_GROUP =            (1 << 9);
435 enum SHF_TLS =              (1 << 10);
436 enum SHF_COMPRESSED =       (1 << 11);
437 enum SHF_MASKOS =           0x0ff00000;
438 enum SHF_MASKPROC =         0xf0000000;
439 enum SHF_ORDERED =          (1 << 30);
440 enum SHF_EXCLUDE =          (1 << 31);
441 enum GRP_COMDAT =      0x1;
442 
443 struct Elf32_Sym
444 {
445   Elf32_Word    st_name;
446   Elf32_Addr    st_value;
447   Elf32_Word    st_size;
448   ubyte st_info;
449   ubyte st_other;
450   Elf32_Section st_shndx;
451 }
452 
453 struct Elf64_Sym
454 {
455   Elf64_Word    st_name;
456   ubyte st_info;
457   ubyte st_other;
458   Elf64_Section st_shndx;
459   Elf64_Addr    st_value;
460   Elf64_Xword   st_size;
461 }
462 
463 struct Elf32_Syminfo
464 {
465   Elf32_Half si_boundto;
466   Elf32_Half si_flags;
467 }
468 
469 struct Elf64_Syminfo
470 {
471   Elf64_Half si_boundto;
472   Elf64_Half si_flags;
473 }
474 
475 enum SYMINFO_BT_SELF =         0xffff;
476 enum SYMINFO_BT_PARENT =       0xfffe;
477 enum SYMINFO_BT_LOWRESERVE =   0xff00;
478 
479 enum SYMINFO_FLG_DIRECT =      0x0001;
480 enum SYMINFO_FLG_PASSTHRU =    0x0002;
481 enum SYMINFO_FLG_COPY =        0x0004;
482 enum SYMINFO_FLG_LAZYLOAD =    0x0008;
483 
484 enum SYMINFO_NONE =            0;
485 enum SYMINFO_CURRENT =         1;
486 enum SYMINFO_NUM =             2;
487 
488 extern (D)
489 {
490     auto ELF32_ST_BIND(T)(T val) { return cast(ubyte)val >> 4; }
491     auto ELF32_ST_TYPE(T)(T val) { return val & 0xf; }
492     auto ELF32_ST_INFO(B, T)(B bind, T type) { return (bind << 4) + (type & 0xf); }
493     alias ELF32_ST_BIND ELF64_ST_BIND;
494     alias ELF32_ST_TYPE ELF64_ST_TYPE;
495     alias ELF32_ST_INFO ELF64_ST_INFO;
496 }
497 
498 enum STB_LOCAL =       0;
499 enum STB_GLOBAL =      1;
500 enum STB_WEAK =        2;
501 enum STB_NUM =         3;
502 enum STB_LOOS =        10;
503 enum STB_GNU_UNIQUE =  10;
504 enum STB_HIOS =        12;
505 enum STB_LOPROC =      13;
506 enum STB_HIPROC =      15;
507 
508 enum STT_NOTYPE =      0;
509 enum STT_OBJECT =      1;
510 enum STT_FUNC =        2;
511 enum STT_SECTION =     3;
512 enum STT_FILE =        4;
513 enum STT_COMMON =      5;
514 enum STT_TLS =         6;
515 enum STT_NUM =         7;
516 enum STT_LOOS =        10;
517 enum STT_GNU_IFUNC =   10;
518 enum STT_HIOS =        12;
519 enum STT_LOPROC =      13;
520 enum STT_HIPROC =      15;
521 
522 enum STN_UNDEF =       0;
523 
524 enum STV_DEFAULT =     0;
525 enum STV_INTERNAL =    1;
526 enum STV_HIDDEN =      2;
527 enum STV_PROTECTED =   3;
528 
529 struct Elf32_Rel
530 {
531   Elf32_Addr    r_offset;
532   Elf32_Word    r_info;
533 }
534 
535 struct Elf64_Rel
536 {
537   Elf64_Addr    r_offset;
538   Elf64_Xword   r_info;
539 }
540 
541 struct Elf32_Rela
542 {
543   Elf32_Addr    r_offset;
544   Elf32_Word    r_info;
545   Elf32_Sword   r_addend;
546 }
547 
548 struct Elf64_Rela
549 {
550   Elf64_Addr    r_offset;
551   Elf64_Xword   r_info;
552   Elf64_Sxword  r_addend;
553 }
554 
555 extern (D)
556 {
557     auto ELF32_R_SYM(V)(V val) { return val >> 8; }
558     auto ELF32_R_TYPE(V)(V val) { return val & 0xff; }
559     auto ELF32_R_INFO(S, T)(S sym, T type) { return (sym << 8) + (type & 0xff); }
560 
561     auto ELF64_R_SYM(I)(I i) { return i >> 32; }
562     auto ELF64_R_TYPE(I)(I i) { return i & 0xffffffff; }
563     auto ELF64_R_INFO(S, T)(S sym, T type) { return (sym << 32) + (type); }
564 }
565 
566 struct Elf32_Phdr
567 {
568   Elf32_Word    p_type;
569   Elf32_Off     p_offset;
570   Elf32_Addr    p_vaddr;
571   Elf32_Addr    p_paddr;
572   Elf32_Word    p_filesz;
573   Elf32_Word    p_memsz;
574   Elf32_Word    p_flags;
575   Elf32_Word    p_align;
576 }
577 
578 struct Elf64_Phdr
579 {
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 }
589 
590 enum PN_XNUM =         0xffff;
591 
592 enum PT_NULL =         0;
593 enum PT_LOAD =         1;
594 enum PT_DYNAMIC =      2;
595 enum PT_INTERP =       3;
596 enum PT_NOTE =         4;
597 enum PT_SHLIB =        5;
598 enum PT_PHDR =         6;
599 enum PT_TLS =          7;
600 enum PT_NUM =          8;
601 enum PT_LOOS =         0x60000000;
602 enum PT_GNU_EH_FRAME = 0x6474e550;
603 enum PT_GNU_STACK =    0x6474e551;
604 enum PT_GNU_RELRO =    0x6474e552;
605 enum PT_LOSUNW =       0x6ffffffa;
606 enum PT_SUNWBSS =      0x6ffffffa;
607 enum PT_SUNWSTACK =    0x6ffffffb;
608 enum PT_HISUNW =       0x6fffffff;
609 enum PT_HIOS =         0x6fffffff;
610 enum PT_LOPROC =       0x70000000;
611 enum PT_HIPROC =       0x7fffffff;
612 
613 enum PF_X =            (1 << 0);
614 enum PF_W =            (1 << 1);
615 enum PF_R =            (1 << 2);
616 enum PF_MASKOS =       0x0ff00000;
617 enum PF_MASKPROC =     0xf0000000;
618 
619 enum DT_NULL =         0;
620 enum DT_NEEDED =       1;
621 enum DT_PLTRELSZ =     2;
622 enum DT_PLTGOT =       3;
623 enum DT_HASH =         4;
624 enum DT_STRTAB =       5;
625 enum DT_SYMTAB =       6;
626 enum DT_RELA =         7;
627 enum DT_RELASZ =       8;
628 enum DT_RELAENT =      9;
629 enum DT_STRSZ =        10;
630 enum DT_SYMENT =       11;
631 enum DT_INIT =         12;
632 enum DT_FINI =         13;
633 enum DT_SONAME =       14;
634 enum DT_RPATH =        15;
635 enum DT_SYMBOLIC =     16;
636 enum DT_REL =          17;
637 enum DT_RELSZ =        18;
638 enum DT_RELENT =       19;
639 enum DT_PLTREL =       20;
640 enum DT_DEBUG =        21;
641 enum DT_TEXTREL =      22;
642 enum DT_JMPREL =       23;
643 enum DT_BIND_NOW =     24;
644 enum DT_INIT_ARRAY =   25;
645 enum DT_FINI_ARRAY =   26;
646 enum DT_INIT_ARRAYSZ = 27;
647 enum DT_FINI_ARRAYSZ = 28;
648 enum DT_RUNPATH =      29;
649 enum DT_FLAGS =        30;
650 enum DT_ENCODING =     32;
651 enum DT_PREINIT_ARRAY = 32;
652 enum DT_PREINIT_ARRAYSZ = 33;
653 enum DT_NUM =          34;
654 enum DT_LOOS =         0x6000000d;
655 enum DT_HIOS =         0x6ffff000;
656 enum DT_LOPROC =       0x70000000;
657 enum DT_HIPROC =       0x7fffffff;
658 enum DT_PROCNUM =      DT_MIPS_NUM;
659 enum DT_VALRNGLO =     0x6ffffd00;
660 enum DT_GNU_PRELINKED = 0x6ffffdf5;
661 enum DT_GNU_CONFLICTSZ = 0x6ffffdf6;
662 enum DT_GNU_LIBLISTSZ = 0x6ffffdf7;
663 enum DT_CHECKSUM =     0x6ffffdf8;
664 enum DT_PLTPADSZ =     0x6ffffdf9;
665 enum DT_MOVEENT =      0x6ffffdfa;
666 enum DT_MOVESZ =       0x6ffffdfb;
667 enum DT_FEATURE_1 =    0x6ffffdfc;
668 enum DT_POSFLAG_1 =    0x6ffffdfd;
669 enum DT_SYMINSZ =      0x6ffffdfe;
670 enum DT_SYMINENT =     0x6ffffdff;
671 enum DT_VALRNGHI =     0x6ffffdff;
672 extern (D) auto DT_VALTAGIDX(T)(T tag)
673 {
674     return DT_VALRNGHI - tag;
675 }
676 enum DT_VALNUM = 12;
677 enum DT_ADDRRNGLO =    0x6ffffe00;
678 enum DT_GNU_HASH =     0x6ffffef5;
679 enum DT_TLSDESC_PLT =  0x6ffffef6;
680 enum DT_TLSDESC_GOT =  0x6ffffef7;
681 enum DT_GNU_CONFLICT = 0x6ffffef8;
682 enum DT_GNU_LIBLIST =  0x6ffffef9;
683 enum DT_CONFIG =       0x6ffffefa;
684 enum DT_DEPAUDIT =     0x6ffffefb;
685 enum DT_AUDIT =        0x6ffffefc;
686 enum DT_PLTPAD =       0x6ffffefd;
687 enum DT_MOVETAB =      0x6ffffefe;
688 enum DT_SYMINFO =      0x6ffffeff;
689 enum DT_ADDRRNGHI =    0x6ffffeff;
690 extern (D) auto DT_ADDRTAGIDX(T)(T tag)
691 {
692     return DT_ADDRRNGHI - tag;
693 }
694 enum DT_ADDRNUM = 11;
695 enum DT_VERSYM =       0x6ffffff0;
696 
697 enum DT_RELACOUNT =    0x6ffffff9;
698 enum DT_RELCOUNT =     0x6ffffffa;
699 enum DT_FLAGS_1 =      0x6ffffffb;
700 enum DT_VERDEF =       0x6ffffffc;
701 enum DT_VERDEFNUM =    0x6ffffffd;
702 enum DT_VERNEED =      0x6ffffffe;
703 enum DT_VERNEEDNUM =   0x6fffffff;
704 extern (D) auto DT_VERSIONTAGIDX(T)(T tag)
705 {
706     return DT_VERNEEDNUM - tag;
707 }
708 enum DT_VERSIONTAGNUM = 16;
709 enum DT_AUXILIARY =    0x7ffffffd;
710 enum DT_FILTER =       0x7fffffff;
711 extern (D) auto DT_EXTRATAGIDX(T)(T tag)
712 {
713     return cast(Elf32_Word)(-(cast(Elf32_Sword)(tag) <<1>>1)-1);
714 }
715 enum DT_EXTRANUM =     3;
716 enum DF_ORIGIN =       0x00000001;
717 enum DF_SYMBOLIC =     0x00000002;
718 enum DF_TEXTREL =      0x00000004;
719 enum DF_BIND_NOW =     0x00000008;
720 enum DF_STATIC_TLS =   0x00000010;
721 enum DF_1_NOW =        0x00000001;
722 enum DF_1_GLOBAL =     0x00000002;
723 enum DF_1_GROUP =      0x00000004;
724 enum DF_1_NODELETE =   0x00000008;
725 enum DF_1_LOADFLTR =   0x00000010;
726 enum DF_1_INITFIRST =  0x00000020;
727 enum DF_1_NOOPEN =     0x00000040;
728 enum DF_1_ORIGIN =     0x00000080;
729 enum DF_1_DIRECT =     0x00000100;
730 enum DF_1_TRANS =      0x00000200;
731 enum DF_1_INTERPOSE =  0x00000400;
732 enum DF_1_NODEFLIB =   0x00000800;
733 enum DF_1_NODUMP =     0x00001000;
734 enum DF_1_CONFALT =    0x00002000;
735 enum DF_1_ENDFILTEE =  0x00004000;
736 enum DF_1_DISPRELDNE = 0x00008000;
737 enum DF_1_DISPRELPND = 0x00010000;
738 enum DF_1_NODIRECT =   0x00020000;
739 enum DF_1_IGNMULDEF =  0x00040000;
740 enum DF_1_NOKSYMS =    0x00080000;
741 enum DF_1_NOHDR =      0x00100000;
742 enum DF_1_EDITED =     0x00200000;
743 enum DF_1_NORELOC =    0x00400000;
744 enum DF_1_SYMINTPOSE = 0x00800000;
745 enum DF_1_GLOBAUDIT =  0x01000000;
746 enum DF_1_SINGLETON =  0x02000000;
747 enum DTF_1_PARINIT =   0x00000001;
748 enum DTF_1_CONFEXP =   0x00000002;
749 enum DF_P1_LAZYLOAD =  0x00000001;
750 enum DF_P1_GROUPPERM = 0x00000002;
751 
752 struct Elf32_Verdef
753 {
754     Elf32_Half    vd_version;
755     Elf32_Half    vd_flags;
756     Elf32_Half    vd_ndx;
757     Elf32_Half    vd_cnt;
758     Elf32_Word    vd_hash;
759     Elf32_Word    vd_aux;
760     Elf32_Word    vd_next;
761 }
762 
763 struct Elf64_Verdef
764 {
765     Elf64_Half    vd_version;
766     Elf64_Half    vd_flags;
767     Elf64_Half    vd_ndx;
768     Elf64_Half    vd_cnt;
769     Elf64_Word    vd_hash;
770     Elf64_Word    vd_aux;
771     Elf64_Word    vd_next;
772 }
773 enum VER_DEF_NONE =    0;
774 enum VER_DEF_CURRENT = 1;
775 enum VER_DEF_NUM =     2;
776 enum VER_FLG_BASE =    0x1;
777 enum VER_FLG_WEAK =    0x2;
778 enum VER_NDX_LOCAL =           0;
779 enum VER_NDX_GLOBAL =          1;
780 enum VER_NDX_LORESERVE =       0xff00;
781 enum VER_NDX_ELIMINATE =       0xff01;
782 
783 struct Elf32_Verdaux
784 {
785     Elf32_Word    vda_name;
786     Elf32_Word    vda_next;
787 }
788 
789 struct Elf64_Verdaux
790 {
791     Elf64_Word    vda_name;
792     Elf64_Word    vda_next;
793 }
794 
795 struct Elf32_Verneed
796 {
797     Elf32_Half    vn_version;
798     Elf32_Half    vn_cnt;
799     Elf32_Word    vn_file;
800     Elf32_Word    vn_aux;
801     Elf32_Word    vn_next;
802 }
803 
804 struct Elf64_Verneed
805 {
806     Elf64_Half    vn_version;
807     Elf64_Half    vn_cnt;
808     Elf64_Word    vn_file;
809     Elf64_Word    vn_aux;
810     Elf64_Word    vn_next;
811 }
812 enum VER_NEED_NONE =    0;
813 enum VER_NEED_CURRENT = 1;
814 enum VER_NEED_NUM =     2;
815 
816 struct Elf32_Vernaux
817 {
818     Elf32_Word    vna_hash;
819     Elf32_Half    vna_flags;
820     Elf32_Half    vna_other;
821     Elf32_Word    vna_name;
822     Elf32_Word    vna_next;
823 }
824 
825 struct Elf64_Vernaux
826 {
827     Elf64_Word    vna_hash;
828     Elf64_Half    vna_flags;
829     Elf64_Half    vna_other;
830     Elf64_Word    vna_name;
831     Elf64_Word    vna_next;
832 }
833 
834 enum ELF_NOTE_SOLARIS =        "SUNW Solaris";
835 enum ELF_NOTE_GNU =            "GNU";
836 enum ELF_NOTE_PAGESIZE_HINT =  1;
837 enum ELF_NOTE_ABI =    1;
838 enum ELF_NOTE_OS_LINUX =       0;
839 enum ELF_NOTE_OS_GNU =         1;
840 enum ELF_NOTE_OS_SOLARIS2 =    2;
841 enum ELF_NOTE_OS_FREEBSD =     3;
842 
843 struct Elf32_Move
844 {
845   Elf32_Xword m_value;
846   Elf32_Word m_info;
847   Elf32_Word m_poffset;
848   Elf32_Half m_repeat;
849   Elf32_Half m_stride;
850 }
851 
852 struct Elf64_Move
853 {
854   Elf64_Xword m_value;
855   Elf64_Xword m_info;
856   Elf64_Xword m_poffset;
857   Elf64_Half m_repeat;
858   Elf64_Half m_stride;
859 }
860 extern (D)
861 {
862     auto ELF32_M_SYM(I)(I info) { return info >> 8; }
863     auto ELF32_M_SIZE(I)(I info) { return cast(ubyte)info; }
864     auto ELF32_M_INFO(S, SZ)(S sym, SZ size) { return (sym << 8) + cast(ubyte)size; }
865 }
866 
867 alias ELF32_M_SYM ELF64_M_SYM;
868 alias ELF32_M_SIZE ELF64_M_SIZE;
869 alias ELF32_M_INFO ELF64_M_INFO;
870 enum EF_CPU32 =        0x00810000;
871 
872 enum R_68K_NONE =      0;
873 enum R_68K_32 =        1;
874 enum R_68K_16 =        2;
875 enum R_68K_8 =         3;
876 enum R_68K_PC32 =      4;
877 enum R_68K_PC16 =      5;
878 enum R_68K_PC8 =       6;
879 enum R_68K_GOT32 =     7;
880 enum R_68K_GOT16 =     8;
881 enum R_68K_GOT8 =      9;
882 enum R_68K_GOT32O =    10;
883 enum R_68K_GOT16O =    11;
884 enum R_68K_GOT8O =     12;
885 enum R_68K_PLT32 =     13;
886 enum R_68K_PLT16 =     14;
887 enum R_68K_PLT8 =      15;
888 enum R_68K_PLT32O =    16;
889 enum R_68K_PLT16O =    17;
890 enum R_68K_PLT8O =     18;
891 enum R_68K_COPY =      19;
892 enum R_68K_GLOB_DAT =  20;
893 enum R_68K_JMP_SLOT =  21;
894 enum R_68K_RELATIVE =  22;
895 enum R_68K_TLS_GD32 =      25;
896 enum R_68K_TLS_GD16 =      26;
897 enum R_68K_TLS_GD8 =       27;
898 enum R_68K_TLS_LDM32 =     28;
899 enum R_68K_TLS_LDM16 =     29;
900 enum R_68K_TLS_LDM8 =      30;
901 enum R_68K_TLS_LDO32 =     31;
902 enum R_68K_TLS_LDO16 =     32;
903 enum R_68K_TLS_LDO8 =      33;
904 enum R_68K_TLS_IE32 =      34;
905 enum R_68K_TLS_IE16 =      35;
906 enum R_68K_TLS_IE8 =       36;
907 enum R_68K_TLS_LE32 =      37;
908 enum R_68K_TLS_LE16 =      38;
909 enum R_68K_TLS_LE8 =       39;
910 enum R_68K_TLS_DTPMOD32 =  40;
911 enum R_68K_TLS_DTPREL32 =  41;
912 enum R_68K_TLS_TPREL32 =   42;
913 enum R_68K_NUM =       43;
914 
915 enum R_386_NONE =         0;
916 enum R_386_32 =           1;
917 enum R_386_PC32 =         2;
918 enum R_386_GOT32 =        3;
919 enum R_386_PLT32 =        4;
920 enum R_386_COPY =         5;
921 enum R_386_GLOB_DAT =     6;
922 enum R_386_JMP_SLOT =     7;
923 enum R_386_RELATIVE =     8;
924 enum R_386_GOTOFF =       9;
925 enum R_386_GOTPC =        10;
926 enum R_386_32PLT =        11;
927 enum R_386_TLS_TPOFF =    14;
928 enum R_386_TLS_IE =       15;
929 enum R_386_TLS_GOTIE =    16;
930 enum R_386_TLS_LE =       17;
931 enum R_386_TLS_GD =       18;
932 enum R_386_TLS_LDM =      19;
933 enum R_386_16 =           20;
934 enum R_386_PC16 =         21;
935 enum R_386_8 =            22;
936 enum R_386_PC8 =          23;
937 enum R_386_TLS_GD_32 =    24;
938 enum R_386_TLS_GD_PUSH =  25;
939 enum R_386_TLS_GD_CALL =  26;
940 enum R_386_TLS_GD_POP =   27;
941 enum R_386_TLS_LDM_32 =   28;
942 enum R_386_TLS_LDM_PUSH = 29;
943 enum R_386_TLS_LDM_CALL = 30;
944 enum R_386_TLS_LDM_POP =  31;
945 enum R_386_TLS_LDO_32 =   32;
946 enum R_386_TLS_IE_32 =    33;
947 enum R_386_TLS_LE_32 =    34;
948 enum R_386_TLS_DTPMOD32 = 35;
949 enum R_386_TLS_DTPOFF32 = 36;
950 enum R_386_TLS_TPOFF32 =  37;
951 enum R_386_SIZE32 =       38;
952 enum R_386_TLS_GOTDESC =  39;
953 enum R_386_TLS_DESC_CALL = 40;
954 enum R_386_TLS_DESC =     41;
955 enum R_386_IRELATIVE =    42;
956 enum R_386_NUM =          43;
957 
958 enum STT_SPARC_REGISTER =      13;
959 
960 enum EF_SPARCV9_MM =           3;
961 enum EF_SPARCV9_TSO =          0;
962 enum EF_SPARCV9_PSO =          1;
963 enum EF_SPARCV9_RMO =          2;
964 enum EF_SPARC_LEDATA =         0x800000;
965 enum EF_SPARC_EXT_MASK =       0xFFFF00;
966 enum EF_SPARC_32PLUS =         0x000100;
967 enum EF_SPARC_SUN_US1 =        0x000200;
968 enum EF_SPARC_HAL_R1 =         0x000400;
969 enum EF_SPARC_SUN_US3 =        0x000800;
970 
971 enum R_SPARC_NONE =            0;
972 enum R_SPARC_8 =               1;
973 enum R_SPARC_16 =              2;
974 enum R_SPARC_32 =              3;
975 enum R_SPARC_DISP8 =           4;
976 enum R_SPARC_DISP16 =          5;
977 enum R_SPARC_DISP32 =          6;
978 enum R_SPARC_WDISP30 =         7;
979 enum R_SPARC_WDISP22 =         8;
980 enum R_SPARC_HI22 =            9;
981 enum R_SPARC_22 =              10;
982 enum R_SPARC_13 =              11;
983 enum R_SPARC_LO10 =            12;
984 enum R_SPARC_GOT10 =           13;
985 enum R_SPARC_GOT13 =           14;
986 enum R_SPARC_GOT22 =           15;
987 enum R_SPARC_PC10 =            16;
988 enum R_SPARC_PC22 =            17;
989 enum R_SPARC_WPLT30 =          18;
990 enum R_SPARC_COPY =            19;
991 enum R_SPARC_GLOB_DAT =        20;
992 enum R_SPARC_JMP_SLOT =        21;
993 enum R_SPARC_RELATIVE =        22;
994 enum R_SPARC_UA32 =            23;
995 
996 enum R_SPARC_PLT32 =           24;
997 enum R_SPARC_HIPLT22 =         25;
998 enum R_SPARC_LOPLT10 =         26;
999 enum R_SPARC_PCPLT32 =         27;
1000 enum R_SPARC_PCPLT22 =         28;
1001 enum R_SPARC_PCPLT10 =         29;
1002 enum R_SPARC_10 =              30;
1003 enum R_SPARC_11 =              31;
1004 enum R_SPARC_64 =              32;
1005 enum R_SPARC_OLO10 =           33;
1006 enum R_SPARC_HH22 =            34;
1007 enum R_SPARC_HM10 =            35;
1008 enum R_SPARC_LM22 =            36;
1009 enum R_SPARC_PC_HH22 =         37;
1010 enum R_SPARC_PC_HM10 =         38;
1011 enum R_SPARC_PC_LM22 =         39;
1012 enum R_SPARC_WDISP16 =         40;
1013 enum R_SPARC_WDISP19 =         41;
1014 enum R_SPARC_GLOB_JMP =        42;
1015 enum R_SPARC_7 =               43;
1016 enum R_SPARC_5 =               44;
1017 enum R_SPARC_6 =               45;
1018 enum R_SPARC_DISP64 =          46;
1019 enum R_SPARC_PLT64 =           47;
1020 enum R_SPARC_HIX22 =           48;
1021 enum R_SPARC_LOX10 =           49;
1022 enum R_SPARC_H44 =             50;
1023 enum R_SPARC_M44 =             51;
1024 enum R_SPARC_L44 =             52;
1025 enum R_SPARC_REGISTER =        53;
1026 enum R_SPARC_UA64 =            54;
1027 enum R_SPARC_UA16 =            55;
1028 enum R_SPARC_TLS_GD_HI22 =     56;
1029 enum R_SPARC_TLS_GD_LO10 =     57;
1030 enum R_SPARC_TLS_GD_ADD =      58;
1031 enum R_SPARC_TLS_GD_CALL =     59;
1032 enum R_SPARC_TLS_LDM_HI22 =    60;
1033 enum R_SPARC_TLS_LDM_LO10 =    61;
1034 enum R_SPARC_TLS_LDM_ADD =     62;
1035 enum R_SPARC_TLS_LDM_CALL =    63;
1036 enum R_SPARC_TLS_LDO_HIX22 =   64;
1037 enum R_SPARC_TLS_LDO_LOX10 =   65;
1038 enum R_SPARC_TLS_LDO_ADD =     66;
1039 enum R_SPARC_TLS_IE_HI22 =     67;
1040 enum R_SPARC_TLS_IE_LO10 =     68;
1041 enum R_SPARC_TLS_IE_LD =       69;
1042 enum R_SPARC_TLS_IE_LDX =      70;
1043 enum R_SPARC_TLS_IE_ADD =      71;
1044 enum R_SPARC_TLS_LE_HIX22 =    72;
1045 enum R_SPARC_TLS_LE_LOX10 =    73;
1046 enum R_SPARC_TLS_DTPMOD32 =    74;
1047 enum R_SPARC_TLS_DTPMOD64 =    75;
1048 enum R_SPARC_TLS_DTPOFF32 =    76;
1049 enum R_SPARC_TLS_DTPOFF64 =    77;
1050 enum R_SPARC_TLS_TPOFF32 =     78;
1051 enum R_SPARC_TLS_TPOFF64 =     79;
1052 enum R_SPARC_GOTDATA_HIX22 =   80;
1053 enum R_SPARC_GOTDATA_LOX10 =   81;
1054 enum R_SPARC_GOTDATA_OP_HIX22 =        82;
1055 enum R_SPARC_GOTDATA_OP_LOX10 =        83;
1056 enum R_SPARC_GOTDATA_OP =      84;
1057 enum R_SPARC_H34 =             85;
1058 enum R_SPARC_SIZE32 =          86;
1059 enum R_SPARC_SIZE64 =          87;
1060 enum R_SPARC_WDISP10 =         88;
1061 enum R_SPARC_JMP_IREL =        248;
1062 enum R_SPARC_IRELATIVE =       249;
1063 enum R_SPARC_GNU_VTINHERIT =   250;
1064 enum R_SPARC_GNU_VTENTRY =     251;
1065 enum R_SPARC_REV32 =           252;
1066 enum R_SPARC_NUM =             253;
1067 
1068 enum DT_SPARC_REGISTER =       0x70000001;
1069 enum DT_SPARC_NUM =            2;
1070 
1071 enum EF_MIPS_NOREORDER =       1;
1072 enum EF_MIPS_PIC =             2;
1073 enum EF_MIPS_CPIC =            4;
1074 enum EF_MIPS_XGOT =            8;
1075 enum EF_MIPS_64BIT_WHIRL =     16;
1076 enum EF_MIPS_ABI2 =            32;
1077 enum EF_MIPS_ABI_ON32 =        64;
1078 enum EF_MIPS_ARCH =            0xf0000000;
1079 
1080 enum EF_MIPS_ARCH_1 =          0x00000000;
1081 enum EF_MIPS_ARCH_2 =          0x10000000;
1082 enum EF_MIPS_ARCH_3 =          0x20000000;
1083 enum EF_MIPS_ARCH_4 =          0x30000000;
1084 enum EF_MIPS_ARCH_5 =          0x40000000;
1085 enum EF_MIPS_ARCH_32 =         0x50000000;
1086 enum EF_MIPS_ARCH_64 =         0x60000000;
1087 enum EF_MIPS_ARCH_32R2 =       0x70000000;
1088 enum EF_MIPS_ARCH_64R2 =       0x80000000;
1089 
1090 enum E_MIPS_ARCH_1 =           EF_MIPS_ARCH_1;
1091 enum E_MIPS_ARCH_2 =           EF_MIPS_ARCH_2;
1092 enum E_MIPS_ARCH_3 =           EF_MIPS_ARCH_3;
1093 enum E_MIPS_ARCH_4 =           EF_MIPS_ARCH_4;
1094 enum E_MIPS_ARCH_5 =           EF_MIPS_ARCH_5;
1095 enum E_MIPS_ARCH_32 =          EF_MIPS_ARCH_32;
1096 enum E_MIPS_ARCH_64 =          EF_MIPS_ARCH_64;
1097 
1098 enum SHN_MIPS_ACOMMON =        0xff00;
1099 enum SHN_MIPS_TEXT =           0xff01;
1100 enum SHN_MIPS_DATA =           0xff02;
1101 enum SHN_MIPS_SCOMMON =        0xff03;
1102 enum SHN_MIPS_SUNDEFINED =     0xff04;
1103 
1104 enum SHT_MIPS_LIBLIST =        0x70000000;
1105 enum SHT_MIPS_MSYM =           0x70000001;
1106 enum SHT_MIPS_CONFLICT =       0x70000002;
1107 enum SHT_MIPS_GPTAB =          0x70000003;
1108 enum SHT_MIPS_UCODE =          0x70000004;
1109 enum SHT_MIPS_DEBUG =          0x70000005;
1110 enum SHT_MIPS_REGINFO =        0x70000006;
1111 enum SHT_MIPS_PACKAGE =        0x70000007;
1112 enum SHT_MIPS_PACKSYM =        0x70000008;
1113 enum SHT_MIPS_RELD =           0x70000009;
1114 enum SHT_MIPS_IFACE =          0x7000000b;
1115 enum SHT_MIPS_CONTENT =        0x7000000c;
1116 enum SHT_MIPS_OPTIONS =        0x7000000d;
1117 enum SHT_MIPS_SHDR =           0x70000010;
1118 enum SHT_MIPS_FDESC =          0x70000011;
1119 enum SHT_MIPS_EXTSYM =         0x70000012;
1120 enum SHT_MIPS_DENSE =          0x70000013;
1121 enum SHT_MIPS_PDESC =          0x70000014;
1122 enum SHT_MIPS_LOCSYM =         0x70000015;
1123 enum SHT_MIPS_AUXSYM =         0x70000016;
1124 enum SHT_MIPS_OPTSYM =         0x70000017;
1125 enum SHT_MIPS_LOCSTR =         0x70000018;
1126 enum SHT_MIPS_LINE =           0x70000019;
1127 enum SHT_MIPS_RFDESC =         0x7000001a;
1128 enum SHT_MIPS_DELTASYM =       0x7000001b;
1129 enum SHT_MIPS_DELTAINST =      0x7000001c;
1130 enum SHT_MIPS_DELTACLASS =     0x7000001d;
1131 enum SHT_MIPS_DWARF =          0x7000001e;
1132 enum SHT_MIPS_DELTADECL =      0x7000001f;
1133 enum SHT_MIPS_SYMBOL_LIB =     0x70000020;
1134 enum SHT_MIPS_EVENTS =         0x70000021;
1135 enum SHT_MIPS_TRANSLATE =      0x70000022;
1136 enum SHT_MIPS_PIXIE =          0x70000023;
1137 enum SHT_MIPS_XLATE =          0x70000024;
1138 enum SHT_MIPS_XLATE_DEBUG =    0x70000025;
1139 enum SHT_MIPS_WHIRL =          0x70000026;
1140 enum SHT_MIPS_EH_REGION =      0x70000027;
1141 enum SHT_MIPS_XLATE_OLD =      0x70000028;
1142 enum SHT_MIPS_PDR_EXCEPTION =  0x70000029;
1143 
1144 enum SHF_MIPS_GPREL =          0x10000000;
1145 enum SHF_MIPS_MERGE =          0x20000000;
1146 enum SHF_MIPS_ADDR =           0x40000000;
1147 enum SHF_MIPS_STRINGS =        0x80000000;
1148 enum SHF_MIPS_NOSTRIP =        0x08000000;
1149 enum SHF_MIPS_LOCAL =          0x04000000;
1150 enum SHF_MIPS_NAMES =          0x02000000;
1151 enum SHF_MIPS_NODUPE =         0x01000000;
1152 enum STO_MIPS_DEFAULT =                0x0;
1153 enum STO_MIPS_INTERNAL =               0x1;
1154 enum STO_MIPS_HIDDEN =                 0x2;
1155 enum STO_MIPS_PROTECTED =              0x3;
1156 enum STO_MIPS_PLT =                    0x8;
1157 enum STO_MIPS_SC_ALIGN_UNUSED =        0xff;
1158 enum STB_MIPS_SPLIT_COMMON =           13;
1159 
1160 union Elf32_gptab
1161 {
1162     struct _gt_header
1163     {
1164         Elf32_Word gt_current_g_value;
1165         Elf32_Word gt_unused;
1166     } _gt_header gt_header;
1167     struct _gt_entry
1168     {
1169         Elf32_Word gt_g_value;
1170         Elf32_Word gt_bytes;
1171     } _gt_entry gt_entry;
1172 }
1173 
1174 struct Elf32_RegInfo
1175 {
1176     Elf32_Word ri_gprmask;
1177     Elf32_Word[4] ri_cprmask;
1178     Elf32_Sword ri_gp_value;
1179 }
1180 
1181 struct Elf_Options
1182 {
1183     ubyte kind;
1184     ubyte size;
1185     Elf32_Section section;
1186     Elf32_Word info;
1187 }
1188 
1189 enum ODK_NULL =        0;
1190 enum ODK_REGINFO =     1;
1191 enum ODK_EXCEPTIONS =  2;
1192 enum ODK_PAD =         3;
1193 enum ODK_HWPATCH =     4;
1194 enum ODK_FILL =        5;
1195 enum ODK_TAGS =        6;
1196 enum ODK_HWAND =       7;
1197 enum ODK_HWOR =        8;
1198 
1199 enum OEX_FPU_MIN =     0x1f;
1200 enum OEX_FPU_MAX =     0x1f00;
1201 enum OEX_PAGE0 =       0x10000;
1202 enum OEX_SMM =         0x20000;
1203 enum OEX_FPDBUG =      0x40000;
1204 enum OEX_PRECISEFP =   OEX_FPDBUG;
1205 enum OEX_DISMISS =     0x80000;
1206 
1207 enum OEX_FPU_INVAL =   0x10;
1208 enum OEX_FPU_DIV0 =    0x08;
1209 enum OEX_FPU_OFLO =    0x04;
1210 enum OEX_FPU_UFLO =    0x02;
1211 enum OEX_FPU_INEX =    0x01;
1212 
1213 enum OHW_R4KEOP =      0x1;
1214 enum OHW_R8KPFETCH =   0x2;
1215 enum OHW_R5KEOP =      0x4;
1216 enum OHW_R5KCVTL =     0x8;
1217 
1218 enum OPAD_PREFIX =     0x1;
1219 enum OPAD_POSTFIX =    0x2;
1220 enum OPAD_SYMBOL =     0x4;
1221 
1222 struct Elf_Options_Hw
1223 {
1224     Elf32_Word hwp_flags1;
1225     Elf32_Word hwp_flags2;
1226 }
1227 
1228 enum OHWA0_R4KEOP_CHECKED =    0x00000001;
1229 enum OHWA1_R4KEOP_CLEAN =      0x00000002;
1230 
1231 enum R_MIPS_NONE =             0;
1232 enum R_MIPS_16 =               1;
1233 enum R_MIPS_32 =               2;
1234 enum R_MIPS_REL32 =            3;
1235 enum R_MIPS_26 =               4;
1236 enum R_MIPS_HI16 =             5;
1237 enum R_MIPS_LO16 =             6;
1238 enum R_MIPS_GPREL16 =          7;
1239 enum R_MIPS_LITERAL =          8;
1240 enum R_MIPS_GOT16 =            9;
1241 enum R_MIPS_PC16 =             10;
1242 enum R_MIPS_CALL16 =           11;
1243 enum R_MIPS_GPREL32 =          12;
1244 
1245 enum R_MIPS_SHIFT5 =           16;
1246 enum R_MIPS_SHIFT6 =           17;
1247 enum R_MIPS_64 =               18;
1248 enum R_MIPS_GOT_DISP =         19;
1249 enum R_MIPS_GOT_PAGE =         20;
1250 enum R_MIPS_GOT_OFST =         21;
1251 enum R_MIPS_GOT_HI16 =         22;
1252 enum R_MIPS_GOT_LO16 =         23;
1253 enum R_MIPS_SUB =              24;
1254 enum R_MIPS_INSERT_A =         25;
1255 enum R_MIPS_INSERT_B =         26;
1256 enum R_MIPS_DELETE =           27;
1257 enum R_MIPS_HIGHER =           28;
1258 enum R_MIPS_HIGHEST =          29;
1259 enum R_MIPS_CALL_HI16 =        30;
1260 enum R_MIPS_CALL_LO16 =        31;
1261 enum R_MIPS_SCN_DISP =         32;
1262 enum R_MIPS_REL16 =            33;
1263 enum R_MIPS_ADD_IMMEDIATE =    34;
1264 enum R_MIPS_PJUMP =            35;
1265 enum R_MIPS_RELGOT =           36;
1266 enum R_MIPS_JALR =             37;
1267 enum R_MIPS_TLS_DTPMOD32 =     38;
1268 enum R_MIPS_TLS_DTPREL32 =     39;
1269 enum R_MIPS_TLS_DTPMOD64 =     40;
1270 enum R_MIPS_TLS_DTPREL64 =     41;
1271 enum R_MIPS_TLS_GD =           42;
1272 enum R_MIPS_TLS_LDM =          43;
1273 enum R_MIPS_TLS_DTPREL_HI16 =  44;
1274 enum R_MIPS_TLS_DTPREL_LO16 =  45;
1275 enum R_MIPS_TLS_GOTTPREL =     46;
1276 enum R_MIPS_TLS_TPREL32 =      47;
1277 enum R_MIPS_TLS_TPREL64 =      48;
1278 enum R_MIPS_TLS_TPREL_HI16 =   49;
1279 enum R_MIPS_TLS_TPREL_LO16 =   50;
1280 enum R_MIPS_GLOB_DAT =         51;
1281 enum R_MIPS_COPY =             126;
1282 enum R_MIPS_JUMP_SLOT =        127;
1283 enum R_MIPS_NUM =              128;
1284 
1285 enum PT_MIPS_REGINFO = 0x70000000;
1286 enum PT_MIPS_RTPROC =  0x70000001;
1287 enum PT_MIPS_OPTIONS = 0x70000002;
1288 
1289 enum PF_MIPS_LOCAL =   0x10000000;
1290 
1291 enum DT_MIPS_RLD_VERSION =  0x70000001;
1292 enum DT_MIPS_TIME_STAMP =   0x70000002;
1293 enum DT_MIPS_ICHECKSUM =    0x70000003;
1294 enum DT_MIPS_IVERSION =     0x70000004;
1295 enum DT_MIPS_FLAGS =        0x70000005;
1296 enum DT_MIPS_BASE_ADDRESS = 0x70000006;
1297 enum DT_MIPS_MSYM =         0x70000007;
1298 enum DT_MIPS_CONFLICT =     0x70000008;
1299 enum DT_MIPS_LIBLIST =      0x70000009;
1300 enum DT_MIPS_LOCAL_GOTNO =  0x7000000a;
1301 enum DT_MIPS_CONFLICTNO =   0x7000000b;
1302 enum DT_MIPS_LIBLISTNO =    0x70000010;
1303 enum DT_MIPS_SYMTABNO =     0x70000011;
1304 enum DT_MIPS_UNREFEXTNO =   0x70000012;
1305 enum DT_MIPS_GOTSYM =       0x70000013;
1306 enum DT_MIPS_HIPAGENO =     0x70000014;
1307 enum DT_MIPS_RLD_MAP =      0x70000016;
1308 enum DT_MIPS_DELTA_CLASS =  0x70000017;
1309 enum DT_MIPS_DELTA_CLASS_NO =    0x70000018;
1310 enum DT_MIPS_DELTA_INSTANCE =    0x70000019;
1311 enum DT_MIPS_DELTA_INSTANCE_NO = 0x7000001a;
1312 enum DT_MIPS_DELTA_RELOC =  0x7000001b;
1313 enum DT_MIPS_DELTA_RELOC_NO = 0x7000001c;
1314 enum DT_MIPS_DELTA_SYM =    0x7000001d;
1315 enum DT_MIPS_DELTA_SYM_NO = 0x7000001e;
1316 enum DT_MIPS_DELTA_CLASSSYM = 0x70000020;
1317 enum DT_MIPS_DELTA_CLASSSYM_NO = 0x70000021;
1318 enum DT_MIPS_CXX_FLAGS =    0x70000022;
1319 enum DT_MIPS_PIXIE_INIT =   0x70000023;
1320 enum DT_MIPS_SYMBOL_LIB =   0x70000024;
1321 enum DT_MIPS_LOCALPAGE_GOTIDX = 0x70000025;
1322 enum DT_MIPS_LOCAL_GOTIDX = 0x70000026;
1323 enum DT_MIPS_HIDDEN_GOTIDX = 0x70000027;
1324 enum DT_MIPS_PROTECTED_GOTIDX = 0x70000028;
1325 enum DT_MIPS_OPTIONS =      0x70000029;
1326 enum DT_MIPS_INTERFACE =    0x7000002a;
1327 enum DT_MIPS_DYNSTR_ALIGN = 0x7000002b;
1328 enum DT_MIPS_INTERFACE_SIZE = 0x7000002c;
1329 enum DT_MIPS_RLD_TEXT_RESOLVE_ADDR = 0x7000002d;
1330 enum DT_MIPS_PERF_SUFFIX =  0x7000002e;
1331 enum DT_MIPS_COMPACT_SIZE = 0x7000002f;
1332 enum DT_MIPS_GP_VALUE =     0x70000030;
1333 enum DT_MIPS_AUX_DYNAMIC =  0x70000031;
1334 enum DT_MIPS_PLTGOT =       0x70000032;
1335 enum DT_MIPS_RWPLT =        0x70000034;
1336 enum DT_MIPS_NUM =          0x35;
1337 
1338 enum RHF_NONE =                   0;
1339 enum RHF_QUICKSTART =             (1 << 0);
1340 enum RHF_NOTPOT =                 (1 << 1);
1341 enum RHF_NO_LIBRARY_REPLACEMENT = (1 << 2);
1342 enum RHF_NO_MOVE =                (1 << 3);
1343 enum RHF_SGI_ONLY =               (1 << 4);
1344 enum RHF_GUARANTEE_INIT =         (1 << 5);
1345 enum RHF_DELTA_C_PLUS_PLUS =      (1 << 6);
1346 enum RHF_GUARANTEE_START_INIT =   (1 << 7);
1347 enum RHF_PIXIE =                  (1 << 8);
1348 enum RHF_DEFAULT_DELAY_LOAD =     (1 << 9);
1349 enum RHF_REQUICKSTART =           (1 << 10);
1350 enum RHF_REQUICKSTARTED =         (1 << 11);
1351 enum RHF_CORD =                   (1 << 12);
1352 enum RHF_NO_UNRES_UNDEF =         (1 << 13);
1353 enum RHF_RLD_ORDER_SAFE =         (1 << 14);
1354 
1355 struct Elf32_Lib
1356 {
1357     Elf32_Word l_name;
1358     Elf32_Word l_time_stamp;
1359     Elf32_Word l_checksum;
1360     Elf32_Word l_version;
1361     Elf32_Word l_flags;
1362 }
1363 
1364 struct Elf64_Lib
1365 {
1366     Elf64_Word l_name;
1367     Elf64_Word l_time_stamp;
1368     Elf64_Word l_checksum;
1369     Elf64_Word l_version;
1370     Elf64_Word l_flags;
1371 }
1372 
1373 enum LL_NONE =           0;
1374 enum LL_EXACT_MATCH =    (1 << 0);
1375 enum LL_IGNORE_INT_VER = (1 << 1);
1376 enum LL_REQUIRE_MINOR =  (1 << 2);
1377 enum LL_EXPORTS =        (1 << 3);
1378 enum LL_DELAY_LOAD =     (1 << 4);
1379 enum LL_DELTA =          (1 << 5);
1380 
1381 alias Elf32_Addr Elf32_Conflict;
1382 
1383 enum EF_PARISC_TRAPNIL =       0x00010000;
1384 enum EF_PARISC_EXT =           0x00020000;
1385 enum EF_PARISC_LSB =           0x00040000;
1386 enum EF_PARISC_WIDE =          0x00080000;
1387 enum EF_PARISC_NO_KABP =       0x00100000;
1388 enum EF_PARISC_LAZYSWAP =      0x00400000;
1389 enum EF_PARISC_ARCH =          0x0000ffff;
1390 
1391 enum EFA_PARISC_1_0 =              0x020b;
1392 enum EFA_PARISC_1_1 =              0x0210;
1393 enum EFA_PARISC_2_0 =              0x0214;
1394 
1395 enum SHN_PARISC_ANSI_COMMON =  0xff00;
1396 enum SHN_PARISC_HUGE_COMMON =  0xff01;
1397 
1398 enum SHT_PARISC_EXT =          0x70000000;
1399 enum SHT_PARISC_UNWIND =       0x70000001;
1400 enum SHT_PARISC_DOC =          0x70000002;
1401 
1402 enum SHF_PARISC_SHORT =        0x20000000;
1403 enum SHF_PARISC_HUGE =         0x40000000;
1404 enum SHF_PARISC_SBP =          0x80000000;
1405 
1406 enum STT_PARISC_MILLICODE =    13;
1407 
1408 enum STT_HP_OPAQUE =           (STT_LOOS + 0x1);
1409 enum STT_HP_STUB =             (STT_LOOS + 0x2);
1410 
1411 enum R_PARISC_NONE =           0;
1412 enum R_PARISC_DIR32 =          1;
1413 enum R_PARISC_DIR21L =         2;
1414 enum R_PARISC_DIR17R =         3;
1415 enum R_PARISC_DIR17F =         4;
1416 enum R_PARISC_DIR14R =         6;
1417 enum R_PARISC_PCREL32 =        9;
1418 enum R_PARISC_PCREL21L =       10;
1419 enum R_PARISC_PCREL17R =       11;
1420 enum R_PARISC_PCREL17F =       12;
1421 enum R_PARISC_PCREL14R =       14;
1422 enum R_PARISC_DPREL21L =       18;
1423 enum R_PARISC_DPREL14R =       22;
1424 enum R_PARISC_GPREL21L =       26;
1425 enum R_PARISC_GPREL14R =       30;
1426 enum R_PARISC_LTOFF21L =       34;
1427 enum R_PARISC_LTOFF14R =       38;
1428 enum R_PARISC_SECREL32 =       41;
1429 enum R_PARISC_SEGBASE =        48;
1430 enum R_PARISC_SEGREL32 =       49;
1431 enum R_PARISC_PLTOFF21L =      50;
1432 enum R_PARISC_PLTOFF14R =      54;
1433 enum R_PARISC_LTOFF_FPTR32 =   57;
1434 enum R_PARISC_LTOFF_FPTR21L =  58;
1435 enum R_PARISC_LTOFF_FPTR14R =  62;
1436 enum R_PARISC_FPTR64 =         64;
1437 enum R_PARISC_PLABEL32 =       65;
1438 enum R_PARISC_PLABEL21L =      66;
1439 enum R_PARISC_PLABEL14R =      70;
1440 enum R_PARISC_PCREL64 =        72;
1441 enum R_PARISC_PCREL22F =       74;
1442 enum R_PARISC_PCREL14WR =      75;
1443 enum R_PARISC_PCREL14DR =      76;
1444 enum R_PARISC_PCREL16F =       77;
1445 enum R_PARISC_PCREL16WF =      78;
1446 enum R_PARISC_PCREL16DF =      79;
1447 enum R_PARISC_DIR64 =          80;
1448 enum R_PARISC_DIR14WR =        83;
1449 enum R_PARISC_DIR14DR =        84;
1450 enum R_PARISC_DIR16F =         85;
1451 enum R_PARISC_DIR16WF =        86;
1452 enum R_PARISC_DIR16DF =        87;
1453 enum R_PARISC_GPREL64 =        88;
1454 enum R_PARISC_GPREL14WR =      91;
1455 enum R_PARISC_GPREL14DR =      92;
1456 enum R_PARISC_GPREL16F =       93;
1457 enum R_PARISC_GPREL16WF =      94;
1458 enum R_PARISC_GPREL16DF =      95;
1459 enum R_PARISC_LTOFF64 =        96;
1460 enum R_PARISC_LTOFF14WR =      99;
1461 enum R_PARISC_LTOFF14DR =      100;
1462 enum R_PARISC_LTOFF16F =       101;
1463 enum R_PARISC_LTOFF16WF =      102;
1464 enum R_PARISC_LTOFF16DF =      103;
1465 enum R_PARISC_SECREL64 =       104;
1466 enum R_PARISC_SEGREL64 =       112;
1467 enum R_PARISC_PLTOFF14WR =     115;
1468 enum R_PARISC_PLTOFF14DR =     116;
1469 enum R_PARISC_PLTOFF16F =      117;
1470 enum R_PARISC_PLTOFF16WF =     118;
1471 enum R_PARISC_PLTOFF16DF =     119;
1472 enum R_PARISC_LTOFF_FPTR64 =   120;
1473 enum R_PARISC_LTOFF_FPTR14WR = 123;
1474 enum R_PARISC_LTOFF_FPTR14DR = 124;
1475 enum R_PARISC_LTOFF_FPTR16F =  125;
1476 enum R_PARISC_LTOFF_FPTR16WF = 126;
1477 enum R_PARISC_LTOFF_FPTR16DF = 127;
1478 enum R_PARISC_LORESERVE =      128;
1479 enum R_PARISC_COPY =           128;
1480 enum R_PARISC_IPLT =           129;
1481 enum R_PARISC_EPLT =           130;
1482 enum R_PARISC_TPREL32 =        153;
1483 enum R_PARISC_TPREL21L =       154;
1484 enum R_PARISC_TPREL14R =       158;
1485 enum R_PARISC_LTOFF_TP21L =    162;
1486 enum R_PARISC_LTOFF_TP14R =    166;
1487 enum R_PARISC_LTOFF_TP14F =    167;
1488 enum R_PARISC_TPREL64 =        216;
1489 enum R_PARISC_TPREL14WR =      219;
1490 enum R_PARISC_TPREL14DR =      220;
1491 enum R_PARISC_TPREL16F =       221;
1492 enum R_PARISC_TPREL16WF =      222;
1493 enum R_PARISC_TPREL16DF =      223;
1494 enum R_PARISC_LTOFF_TP64 =     224;
1495 enum R_PARISC_LTOFF_TP14WR =   227;
1496 enum R_PARISC_LTOFF_TP14DR =   228;
1497 enum R_PARISC_LTOFF_TP16F =    229;
1498 enum R_PARISC_LTOFF_TP16WF =   230;
1499 enum R_PARISC_LTOFF_TP16DF =   231;
1500 enum R_PARISC_GNU_VTENTRY =    232;
1501 enum R_PARISC_GNU_VTINHERIT =  233;
1502 enum R_PARISC_TLS_GD21L =      234;
1503 enum R_PARISC_TLS_GD14R =      235;
1504 enum R_PARISC_TLS_GDCALL =     236;
1505 enum R_PARISC_TLS_LDM21L =     237;
1506 enum R_PARISC_TLS_LDM14R =     238;
1507 enum R_PARISC_TLS_LDMCALL =    239;
1508 enum R_PARISC_TLS_LDO21L =     240;
1509 enum R_PARISC_TLS_LDO14R =     241;
1510 enum R_PARISC_TLS_DTPMOD32 =   242;
1511 enum R_PARISC_TLS_DTPMOD64 =   243;
1512 enum R_PARISC_TLS_DTPOFF32 =   244;
1513 enum R_PARISC_TLS_DTPOFF64 =   245;
1514 enum R_PARISC_TLS_LE21L =      R_PARISC_TPREL21L;
1515 enum R_PARISC_TLS_LE14R =      R_PARISC_TPREL14R;
1516 enum R_PARISC_TLS_IE21L =      R_PARISC_LTOFF_TP21L;
1517 enum R_PARISC_TLS_IE14R =      R_PARISC_LTOFF_TP14R;
1518 enum R_PARISC_TLS_TPREL32 =    R_PARISC_TPREL32;
1519 enum R_PARISC_TLS_TPREL64 =    R_PARISC_TPREL64;
1520 enum R_PARISC_HIRESERVE =      255;
1521 
1522 enum PT_HP_TLS =               (PT_LOOS + 0x0);
1523 enum PT_HP_CORE_NONE =         (PT_LOOS + 0x1);
1524 enum PT_HP_CORE_VERSION =      (PT_LOOS + 0x2);
1525 enum PT_HP_CORE_KERNEL =       (PT_LOOS + 0x3);
1526 enum PT_HP_CORE_COMM =         (PT_LOOS + 0x4);
1527 enum PT_HP_CORE_PROC =         (PT_LOOS + 0x5);
1528 enum PT_HP_CORE_LOADABLE =     (PT_LOOS + 0x6);
1529 enum PT_HP_CORE_STACK =        (PT_LOOS + 0x7);
1530 enum PT_HP_CORE_SHM =          (PT_LOOS + 0x8);
1531 enum PT_HP_CORE_MMF =          (PT_LOOS + 0x9);
1532 enum PT_HP_PARALLEL =          (PT_LOOS + 0x10);
1533 enum PT_HP_FASTBIND =          (PT_LOOS + 0x11);
1534 enum PT_HP_OPT_ANNOT =         (PT_LOOS + 0x12);
1535 enum PT_HP_HSL_ANNOT =         (PT_LOOS + 0x13);
1536 enum PT_HP_STACK =             (PT_LOOS + 0x14);
1537 
1538 enum PT_PARISC_ARCHEXT =       0x70000000;
1539 enum PT_PARISC_UNWIND =        0x70000001;
1540 
1541 enum PF_PARISC_SBP =           0x08000000;
1542 
1543 enum PF_HP_PAGE_SIZE =         0x00100000;
1544 enum PF_HP_FAR_SHARED =        0x00200000;
1545 enum PF_HP_NEAR_SHARED =       0x00400000;
1546 enum PF_HP_CODE =              0x01000000;
1547 enum PF_HP_MODIFY =            0x02000000;
1548 enum PF_HP_LAZYSWAP =          0x04000000;
1549 enum PF_HP_SBP =               0x08000000;
1550 
1551 enum EF_ALPHA_32BIT =          1;
1552 enum EF_ALPHA_CANRELAX =       2;
1553 enum SHT_ALPHA_DEBUG =         0x70000001;
1554 enum SHT_ALPHA_REGINFO =       0x70000002;
1555 
1556 enum SHF_ALPHA_GPREL =         0x10000000;
1557 enum STO_ALPHA_NOPV =          0x80;
1558 enum STO_ALPHA_STD_GPLOAD =    0x88;
1559 
1560 enum R_ALPHA_NONE =            0;
1561 enum R_ALPHA_REFLONG =         1;
1562 enum R_ALPHA_REFQUAD =         2;
1563 enum R_ALPHA_GPREL32 =         3;
1564 enum R_ALPHA_LITERAL =         4;
1565 enum R_ALPHA_LITUSE =          5;
1566 enum R_ALPHA_GPDISP =          6;
1567 enum R_ALPHA_BRADDR =          7;
1568 enum R_ALPHA_HINT =            8;
1569 enum R_ALPHA_SREL16 =          9;
1570 enum R_ALPHA_SREL32 =          10;
1571 enum R_ALPHA_SREL64 =          11;
1572 enum R_ALPHA_GPRELHIGH =       17;
1573 enum R_ALPHA_GPRELLOW =        18;
1574 enum R_ALPHA_GPREL16 =         19;
1575 enum R_ALPHA_COPY =            24;
1576 enum R_ALPHA_GLOB_DAT =        25;
1577 enum R_ALPHA_JMP_SLOT =        26;
1578 enum R_ALPHA_RELATIVE =        27;
1579 enum R_ALPHA_TLS_GD_HI =       28;
1580 enum R_ALPHA_TLSGD =           29;
1581 enum R_ALPHA_TLS_LDM =         30;
1582 enum R_ALPHA_DTPMOD64 =        31;
1583 enum R_ALPHA_GOTDTPREL =       32;
1584 enum R_ALPHA_DTPREL64 =        33;
1585 enum R_ALPHA_DTPRELHI =        34;
1586 enum R_ALPHA_DTPRELLO =        35;
1587 enum R_ALPHA_DTPREL16 =        36;
1588 enum R_ALPHA_GOTTPREL =        37;
1589 enum R_ALPHA_TPREL64 =         38;
1590 enum R_ALPHA_TPRELHI =         39;
1591 enum R_ALPHA_TPRELLO =         40;
1592 enum R_ALPHA_TPREL16 =         41;
1593 enum R_ALPHA_NUM =             46;
1594 enum LITUSE_ALPHA_ADDR =       0;
1595 enum LITUSE_ALPHA_BASE =       1;
1596 enum LITUSE_ALPHA_BYTOFF =     2;
1597 enum LITUSE_ALPHA_JSR =        3;
1598 enum LITUSE_ALPHA_TLS_GD =     4;
1599 enum LITUSE_ALPHA_TLS_LDM =    5;
1600 enum DT_ALPHA_PLTRO =          (DT_LOPROC + 0);
1601 enum DT_ALPHA_NUM =            1;
1602 enum EF_PPC_EMB =              0x80000000;
1603 enum EF_PPC_RELOCATABLE =      0x00010000;
1604 enum EF_PPC_RELOCATABLE_LIB =  0x00008000;
1605 enum R_PPC_NONE =              0;
1606 enum R_PPC_ADDR32 =            1;
1607 enum R_PPC_ADDR24 =            2;
1608 enum R_PPC_ADDR16 =            3;
1609 enum R_PPC_ADDR16_LO =         4;
1610 enum R_PPC_ADDR16_HI =         5;
1611 enum R_PPC_ADDR16_HA =         6;
1612 enum R_PPC_ADDR14 =            7;
1613 enum R_PPC_ADDR14_BRTAKEN =    8;
1614 enum R_PPC_ADDR14_BRNTAKEN =   9;
1615 enum R_PPC_REL24 =             10;
1616 enum R_PPC_REL14 =             11;
1617 enum R_PPC_REL14_BRTAKEN =     12;
1618 enum R_PPC_REL14_BRNTAKEN =    13;
1619 enum R_PPC_GOT16 =             14;
1620 enum R_PPC_GOT16_LO =          15;
1621 enum R_PPC_GOT16_HI =          16;
1622 enum R_PPC_GOT16_HA =          17;
1623 enum R_PPC_PLTREL24 =          18;
1624 enum R_PPC_COPY =              19;
1625 enum R_PPC_GLOB_DAT =          20;
1626 enum R_PPC_JMP_SLOT =          21;
1627 enum R_PPC_RELATIVE =          22;
1628 enum R_PPC_LOCAL24PC =         23;
1629 enum R_PPC_UADDR32 =           24;
1630 enum R_PPC_UADDR16 =           25;
1631 enum R_PPC_REL32 =             26;
1632 enum R_PPC_PLT32 =             27;
1633 enum R_PPC_PLTREL32 =          28;
1634 enum R_PPC_PLT16_LO =          29;
1635 enum R_PPC_PLT16_HI =          30;
1636 enum R_PPC_PLT16_HA =          31;
1637 enum R_PPC_SDAREL16 =          32;
1638 enum R_PPC_SECTOFF =           33;
1639 enum R_PPC_SECTOFF_LO =        34;
1640 enum R_PPC_SECTOFF_HI =        35;
1641 enum R_PPC_SECTOFF_HA =        36;
1642 enum R_PPC_TLS =               67;
1643 enum R_PPC_DTPMOD32 =          68;
1644 enum R_PPC_TPREL16 =           69;
1645 enum R_PPC_TPREL16_LO =        70;
1646 enum R_PPC_TPREL16_HI =        71;
1647 enum R_PPC_TPREL16_HA =        72;
1648 enum R_PPC_TPREL32 =           73;
1649 enum R_PPC_DTPREL16 =          74;
1650 enum R_PPC_DTPREL16_LO =       75;
1651 enum R_PPC_DTPREL16_HI =       76;
1652 enum R_PPC_DTPREL16_HA =       77;
1653 enum R_PPC_DTPREL32 =          78;
1654 enum R_PPC_GOT_TLSGD16 =       79;
1655 enum R_PPC_GOT_TLSGD16_LO =    80;
1656 enum R_PPC_GOT_TLSGD16_HI =    81;
1657 enum R_PPC_GOT_TLSGD16_HA =    82;
1658 enum R_PPC_GOT_TLSLD16 =       83;
1659 enum R_PPC_GOT_TLSLD16_LO =    84;
1660 enum R_PPC_GOT_TLSLD16_HI =    85;
1661 enum R_PPC_GOT_TLSLD16_HA =    86;
1662 enum R_PPC_GOT_TPREL16 =       87;
1663 enum R_PPC_GOT_TPREL16_LO =    88;
1664 enum R_PPC_GOT_TPREL16_HI =    89;
1665 enum R_PPC_GOT_TPREL16_HA =    90;
1666 enum R_PPC_GOT_DTPREL16 =      91;
1667 enum R_PPC_GOT_DTPREL16_LO =   92;
1668 enum R_PPC_GOT_DTPREL16_HI =   93;
1669 enum R_PPC_GOT_DTPREL16_HA =   94;
1670 enum R_PPC_EMB_NADDR32 =       101;
1671 enum R_PPC_EMB_NADDR16 =       102;
1672 enum R_PPC_EMB_NADDR16_LO =    103;
1673 enum R_PPC_EMB_NADDR16_HI =    104;
1674 enum R_PPC_EMB_NADDR16_HA =    105;
1675 enum R_PPC_EMB_SDAI16 =        106;
1676 enum R_PPC_EMB_SDA2I16 =       107;
1677 enum R_PPC_EMB_SDA2REL =       108;
1678 enum R_PPC_EMB_SDA21 =         109;
1679 enum R_PPC_EMB_MRKREF =        110;
1680 enum R_PPC_EMB_RELSEC16 =      111;
1681 enum R_PPC_EMB_RELST_LO =      112;
1682 enum R_PPC_EMB_RELST_HI =      113;
1683 enum R_PPC_EMB_RELST_HA =      114;
1684 enum R_PPC_EMB_BIT_FLD =       115;
1685 enum R_PPC_EMB_RELSDA =        116;
1686 enum R_PPC_DIAB_SDA21_LO =     180;
1687 enum R_PPC_DIAB_SDA21_HI =     181;
1688 enum R_PPC_DIAB_SDA21_HA =     182;
1689 enum R_PPC_DIAB_RELSDA_LO =    183;
1690 enum R_PPC_DIAB_RELSDA_HI =    184;
1691 enum R_PPC_DIAB_RELSDA_HA =    185;
1692 enum R_PPC_IRELATIVE =         248;
1693 enum R_PPC_REL16 =             249;
1694 enum R_PPC_REL16_LO =          250;
1695 enum R_PPC_REL16_HI =          251;
1696 enum R_PPC_REL16_HA =          252;
1697 enum R_PPC_TOC16 =             255;
1698 enum DT_PPC_GOT =              (DT_LOPROC + 0);
1699 enum DT_PPC_NUM =              1;
1700 enum R_PPC64_NONE =            R_PPC_NONE;
1701 enum R_PPC64_ADDR32 =          R_PPC_ADDR32;
1702 enum R_PPC64_ADDR24 =          R_PPC_ADDR24;
1703 enum R_PPC64_ADDR16 =          R_PPC_ADDR16;
1704 enum R_PPC64_ADDR16_LO =       R_PPC_ADDR16_LO;
1705 enum R_PPC64_ADDR16_HI =       R_PPC_ADDR16_HI;
1706 enum R_PPC64_ADDR16_HA =       R_PPC_ADDR16_HA;
1707 enum R_PPC64_ADDR14 =          R_PPC_ADDR14;
1708 enum R_PPC64_ADDR14_BRTAKEN =  R_PPC_ADDR14_BRTAKEN;
1709 enum R_PPC64_ADDR14_BRNTAKEN = R_PPC_ADDR14_BRNTAKEN;
1710 enum R_PPC64_REL24 =           R_PPC_REL24;
1711 enum R_PPC64_REL14 =           R_PPC_REL14;
1712 enum R_PPC64_REL14_BRTAKEN =   R_PPC_REL14_BRTAKEN;
1713 enum R_PPC64_REL14_BRNTAKEN =  R_PPC_REL14_BRNTAKEN;
1714 enum R_PPC64_GOT16 =           R_PPC_GOT16;
1715 enum R_PPC64_GOT16_LO =        R_PPC_GOT16_LO;
1716 enum R_PPC64_GOT16_HI =        R_PPC_GOT16_HI;
1717 enum R_PPC64_GOT16_HA =        R_PPC_GOT16_HA;
1718 
1719 enum R_PPC64_COPY =            R_PPC_COPY;
1720 enum R_PPC64_GLOB_DAT =        R_PPC_GLOB_DAT;
1721 enum R_PPC64_JMP_SLOT =        R_PPC_JMP_SLOT;
1722 enum R_PPC64_RELATIVE =        R_PPC_RELATIVE;
1723 
1724 enum R_PPC64_UADDR32 =         R_PPC_UADDR32;
1725 enum R_PPC64_UADDR16 =         R_PPC_UADDR16;
1726 enum R_PPC64_REL32 =           R_PPC_REL32;
1727 enum R_PPC64_PLT32 =           R_PPC_PLT32;
1728 enum R_PPC64_PLTREL32 =        R_PPC_PLTREL32;
1729 enum R_PPC64_PLT16_LO =        R_PPC_PLT16_LO;
1730 enum R_PPC64_PLT16_HI =        R_PPC_PLT16_HI;
1731 enum R_PPC64_PLT16_HA =        R_PPC_PLT16_HA;
1732 
1733 enum R_PPC64_SECTOFF =         R_PPC_SECTOFF;
1734 enum R_PPC64_SECTOFF_LO =      R_PPC_SECTOFF_LO;
1735 enum R_PPC64_SECTOFF_HI =      R_PPC_SECTOFF_HI;
1736 enum R_PPC64_SECTOFF_HA =      R_PPC_SECTOFF_HA;
1737 enum R_PPC64_ADDR30 =          37;
1738 enum R_PPC64_ADDR64 =          38;
1739 enum R_PPC64_ADDR16_HIGHER =   39;
1740 enum R_PPC64_ADDR16_HIGHERA =  40;
1741 enum R_PPC64_ADDR16_HIGHEST =  41;
1742 enum R_PPC64_ADDR16_HIGHESTA = 42;
1743 enum R_PPC64_UADDR64 =         43;
1744 enum R_PPC64_REL64 =           44;
1745 enum R_PPC64_PLT64 =           45;
1746 enum R_PPC64_PLTREL64 =        46;
1747 enum R_PPC64_TOC16 =           47;
1748 enum R_PPC64_TOC16_LO =        48;
1749 enum R_PPC64_TOC16_HI =        49;
1750 enum R_PPC64_TOC16_HA =        50;
1751 enum R_PPC64_TOC =             51;
1752 enum R_PPC64_PLTGOT16 =        52;
1753 enum R_PPC64_PLTGOT16_LO =     53;
1754 enum R_PPC64_PLTGOT16_HI =     54;
1755 enum R_PPC64_PLTGOT16_HA =     55;
1756 
1757 enum R_PPC64_ADDR16_DS =       56;
1758 enum R_PPC64_ADDR16_LO_DS =    57;
1759 enum R_PPC64_GOT16_DS =        58;
1760 enum R_PPC64_GOT16_LO_DS =     59;
1761 enum R_PPC64_PLT16_LO_DS =     60;
1762 enum R_PPC64_SECTOFF_DS =      61;
1763 enum R_PPC64_SECTOFF_LO_DS =   62;
1764 enum R_PPC64_TOC16_DS =        63;
1765 enum R_PPC64_TOC16_LO_DS =     64;
1766 enum R_PPC64_PLTGOT16_DS =     65;
1767 enum R_PPC64_PLTGOT16_LO_DS =  66;
1768 enum R_PPC64_TLS =             67;
1769 enum R_PPC64_DTPMOD64 =        68;
1770 enum R_PPC64_TPREL16 =         69;
1771 enum R_PPC64_TPREL16_LO =      70;
1772 enum R_PPC64_TPREL16_HI =      71;
1773 enum R_PPC64_TPREL16_HA =      72;
1774 enum R_PPC64_TPREL64 =         73;
1775 enum R_PPC64_DTPREL16 =        74;
1776 enum R_PPC64_DTPREL16_LO =     75;
1777 enum R_PPC64_DTPREL16_HI =     76;
1778 enum R_PPC64_DTPREL16_HA =     77;
1779 enum R_PPC64_DTPREL64 =        78;
1780 enum R_PPC64_GOT_TLSGD16 =     79;
1781 enum R_PPC64_GOT_TLSGD16_LO =  80;
1782 enum R_PPC64_GOT_TLSGD16_HI =  81;
1783 enum R_PPC64_GOT_TLSGD16_HA =  82;
1784 enum R_PPC64_GOT_TLSLD16 =     83;
1785 enum R_PPC64_GOT_TLSLD16_LO =  84;
1786 enum R_PPC64_GOT_TLSLD16_HI =  85;
1787 enum R_PPC64_GOT_TLSLD16_HA =  86;
1788 enum R_PPC64_GOT_TPREL16_DS =  87;
1789 enum R_PPC64_GOT_TPREL16_LO_DS = 88;
1790 enum R_PPC64_GOT_TPREL16_HI =  89;
1791 enum R_PPC64_GOT_TPREL16_HA =  90;
1792 enum R_PPC64_GOT_DTPREL16_DS = 91;
1793 enum R_PPC64_GOT_DTPREL16_LO_DS = 92;
1794 enum R_PPC64_GOT_DTPREL16_HI = 93;
1795 enum R_PPC64_GOT_DTPREL16_HA = 94;
1796 enum R_PPC64_TPREL16_DS =      95;
1797 enum R_PPC64_TPREL16_LO_DS =   96;
1798 enum R_PPC64_TPREL16_HIGHER =  97;
1799 enum R_PPC64_TPREL16_HIGHERA = 98;
1800 enum R_PPC64_TPREL16_HIGHEST = 99;
1801 enum R_PPC64_TPREL16_HIGHESTA = 100;
1802 enum R_PPC64_DTPREL16_DS =     101;
1803 enum R_PPC64_DTPREL16_LO_DS =  102;
1804 enum R_PPC64_DTPREL16_HIGHER = 103;
1805 enum R_PPC64_DTPREL16_HIGHERA = 104;
1806 enum R_PPC64_DTPREL16_HIGHEST = 105;
1807 enum R_PPC64_DTPREL16_HIGHESTA = 106;
1808 enum R_PPC64_JMP_IREL =        247;
1809 enum R_PPC64_IRELATIVE =       248;
1810 enum R_PPC64_REL16 =           249;
1811 enum R_PPC64_REL16_LO =        250;
1812 enum R_PPC64_REL16_HI =        251;
1813 enum R_PPC64_REL16_HA =        252;
1814 enum DT_PPC64_GLINK =  (DT_LOPROC + 0);
1815 enum DT_PPC64_OPD =    (DT_LOPROC + 1);
1816 enum DT_PPC64_OPDSZ =  (DT_LOPROC + 2);
1817 enum DT_PPC64_NUM =    3;
1818 enum EF_ARM_RELEXEC =          0x01;
1819 enum EF_ARM_HASENTRY =         0x02;
1820 enum EF_ARM_INTERWORK =        0x04;
1821 enum EF_ARM_APCS_26 =          0x08;
1822 enum EF_ARM_APCS_FLOAT =       0x10;
1823 enum EF_ARM_PIC =              0x20;
1824 enum EF_ARM_ALIGN8 =           0x40;
1825 enum EF_ARM_NEW_ABI =          0x80;
1826 enum EF_ARM_OLD_ABI =          0x100;
1827 enum EF_ARM_SOFT_FLOAT =       0x200;
1828 enum EF_ARM_VFP_FLOAT =        0x400;
1829 enum EF_ARM_MAVERICK_FLOAT =   0x800;
1830 
1831 enum EF_ARM_ABI_FLOAT_SOFT =   0x200;
1832 enum EF_ARM_ABI_FLOAT_HARD =   0x400;
1833 enum EF_ARM_SYMSARESORTED =    0x04;
1834 enum EF_ARM_DYNSYMSUSESEGIDX = 0x08;
1835 enum EF_ARM_MAPSYMSFIRST =     0x10;
1836 enum EF_ARM_EABIMASK =         0XFF000000;
1837 enum EF_ARM_BE8 =          0x00800000;
1838 enum EF_ARM_LE8 =          0x00400000;
1839 
1840 extern (D) auto EF_ARM_EABI_VERSION(F)(F flags) { return flags & EF_ARM_EABIMASK; }
1841 enum EF_ARM_EABI_UNKNOWN =     0x00000000;
1842 enum EF_ARM_EABI_VER1 =        0x01000000;
1843 enum EF_ARM_EABI_VER2 =        0x02000000;
1844 enum EF_ARM_EABI_VER3 =        0x03000000;
1845 enum EF_ARM_EABI_VER4 =        0x04000000;
1846 enum EF_ARM_EABI_VER5 =        0x05000000;
1847 enum STT_ARM_TFUNC =           STT_LOPROC;
1848 enum STT_ARM_16BIT =           STT_HIPROC;
1849 enum SHF_ARM_ENTRYSECT =       0x10000000;
1850 enum SHF_ARM_COMDEF =          0x80000000;
1851 enum PF_ARM_SB =               0x10000000;
1852 enum PF_ARM_PI =               0x20000000;
1853 enum PF_ARM_ABS =              0x40000000;
1854 enum PT_ARM_EXIDX =            (PT_LOPROC + 1);
1855 enum SHT_ARM_EXIDX =           (SHT_LOPROC + 1);
1856 enum SHT_ARM_PREEMPTMAP =      (SHT_LOPROC + 2);
1857 enum SHT_ARM_ATTRIBUTES =      (SHT_LOPROC + 3);
1858 
1859 enum R_AARCH64_NONE =            0;
1860 enum R_AARCH64_ABS64 =         257;
1861 enum R_AARCH64_ABS32 =         258;
1862 enum R_AARCH64_COPY =         1024;
1863 enum R_AARCH64_GLOB_DAT =     1025;
1864 enum R_AARCH64_JUMP_SLOT =    1026;
1865 enum R_AARCH64_RELATIVE =     1027;
1866 enum R_AARCH64_TLS_DTPMOD64 = 1028;
1867 enum R_AARCH64_TLS_DTPREL64 = 1029;
1868 enum R_AARCH64_TLS_TPREL64 =  1030;
1869 enum R_AARCH64_TLSDESC =      1031;
1870 
1871 enum R_ARM_NONE =              0;
1872 enum R_ARM_PC24 =              1;
1873 enum R_ARM_ABS32 =             2;
1874 enum R_ARM_REL32 =             3;
1875 enum R_ARM_PC13 =              4;
1876 enum R_ARM_ABS16 =             5;
1877 enum R_ARM_ABS12 =             6;
1878 enum R_ARM_THM_ABS5 =          7;
1879 enum R_ARM_ABS8 =              8;
1880 enum R_ARM_SBREL32 =           9;
1881 enum R_ARM_THM_PC22 =          10;
1882 enum R_ARM_THM_PC8 =           11;
1883 enum R_ARM_AMP_VCALL9 =        12;
1884 enum R_ARM_SWI24 =             13;
1885 enum R_ARM_TLS_DESC =          13;
1886 enum R_ARM_THM_SWI8 =          14;
1887 enum R_ARM_XPC25 =             15;
1888 enum R_ARM_THM_XPC22 =         16;
1889 enum R_ARM_TLS_DTPMOD32 =      17;
1890 enum R_ARM_TLS_DTPOFF32 =      18;
1891 enum R_ARM_TLS_TPOFF32 =       19;
1892 enum R_ARM_COPY =              20;
1893 enum R_ARM_GLOB_DAT =          21;
1894 enum R_ARM_JUMP_SLOT =         22;
1895 enum R_ARM_RELATIVE =          23;
1896 enum R_ARM_GOTOFF =            24;
1897 enum R_ARM_GOTPC =             25;
1898 enum R_ARM_GOT32 =             26;
1899 enum R_ARM_PLT32 =             27;
1900 enum R_ARM_ALU_PCREL_7_0 =     32;
1901 enum R_ARM_ALU_PCREL_15_8 =    33;
1902 enum R_ARM_ALU_PCREL_23_15 =   34;
1903 enum R_ARM_LDR_SBREL_11_0 =    35;
1904 enum R_ARM_ALU_SBREL_19_12 =   36;
1905 enum R_ARM_ALU_SBREL_27_20 =   37;
1906 enum R_ARM_TLS_GOTDESC =       90;
1907 enum R_ARM_TLS_CALL =          91;
1908 enum R_ARM_TLS_DESCSEQ =       92;
1909 enum R_ARM_THM_TLS_CALL =      93;
1910 enum R_ARM_GNU_VTENTRY =       100;
1911 enum R_ARM_GNU_VTINHERIT =     101;
1912 enum R_ARM_THM_PC11 =          102;
1913 enum R_ARM_THM_PC9 =           103;
1914 enum R_ARM_TLS_GD32 =          104;
1915 enum R_ARM_TLS_LDM32 =         105;
1916 enum R_ARM_TLS_LDO32 =         106;
1917 enum R_ARM_TLS_IE32 =          107;
1918 enum R_ARM_TLS_LE32 =          108;
1919 enum R_ARM_THM_TLS_DESCSEQ =   129;
1920 enum R_ARM_IRELATIVE =         160;
1921 enum R_ARM_RXPC25 =            249;
1922 enum R_ARM_RSBREL32 =          250;
1923 enum R_ARM_THM_RPC22 =         251;
1924 enum R_ARM_RREL32 =            252;
1925 enum R_ARM_RABS22 =            253;
1926 enum R_ARM_RPC24 =             254;
1927 enum R_ARM_RBASE =             255;
1928 enum R_ARM_NUM =               256;
1929 enum EF_IA_64_MASKOS =         0x0000000f;
1930 enum EF_IA_64_ABI64 =          0x00000010;
1931 enum EF_IA_64_ARCH =           0xff000000;
1932 enum PT_IA_64_ARCHEXT =        (PT_LOPROC + 0);
1933 enum PT_IA_64_UNWIND =         (PT_LOPROC + 1);
1934 enum PT_IA_64_HP_OPT_ANOT =    (PT_LOOS + 0x12);
1935 enum PT_IA_64_HP_HSL_ANOT =    (PT_LOOS + 0x13);
1936 enum PT_IA_64_HP_STACK =       (PT_LOOS + 0x14);
1937 enum PF_IA_64_NORECOV =        0x80000000;
1938 enum SHT_IA_64_EXT =           (SHT_LOPROC + 0);
1939 enum SHT_IA_64_UNWIND =        (SHT_LOPROC + 1);
1940 enum SHF_IA_64_SHORT =         0x10000000;
1941 enum SHF_IA_64_NORECOV =       0x20000000;
1942 enum DT_IA_64_PLT_RESERVE =    (DT_LOPROC + 0);
1943 enum DT_IA_64_NUM =            1;
1944 enum R_IA64_NONE =             0x00;
1945 enum R_IA64_IMM14 =            0x21;
1946 enum R_IA64_IMM22 =            0x22;
1947 enum R_IA64_IMM64 =            0x23;
1948 enum R_IA64_DIR32MSB =         0x24;
1949 enum R_IA64_DIR32LSB =         0x25;
1950 enum R_IA64_DIR64MSB =         0x26;
1951 enum R_IA64_DIR64LSB =         0x27;
1952 enum R_IA64_GPREL22 =          0x2a;
1953 enum R_IA64_GPREL64I =         0x2b;
1954 enum R_IA64_GPREL32MSB =       0x2c;
1955 enum R_IA64_GPREL32LSB =       0x2d;
1956 enum R_IA64_GPREL64MSB =       0x2e;
1957 enum R_IA64_GPREL64LSB =       0x2f;
1958 enum R_IA64_LTOFF22 =          0x32;
1959 enum R_IA64_LTOFF64I =         0x33;
1960 enum R_IA64_PLTOFF22 =         0x3a;
1961 enum R_IA64_PLTOFF64I =        0x3b;
1962 enum R_IA64_PLTOFF64MSB =      0x3e;
1963 enum R_IA64_PLTOFF64LSB =      0x3f;
1964 enum R_IA64_FPTR64I =          0x43;
1965 enum R_IA64_FPTR32MSB =        0x44;
1966 enum R_IA64_FPTR32LSB =        0x45;
1967 enum R_IA64_FPTR64MSB =        0x46;
1968 enum R_IA64_FPTR64LSB =        0x47;
1969 enum R_IA64_PCREL60B =         0x48;
1970 enum R_IA64_PCREL21B =         0x49;
1971 enum R_IA64_PCREL21M =         0x4a;
1972 enum R_IA64_PCREL21F =         0x4b;
1973 enum R_IA64_PCREL32MSB =       0x4c;
1974 enum R_IA64_PCREL32LSB =       0x4d;
1975 enum R_IA64_PCREL64MSB =       0x4e;
1976 enum R_IA64_PCREL64LSB =       0x4f;
1977 enum R_IA64_LTOFF_FPTR22 =     0x52;
1978 enum R_IA64_LTOFF_FPTR64I =    0x53;
1979 enum R_IA64_LTOFF_FPTR32MSB =  0x54;
1980 enum R_IA64_LTOFF_FPTR32LSB =  0x55;
1981 enum R_IA64_LTOFF_FPTR64MSB =  0x56;
1982 enum R_IA64_LTOFF_FPTR64LSB =  0x57;
1983 enum R_IA64_SEGREL32MSB =      0x5c;
1984 enum R_IA64_SEGREL32LSB =      0x5d;
1985 enum R_IA64_SEGREL64MSB =      0x5e;
1986 enum R_IA64_SEGREL64LSB =      0x5f;
1987 enum R_IA64_SECREL32MSB =      0x64;
1988 enum R_IA64_SECREL32LSB =      0x65;
1989 enum R_IA64_SECREL64MSB =      0x66;
1990 enum R_IA64_SECREL64LSB =      0x67;
1991 enum R_IA64_REL32MSB =         0x6c;
1992 enum R_IA64_REL32LSB =         0x6d;
1993 enum R_IA64_REL64MSB =         0x6e;
1994 enum R_IA64_REL64LSB =         0x6f;
1995 enum R_IA64_LTV32MSB =         0x74;
1996 enum R_IA64_LTV32LSB =         0x75;
1997 enum R_IA64_LTV64MSB =         0x76;
1998 enum R_IA64_LTV64LSB =         0x77;
1999 enum R_IA64_PCREL21BI =        0x79;
2000 enum R_IA64_PCREL22 =          0x7a;
2001 enum R_IA64_PCREL64I =         0x7b;
2002 enum R_IA64_IPLTMSB =          0x80;
2003 enum R_IA64_IPLTLSB =          0x81;
2004 enum R_IA64_COPY =             0x84;
2005 enum R_IA64_SUB =              0x85;
2006 enum R_IA64_LTOFF22X =         0x86;
2007 enum R_IA64_LDXMOV =           0x87;
2008 enum R_IA64_TPREL14 =          0x91;
2009 enum R_IA64_TPREL22 =          0x92;
2010 enum R_IA64_TPREL64I =         0x93;
2011 enum R_IA64_TPREL64MSB =       0x96;
2012 enum R_IA64_TPREL64LSB =       0x97;
2013 enum R_IA64_LTOFF_TPREL22 =    0x9a;
2014 enum R_IA64_DTPMOD64MSB =      0xa6;
2015 enum R_IA64_DTPMOD64LSB =      0xa7;
2016 enum R_IA64_LTOFF_DTPMOD22 =   0xaa;
2017 enum R_IA64_DTPREL14 =         0xb1;
2018 enum R_IA64_DTPREL22 =         0xb2;
2019 enum R_IA64_DTPREL64I =        0xb3;
2020 enum R_IA64_DTPREL32MSB =      0xb4;
2021 enum R_IA64_DTPREL32LSB =      0xb5;
2022 enum R_IA64_DTPREL64MSB =      0xb6;
2023 enum R_IA64_DTPREL64LSB =      0xb7;
2024 enum R_IA64_LTOFF_DTPREL22 =   0xba;
2025 enum EF_SH_MACH_MASK =         0x1f;
2026 enum EF_SH_UNKNOWN =           0x0;
2027 enum EF_SH1 =                  0x1;
2028 enum EF_SH2 =                  0x2;
2029 enum EF_SH3 =                  0x3;
2030 enum EF_SH_DSP =               0x4;
2031 enum EF_SH3_DSP =              0x5;
2032 enum EF_SH4AL_DSP =            0x6;
2033 enum EF_SH3E =                 0x8;
2034 enum EF_SH4 =                  0x9;
2035 enum EF_SH2E =                 0xb;
2036 enum EF_SH4A =                 0xc;
2037 enum EF_SH2A =                 0xd;
2038 enum EF_SH4_NOFPU =            0x10;
2039 enum EF_SH4A_NOFPU =           0x11;
2040 enum EF_SH4_NOMMU_NOFPU =      0x12;
2041 enum EF_SH2A_NOFPU =           0x13;
2042 enum EF_SH3_NOMMU =            0x14;
2043 enum EF_SH2A_SH4_NOFPU =       0x15;
2044 enum EF_SH2A_SH3_NOFPU =       0x16;
2045 enum EF_SH2A_SH4 =             0x17;
2046 enum EF_SH2A_SH3E =            0x18;
2047 enum R_SH_NONE =               0;
2048 enum R_SH_DIR32 =              1;
2049 enum R_SH_REL32 =              2;
2050 enum R_SH_DIR8WPN =            3;
2051 enum R_SH_IND12W =             4;
2052 enum R_SH_DIR8WPL =            5;
2053 enum R_SH_DIR8WPZ =            6;
2054 enum R_SH_DIR8BP =             7;
2055 enum R_SH_DIR8W =              8;
2056 enum R_SH_DIR8L =              9;
2057 enum R_SH_SWITCH16 =           25;
2058 enum R_SH_SWITCH32 =           26;
2059 enum R_SH_USES =               27;
2060 enum R_SH_COUNT =              28;
2061 enum R_SH_ALIGN =              29;
2062 enum R_SH_CODE =               30;
2063 enum R_SH_DATA =               31;
2064 enum R_SH_LABEL =              32;
2065 enum R_SH_SWITCH8 =            33;
2066 enum R_SH_GNU_VTINHERIT =      34;
2067 enum R_SH_GNU_VTENTRY =        35;
2068 enum R_SH_TLS_GD_32 =          144;
2069 enum R_SH_TLS_LD_32 =          145;
2070 enum R_SH_TLS_LDO_32 =         146;
2071 enum R_SH_TLS_IE_32 =          147;
2072 enum R_SH_TLS_LE_32 =          148;
2073 enum R_SH_TLS_DTPMOD32 =       149;
2074 enum R_SH_TLS_DTPOFF32 =       150;
2075 enum R_SH_TLS_TPOFF32 =        151;
2076 enum R_SH_GOT32 =              160;
2077 enum R_SH_PLT32 =              161;
2078 enum R_SH_COPY =               162;
2079 enum R_SH_GLOB_DAT =           163;
2080 enum R_SH_JMP_SLOT =           164;
2081 enum R_SH_RELATIVE =           165;
2082 enum R_SH_GOTOFF =             166;
2083 enum R_SH_GOTPC =              167;
2084 enum R_SH_NUM =                256;
2085 
2086 enum EF_S390_HIGH_GPRS =    0x00000001;
2087 
2088 enum R_390_NONE =              0;
2089 enum R_390_8 =                 1;
2090 enum R_390_12 =                2;
2091 enum R_390_16 =                3;
2092 enum R_390_32 =                4;
2093 enum R_390_PC32 =              5;
2094 enum R_390_GOT12 =             6;
2095 enum R_390_GOT32 =             7;
2096 enum R_390_PLT32 =             8;
2097 enum R_390_COPY =              9;
2098 enum R_390_GLOB_DAT =          10;
2099 enum R_390_JMP_SLOT =          11;
2100 enum R_390_RELATIVE =          12;
2101 enum R_390_GOTOFF32 =          13;
2102 enum R_390_GOTPC =             14;
2103 enum R_390_GOT16 =             15;
2104 enum R_390_PC16 =              16;
2105 enum R_390_PC16DBL =           17;
2106 enum R_390_PLT16DBL =          18;
2107 enum R_390_PC32DBL =           19;
2108 enum R_390_PLT32DBL =          20;
2109 enum R_390_GOTPCDBL =          21;
2110 enum R_390_64 =                22;
2111 enum R_390_PC64 =              23;
2112 enum R_390_GOT64 =             24;
2113 enum R_390_PLT64 =             25;
2114 enum R_390_GOTENT =            26;
2115 enum R_390_GOTOFF16 =          27;
2116 enum R_390_GOTOFF64 =          28;
2117 enum R_390_GOTPLT12 =          29;
2118 enum R_390_GOTPLT16 =          30;
2119 enum R_390_GOTPLT32 =          31;
2120 enum R_390_GOTPLT64 =          32;
2121 enum R_390_GOTPLTENT =         33;
2122 enum R_390_PLTOFF16 =          34;
2123 enum R_390_PLTOFF32 =          35;
2124 enum R_390_PLTOFF64 =          36;
2125 enum R_390_TLS_LOAD =          37;
2126 enum R_390_TLS_GDCALL =        38;
2127 enum R_390_TLS_LDCALL =        39;
2128 enum R_390_TLS_GD32 =          40;
2129 enum R_390_TLS_GD64 =          41;
2130 enum R_390_TLS_GOTIE12 =       42;
2131 enum R_390_TLS_GOTIE32 =       43;
2132 enum R_390_TLS_GOTIE64 =       44;
2133 enum R_390_TLS_LDM32 =         45;
2134 enum R_390_TLS_LDM64 =         46;
2135 enum R_390_TLS_IE32 =          47;
2136 enum R_390_TLS_IE64 =          48;
2137 enum R_390_TLS_IEENT =         49;
2138 enum R_390_TLS_LE32 =          50;
2139 enum R_390_TLS_LE64 =          51;
2140 enum R_390_TLS_LDO32 =         52;
2141 enum R_390_TLS_LDO64 =         53;
2142 enum R_390_TLS_DTPMOD =        54;
2143 enum R_390_TLS_DTPOFF =        55;
2144 enum R_390_TLS_TPOFF =         56;
2145 enum R_390_20 =                57;
2146 enum R_390_GOT20 =             58;
2147 enum R_390_GOTPLT20 =          59;
2148 enum R_390_TLS_GOTIE20 =       60;
2149 enum R_390_IRELATIVE =         61;
2150 enum R_390_NUM =               62;
2151 enum R_CRIS_NONE =             0;
2152 enum R_CRIS_8 =                1;
2153 enum R_CRIS_16 =               2;
2154 enum R_CRIS_32 =               3;
2155 enum R_CRIS_8_PCREL =          4;
2156 enum R_CRIS_16_PCREL =         5;
2157 enum R_CRIS_32_PCREL =         6;
2158 enum R_CRIS_GNU_VTINHERIT =    7;
2159 enum R_CRIS_GNU_VTENTRY =      8;
2160 enum R_CRIS_COPY =             9;
2161 enum R_CRIS_GLOB_DAT =         10;
2162 enum R_CRIS_JUMP_SLOT =        11;
2163 enum R_CRIS_RELATIVE =         12;
2164 enum R_CRIS_16_GOT =           13;
2165 enum R_CRIS_32_GOT =           14;
2166 enum R_CRIS_16_GOTPLT =        15;
2167 enum R_CRIS_32_GOTPLT =        16;
2168 enum R_CRIS_32_GOTREL =        17;
2169 enum R_CRIS_32_PLT_GOTREL =    18;
2170 enum R_CRIS_32_PLT_PCREL =     19;
2171 
2172 enum R_CRIS_NUM =              20;
2173 enum R_X86_64_NONE =           0;
2174 enum R_X86_64_64 =             1;
2175 enum R_X86_64_PC32 =           2;
2176 enum R_X86_64_GOT32 =          3;
2177 enum R_X86_64_PLT32 =          4;
2178 enum R_X86_64_COPY =           5;
2179 enum R_X86_64_GLOB_DAT =       6;
2180 enum R_X86_64_JUMP_SLOT =      7;
2181 enum R_X86_64_RELATIVE =       8;
2182 enum R_X86_64_GOTPCREL =       9;
2183 enum R_X86_64_32 =             10;
2184 enum R_X86_64_32S =            11;
2185 enum R_X86_64_16 =             12;
2186 enum R_X86_64_PC16 =           13;
2187 enum R_X86_64_8 =              14;
2188 enum R_X86_64_PC8 =            15;
2189 enum R_X86_64_DTPMOD64 =       16;
2190 enum R_X86_64_DTPOFF64 =       17;
2191 enum R_X86_64_TPOFF64 =        18;
2192 enum R_X86_64_TLSGD =          19;
2193 enum R_X86_64_TLSLD =          20;
2194 enum R_X86_64_DTPOFF32 =       21;
2195 enum R_X86_64_GOTTPOFF =       22;
2196 enum R_X86_64_TPOFF32 =        23;
2197 enum R_X86_64_PC64 =           24;
2198 enum R_X86_64_GOTOFF64 =       25;
2199 enum R_X86_64_GOTPC32 =        26;
2200 enum R_X86_64_GOT64 =          27;
2201 enum R_X86_64_GOTPCREL64 =     28;
2202 enum R_X86_64_GOTPC64 =        29;
2203 enum R_X86_64_GOTPLT64 =       30;
2204 enum R_X86_64_PLTOFF64 =       31;
2205 enum R_X86_64_SIZE32 =         32;
2206 enum R_X86_64_SIZE64 =         33;
2207 enum R_X86_64_GOTPC32_TLSDESC = 34;
2208 enum R_X86_64_TLSDESC_CALL =   35;
2209 enum R_X86_64_TLSDESC =        36;
2210 enum R_X86_64_IRELATIVE =      37;
2211 enum R_X86_64_RELATIVE64 =     38;
2212 
2213 enum R_X86_64_NUM =            39;
2214 enum R_MN10300_NONE =          0;
2215 enum R_MN10300_32 =            1;
2216 enum R_MN10300_16 =            2;
2217 enum R_MN10300_8 =             3;
2218 enum R_MN10300_PCREL32 =       4;
2219 enum R_MN10300_PCREL16 =       5;
2220 enum R_MN10300_PCREL8 =        6;
2221 enum R_MN10300_GNU_VTINHERIT = 7;
2222 enum R_MN10300_GNU_VTENTRY =   8;
2223 enum R_MN10300_24 =            9;
2224 enum R_MN10300_GOTPC32 =       10;
2225 enum R_MN10300_GOTPC16 =       11;
2226 enum R_MN10300_GOTOFF32 =      12;
2227 enum R_MN10300_GOTOFF24 =      13;
2228 enum R_MN10300_GOTOFF16 =      14;
2229 enum R_MN10300_PLT32 =         15;
2230 enum R_MN10300_PLT16 =         16;
2231 enum R_MN10300_GOT32 =         17;
2232 enum R_MN10300_GOT24 =         18;
2233 enum R_MN10300_GOT16 =         19;
2234 enum R_MN10300_COPY =          20;
2235 enum R_MN10300_GLOB_DAT =      21;
2236 enum R_MN10300_JMP_SLOT =      22;
2237 enum R_MN10300_RELATIVE =      23;
2238 enum R_MN10300_TLS_GD =        24;
2239 enum R_MN10300_TLS_LD =        25;
2240 enum R_MN10300_TLS_LDO =       26;
2241 enum R_MN10300_TLS_GOTIE =     27;
2242 enum R_MN10300_TLS_IE =        28;
2243 enum R_MN10300_TLS_LE =        29;
2244 enum R_MN10300_TLS_DTPMOD =    30;
2245 enum R_MN10300_TLS_DTPOFF =    31;
2246 enum R_MN10300_TLS_TPOFF =     32;
2247 enum R_MN10300_SYM_DIFF =      33;
2248 enum R_MN10300_ALIGN =         34;
2249 enum R_MN10300_NUM =           35;
2250 enum R_M32R_NONE =             0;
2251 enum R_M32R_16 =               1;
2252 enum R_M32R_32 =               2;
2253 enum R_M32R_24 =               3;
2254 enum R_M32R_10_PCREL =         4;
2255 enum R_M32R_18_PCREL =         5;
2256 enum R_M32R_26_PCREL =         6;
2257 enum R_M32R_HI16_ULO =         7;
2258 enum R_M32R_HI16_SLO =         8;
2259 enum R_M32R_LO16 =             9;
2260 enum R_M32R_SDA16 =            10;
2261 enum R_M32R_GNU_VTINHERIT =    11;
2262 enum R_M32R_GNU_VTENTRY =      12;
2263 enum R_M32R_16_RELA =          33;
2264 enum R_M32R_32_RELA =          34;
2265 enum R_M32R_24_RELA =          35;
2266 enum R_M32R_10_PCREL_RELA =    36;
2267 enum R_M32R_18_PCREL_RELA =    37;
2268 enum R_M32R_26_PCREL_RELA =    38;
2269 enum R_M32R_HI16_ULO_RELA =    39;
2270 enum R_M32R_HI16_SLO_RELA =    40;
2271 enum R_M32R_LO16_RELA =        41;
2272 enum R_M32R_SDA16_RELA =       42;
2273 enum R_M32R_RELA_GNU_VTINHERIT =       43;
2274 enum R_M32R_RELA_GNU_VTENTRY = 44;
2275 enum R_M32R_REL32 =            45;
2276 
2277 enum R_M32R_GOT24 =            48;
2278 enum R_M32R_26_PLTREL =        49;
2279 enum R_M32R_COPY =             50;
2280 enum R_M32R_GLOB_DAT =         51;
2281 enum R_M32R_JMP_SLOT =         52;
2282 enum R_M32R_RELATIVE =         53;
2283 enum R_M32R_GOTOFF =           54;
2284 enum R_M32R_GOTPC24 =          55;
2285 enum R_M32R_GOT16_HI_ULO =     56;
2286 enum R_M32R_GOT16_HI_SLO =     57;
2287 enum R_M32R_GOT16_LO =         58;
2288 enum R_M32R_GOTPC_HI_ULO =     59;
2289 enum R_M32R_GOTPC_HI_SLO =     60;
2290 enum R_M32R_GOTPC_LO =         61;
2291 enum R_M32R_GOTOFF_HI_ULO =    62;
2292 enum R_M32R_GOTOFF_HI_SLO =    63;
2293 enum R_M32R_GOTOFF_LO =        64;
2294 enum R_M32R_NUM =              256;
2295 enum R_TILEPRO_NONE =          0;
2296 enum R_TILEPRO_32 =            1;
2297 enum R_TILEPRO_16 =            2;
2298 enum R_TILEPRO_8 =             3;
2299 enum R_TILEPRO_32_PCREL =      4;
2300 enum R_TILEPRO_16_PCREL =      5;
2301 enum R_TILEPRO_8_PCREL =       6;
2302 enum R_TILEPRO_LO16 =          7;
2303 enum R_TILEPRO_HI16 =          8;
2304 enum R_TILEPRO_HA16 =          9;
2305 enum R_TILEPRO_COPY =          10;
2306 enum R_TILEPRO_GLOB_DAT =      11;
2307 enum R_TILEPRO_JMP_SLOT =      12;
2308 enum R_TILEPRO_RELATIVE =      13;
2309 enum R_TILEPRO_BROFF_X1 =      14;
2310 enum R_TILEPRO_JOFFLONG_X1 =   15;
2311 enum R_TILEPRO_JOFFLONG_X1_PLT = 16;
2312 enum R_TILEPRO_IMM8_X0 =       17;
2313 enum R_TILEPRO_IMM8_Y0 =       18;
2314 enum R_TILEPRO_IMM8_X1 =       19;
2315 enum R_TILEPRO_IMM8_Y1 =       20;
2316 enum R_TILEPRO_MT_IMM15_X1 =   21;
2317 enum R_TILEPRO_MF_IMM15_X1 =   22;
2318 enum R_TILEPRO_IMM16_X0 =      23;
2319 enum R_TILEPRO_IMM16_X1 =      24;
2320 enum R_TILEPRO_IMM16_X0_LO =   25;
2321 enum R_TILEPRO_IMM16_X1_LO =   26;
2322 enum R_TILEPRO_IMM16_X0_HI =   27;
2323 enum R_TILEPRO_IMM16_X1_HI =   28;
2324 enum R_TILEPRO_IMM16_X0_HA =   29;
2325 enum R_TILEPRO_IMM16_X1_HA =   30;
2326 enum R_TILEPRO_IMM16_X0_PCREL = 31;
2327 enum R_TILEPRO_IMM16_X1_PCREL = 32;
2328 enum R_TILEPRO_IMM16_X0_LO_PCREL = 33;
2329 enum R_TILEPRO_IMM16_X1_LO_PCREL = 34;
2330 enum R_TILEPRO_IMM16_X0_HI_PCREL = 35;
2331 enum R_TILEPRO_IMM16_X1_HI_PCREL = 36;
2332 enum R_TILEPRO_IMM16_X0_HA_PCREL = 37;
2333 enum R_TILEPRO_IMM16_X1_HA_PCREL = 38;
2334 enum R_TILEPRO_IMM16_X0_GOT =  39;
2335 enum R_TILEPRO_IMM16_X1_GOT =  40;
2336 enum R_TILEPRO_IMM16_X0_GOT_LO = 41;
2337 enum R_TILEPRO_IMM16_X1_GOT_LO = 42;
2338 enum R_TILEPRO_IMM16_X0_GOT_HI = 43;
2339 enum R_TILEPRO_IMM16_X1_GOT_HI = 44;
2340 enum R_TILEPRO_IMM16_X0_GOT_HA = 45;
2341 enum R_TILEPRO_IMM16_X1_GOT_HA = 46;
2342 enum R_TILEPRO_MMSTART_X0 =    47;
2343 enum R_TILEPRO_MMEND_X0 =      48;
2344 enum R_TILEPRO_MMSTART_X1 =    49;
2345 enum R_TILEPRO_MMEND_X1 =      50;
2346 enum R_TILEPRO_SHAMT_X0 =      51;
2347 enum R_TILEPRO_SHAMT_X1 =      52;
2348 enum R_TILEPRO_SHAMT_Y0 =      53;
2349 enum R_TILEPRO_SHAMT_Y1 =      54;
2350 enum R_TILEPRO_DEST_IMM8_X1 =  55;
2351 enum R_TILEPRO_TLS_GD_CALL =   60;
2352 enum R_TILEPRO_IMM8_X0_TLS_GD_ADD = 61;
2353 enum R_TILEPRO_IMM8_X1_TLS_GD_ADD = 62;
2354 enum R_TILEPRO_IMM8_Y0_TLS_GD_ADD = 63;
2355 enum R_TILEPRO_IMM8_Y1_TLS_GD_ADD = 64;
2356 enum R_TILEPRO_TLS_IE_LOAD =   65;
2357 enum R_TILEPRO_IMM16_X0_TLS_GD = 66;
2358 enum R_TILEPRO_IMM16_X1_TLS_GD = 67;
2359 enum R_TILEPRO_IMM16_X0_TLS_GD_LO = 68;
2360 enum R_TILEPRO_IMM16_X1_TLS_GD_LO = 69;
2361 enum R_TILEPRO_IMM16_X0_TLS_GD_HI = 70;
2362 enum R_TILEPRO_IMM16_X1_TLS_GD_HI = 71;
2363 enum R_TILEPRO_IMM16_X0_TLS_GD_HA = 72;
2364 enum R_TILEPRO_IMM16_X1_TLS_GD_HA = 73;
2365 enum R_TILEPRO_IMM16_X0_TLS_IE = 74;
2366 enum R_TILEPRO_IMM16_X1_TLS_IE = 75;
2367 enum R_TILEPRO_IMM16_X0_TLS_IE_LO = 76;
2368 enum R_TILEPRO_IMM16_X1_TLS_IE_LO = 77;
2369 enum R_TILEPRO_IMM16_X0_TLS_IE_HI = 78;
2370 enum R_TILEPRO_IMM16_X1_TLS_IE_HI = 79;
2371 enum R_TILEPRO_IMM16_X0_TLS_IE_HA = 80;
2372 enum R_TILEPRO_IMM16_X1_TLS_IE_HA = 81;
2373 enum R_TILEPRO_TLS_DTPMOD32 =  82;
2374 enum R_TILEPRO_TLS_DTPOFF32 =  83;
2375 enum R_TILEPRO_TLS_TPOFF32 =   84;
2376 enum R_TILEPRO_IMM16_X0_TLS_LE = 85;
2377 enum R_TILEPRO_IMM16_X1_TLS_LE = 86;
2378 enum R_TILEPRO_IMM16_X0_TLS_LE_LO = 87;
2379 enum R_TILEPRO_IMM16_X1_TLS_LE_LO = 88;
2380 enum R_TILEPRO_IMM16_X0_TLS_LE_HI = 89;
2381 enum R_TILEPRO_IMM16_X1_TLS_LE_HI = 90;
2382 enum R_TILEPRO_IMM16_X0_TLS_LE_HA = 91;
2383 enum R_TILEPRO_IMM16_X1_TLS_LE_HA = 92;
2384 
2385 enum R_TILEPRO_GNU_VTINHERIT = 128;
2386 enum R_TILEPRO_GNU_VTENTRY =   129;
2387 
2388 enum R_TILEPRO_NUM =           130;
2389 enum R_TILEGX_NONE =           0;
2390 enum R_TILEGX_64 =             1;
2391 enum R_TILEGX_32 =             2;
2392 enum R_TILEGX_16 =             3;
2393 enum R_TILEGX_8 =              4;
2394 enum R_TILEGX_64_PCREL =       5;
2395 enum R_TILEGX_32_PCREL =       6;
2396 enum R_TILEGX_16_PCREL =       7;
2397 enum R_TILEGX_8_PCREL =        8;
2398 enum R_TILEGX_HW0 =            9;
2399 enum R_TILEGX_HW1 =            10;
2400 enum R_TILEGX_HW2 =            11;
2401 enum R_TILEGX_HW3 =            12;
2402 enum R_TILEGX_HW0_LAST =       13;
2403 enum R_TILEGX_HW1_LAST =       14;
2404 enum R_TILEGX_HW2_LAST =       15;
2405 enum R_TILEGX_COPY =           16;
2406 enum R_TILEGX_GLOB_DAT =       17;
2407 enum R_TILEGX_JMP_SLOT =       18;
2408 enum R_TILEGX_RELATIVE =       19;
2409 enum R_TILEGX_BROFF_X1 =       20;
2410 enum R_TILEGX_JUMPOFF_X1 =     21;
2411 enum R_TILEGX_JUMPOFF_X1_PLT = 22;
2412 enum R_TILEGX_IMM8_X0 =        23;
2413 enum R_TILEGX_IMM8_Y0 =        24;
2414 enum R_TILEGX_IMM8_X1 =        25;
2415 enum R_TILEGX_IMM8_Y1 =        26;
2416 enum R_TILEGX_DEST_IMM8_X1 =   27;
2417 enum R_TILEGX_MT_IMM14_X1 =    28;
2418 enum R_TILEGX_MF_IMM14_X1 =    29;
2419 enum R_TILEGX_MMSTART_X0 =     30;
2420 enum R_TILEGX_MMEND_X0 =       31;
2421 enum R_TILEGX_SHAMT_X0 =       32;
2422 enum R_TILEGX_SHAMT_X1 =       33;
2423 enum R_TILEGX_SHAMT_Y0 =       34;
2424 enum R_TILEGX_SHAMT_Y1 =       35;
2425 enum R_TILEGX_IMM16_X0_HW0 =   36;
2426 enum R_TILEGX_IMM16_X1_HW0 =   37;
2427 enum R_TILEGX_IMM16_X0_HW1 =   38;
2428 enum R_TILEGX_IMM16_X1_HW1 =   39;
2429 enum R_TILEGX_IMM16_X0_HW2 =   40;
2430 enum R_TILEGX_IMM16_X1_HW2 =   41;
2431 enum R_TILEGX_IMM16_X0_HW3 =   42;
2432 enum R_TILEGX_IMM16_X1_HW3 =   43;
2433 enum R_TILEGX_IMM16_X0_HW0_LAST = 44;
2434 enum R_TILEGX_IMM16_X1_HW0_LAST = 45;
2435 enum R_TILEGX_IMM16_X0_HW1_LAST = 46;
2436 enum R_TILEGX_IMM16_X1_HW1_LAST = 47;
2437 enum R_TILEGX_IMM16_X0_HW2_LAST = 48;
2438 enum R_TILEGX_IMM16_X1_HW2_LAST = 49;
2439 enum R_TILEGX_IMM16_X0_HW0_PCREL = 50;
2440 enum R_TILEGX_IMM16_X1_HW0_PCREL = 51;
2441 enum R_TILEGX_IMM16_X0_HW1_PCREL = 52;
2442 enum R_TILEGX_IMM16_X1_HW1_PCREL = 53;
2443 enum R_TILEGX_IMM16_X0_HW2_PCREL = 54;
2444 enum R_TILEGX_IMM16_X1_HW2_PCREL = 55;
2445 enum R_TILEGX_IMM16_X0_HW3_PCREL = 56;
2446 enum R_TILEGX_IMM16_X1_HW3_PCREL = 57;
2447 enum R_TILEGX_IMM16_X0_HW0_LAST_PCREL = 58;
2448 enum R_TILEGX_IMM16_X1_HW0_LAST_PCREL = 59;
2449 enum R_TILEGX_IMM16_X0_HW1_LAST_PCREL = 60;
2450 enum R_TILEGX_IMM16_X1_HW1_LAST_PCREL = 61;
2451 enum R_TILEGX_IMM16_X0_HW2_LAST_PCREL = 62;
2452 enum R_TILEGX_IMM16_X1_HW2_LAST_PCREL = 63;
2453 enum R_TILEGX_IMM16_X0_HW0_GOT = 64;
2454 enum R_TILEGX_IMM16_X1_HW0_GOT = 65;
2455 enum R_TILEGX_IMM16_X0_HW0_PLT_PCREL = 66;
2456 enum R_TILEGX_IMM16_X1_HW0_PLT_PCREL = 67;
2457 enum R_TILEGX_IMM16_X0_HW1_PLT_PCREL = 68;
2458 enum R_TILEGX_IMM16_X1_HW1_PLT_PCREL = 69;
2459 enum R_TILEGX_IMM16_X0_HW2_PLT_PCREL = 70;
2460 enum R_TILEGX_IMM16_X1_HW2_PLT_PCREL = 71;
2461 enum R_TILEGX_IMM16_X0_HW0_LAST_GOT = 72;
2462 enum R_TILEGX_IMM16_X1_HW0_LAST_GOT = 73;
2463 enum R_TILEGX_IMM16_X0_HW1_LAST_GOT = 74;
2464 enum R_TILEGX_IMM16_X1_HW1_LAST_GOT = 75;
2465 enum R_TILEGX_IMM16_X0_HW3_PLT_PCREL = 76;
2466 enum R_TILEGX_IMM16_X1_HW3_PLT_PCREL = 77;
2467 enum R_TILEGX_IMM16_X0_HW0_TLS_GD = 78;
2468 enum R_TILEGX_IMM16_X1_HW0_TLS_GD = 79;
2469 enum R_TILEGX_IMM16_X0_HW0_TLS_LE = 80;
2470 enum R_TILEGX_IMM16_X1_HW0_TLS_LE = 81;
2471 enum R_TILEGX_IMM16_X0_HW0_LAST_TLS_LE = 82;
2472 enum R_TILEGX_IMM16_X1_HW0_LAST_TLS_LE = 83;
2473 enum R_TILEGX_IMM16_X0_HW1_LAST_TLS_LE = 84;
2474 enum R_TILEGX_IMM16_X1_HW1_LAST_TLS_LE = 85;
2475 enum R_TILEGX_IMM16_X0_HW0_LAST_TLS_GD = 86;
2476 enum R_TILEGX_IMM16_X1_HW0_LAST_TLS_GD = 87;
2477 enum R_TILEGX_IMM16_X0_HW1_LAST_TLS_GD = 88;
2478 enum R_TILEGX_IMM16_X1_HW1_LAST_TLS_GD = 89;
2479 enum R_TILEGX_IMM16_X0_HW0_TLS_IE = 92;
2480 enum R_TILEGX_IMM16_X1_HW0_TLS_IE = 93;
2481 enum R_TILEGX_IMM16_X0_HW0_LAST_PLT_PCREL = 94;
2482 enum R_TILEGX_IMM16_X1_HW0_LAST_PLT_PCREL = 95;
2483 enum R_TILEGX_IMM16_X0_HW1_LAST_PLT_PCREL = 96;
2484 enum R_TILEGX_IMM16_X1_HW1_LAST_PLT_PCREL = 97;
2485 enum R_TILEGX_IMM16_X0_HW2_LAST_PLT_PCREL = 98;
2486 enum R_TILEGX_IMM16_X1_HW2_LAST_PLT_PCREL = 99;
2487 enum R_TILEGX_IMM16_X0_HW0_LAST_TLS_IE = 100;
2488 enum R_TILEGX_IMM16_X1_HW0_LAST_TLS_IE = 101;
2489 enum R_TILEGX_IMM16_X0_HW1_LAST_TLS_IE = 102;
2490 enum R_TILEGX_IMM16_X1_HW1_LAST_TLS_IE = 103;
2491 enum R_TILEGX_TLS_DTPMOD64 =   106;
2492 enum R_TILEGX_TLS_DTPOFF64 =   107;
2493 enum R_TILEGX_TLS_TPOFF64 =    108;
2494 enum R_TILEGX_TLS_DTPMOD32 =   109;
2495 enum R_TILEGX_TLS_DTPOFF32 =   110;
2496 enum R_TILEGX_TLS_TPOFF32 =    111;
2497 enum R_TILEGX_TLS_GD_CALL =    112;
2498 enum R_TILEGX_IMM8_X0_TLS_GD_ADD = 113;
2499 enum R_TILEGX_IMM8_X1_TLS_GD_ADD = 114;
2500 enum R_TILEGX_IMM8_Y0_TLS_GD_ADD = 115;
2501 enum R_TILEGX_IMM8_Y1_TLS_GD_ADD = 116;
2502 enum R_TILEGX_TLS_IE_LOAD =    117;
2503 enum R_TILEGX_IMM8_X0_TLS_ADD = 118;
2504 enum R_TILEGX_IMM8_X1_TLS_ADD = 119;
2505 enum R_TILEGX_IMM8_Y0_TLS_ADD = 120;
2506 enum R_TILEGX_IMM8_Y1_TLS_ADD = 121;
2507 
2508 enum R_TILEGX_GNU_VTINHERIT =  128;
2509 enum R_TILEGX_GNU_VTENTRY =    129;
2510 
2511 enum R_TILEGX_NUM =            130;
2512 
2513 enum EF_RISCV_RVC =              0x0001;
2514 enum EF_RISCV_FLOAT_ABI =        0x0006;
2515 enum EF_RISCV_FLOAT_ABI_SOFT =   0x0000;
2516 enum EF_RISCV_FLOAT_ABI_SINGLE = 0x0002;
2517 enum EF_RISCV_FLOAT_ABI_DOUBLE = 0x0004;
2518 enum EF_RISCV_FLOAT_ABI_QUAD =   0x0006;
2519 enum R_RISCV_NONE =            0;
2520 enum R_RISCV_32 =              1;
2521 enum R_RISCV_64 =              2;
2522 enum R_RISCV_RELATIVE =        3;
2523 enum R_RISCV_COPY =            4;
2524 enum R_RISCV_JUMP_SLOT =       5;
2525 enum R_RISCV_TLS_DTPMOD32 =    6;
2526 enum R_RISCV_TLS_DTPMOD64 =    7;
2527 enum R_RISCV_TLS_DTPREL32 =    8;
2528 enum R_RISCV_TLS_DTPREL64 =    9;
2529 enum R_RISCV_TLS_TPREL32 =     10;
2530 enum R_RISCV_TLS_TPREL64 =     11;
2531 enum R_RISCV_BRANCH =          16;
2532 enum R_RISCV_JAL =             17;
2533 enum R_RISCV_CALL =            18;
2534 enum R_RISCV_CALL_PLT =        19;
2535 enum R_RISCV_GOT_HI20 =        20;
2536 enum R_RISCV_TLS_GOT_HI20 =    21;
2537 enum R_RISCV_TLS_GD_HI20 =     22;
2538 enum R_RISCV_PCREL_HI20 =      23;
2539 enum R_RISCV_PCREL_LO12_I =    24;
2540 enum R_RISCV_PCREL_LO12_S =    25;
2541 enum R_RISCV_HI20 =            26;
2542 enum R_RISCV_LO12_I =          27;
2543 enum R_RISCV_LO12_S =          28;
2544 enum R_RISCV_TPREL_HI20 =      29;
2545 enum R_RISCV_TPREL_LO12_I =    30;
2546 enum R_RISCV_TPREL_LO12_S =    31;
2547 enum R_RISCV_TPREL_ADD =       32;
2548 enum R_RISCV_ADD8 =            33;
2549 enum R_RISCV_ADD16 =           34;
2550 enum R_RISCV_ADD32 =           35;
2551 enum R_RISCV_ADD64 =           36;
2552 enum R_RISCV_SUB8 =            37;
2553 enum R_RISCV_SUB16 =           38;
2554 enum R_RISCV_SUB32 =           39;
2555 enum R_RISCV_SUB64 =           40;
2556 enum R_RISCV_GNU_VTINHERIT =   41;
2557 enum R_RISCV_GNU_VTENTRY =     42;
2558 enum R_RISCV_ALIGN =           43;
2559 enum R_RISCV_RVC_BRANCH =      44;
2560 enum R_RISCV_RVC_JUMP =        45;
2561 enum R_RISCV_RVC_LUI =         46;
2562 enum R_RISCV_GPREL_I =         47;
2563 enum R_RISCV_GPREL_S =         48;
2564 enum R_RISCV_TPREL_I =         49;
2565 enum R_RISCV_TPREL_S =         50;
2566 enum R_RISCV_RELAX =           51;
2567 enum R_RISCV_SUB6 =            52;
2568 enum R_RISCV_SET6 =            53;
2569 enum R_RISCV_SET8 =            54;
2570 enum R_RISCV_SET16 =           55;
2571 enum R_RISCV_SET32 =           56;
2572 enum R_RISCV_32_PCREL =        57;
2573 enum R_RISCV_IRELATIVE =       58;
2574 enum R_RISCV_NUM =             59;