1This is bfd.info, produced by makeinfo version 4.8 from bfd.texinfo. 2 3START-INFO-DIR-ENTRY 4* Bfd: (bfd). The Binary File Descriptor library. 5END-INFO-DIR-ENTRY 6 7 This file documents the BFD library. 8 9 Copyright (C) 1991, 2000, 2001, 2003, 2006, 2007 Free Software 10Foundation, Inc. 11 12 Permission is granted to copy, distribute and/or modify this document 13under the terms of the GNU Free Documentation License, Version 1.1 or 14any later version published by the Free Software Foundation; with the 15Invariant Sections being "GNU General Public License" and "Funding Free 16Software", the Front-Cover texts being (a) (see below), and with the 17Back-Cover Texts being (b) (see below). A copy of the license is 18included in the section entitled "GNU Free Documentation License". 19 20 (a) The FSF's Front-Cover Text is: 21 22 A GNU Manual 23 24 (b) The FSF's Back-Cover Text is: 25 26 You have freedom to copy and modify this GNU Manual, like GNU 27software. Copies published by the Free Software Foundation raise 28funds for GNU development. 29 30 31File: bfd.info, Node: Top, Next: Overview, Prev: (dir), Up: (dir) 32 33 This file documents the binary file descriptor library libbfd. 34 35* Menu: 36 37* Overview:: Overview of BFD 38* BFD front end:: BFD front end 39* BFD back ends:: BFD back ends 40* GNU Free Documentation License:: GNU Free Documentation License 41* BFD Index:: BFD Index 42 43 44File: bfd.info, Node: Overview, Next: BFD front end, Prev: Top, Up: Top 45 461 Introduction 47************** 48 49BFD is a package which allows applications to use the same routines to 50operate on object files whatever the object file format. A new object 51file format can be supported simply by creating a new BFD back end and 52adding it to the library. 53 54 BFD is split into two parts: the front end, and the back ends (one 55for each object file format). 56 * The front end of BFD provides the interface to the user. It manages 57 memory and various canonical data structures. The front end also 58 decides which back end to use and when to call back end routines. 59 60 * The back ends provide BFD its view of the real world. Each back 61 end provides a set of calls which the BFD front end can use to 62 maintain its canonical form. The back ends also may keep around 63 information for their own use, for greater efficiency. 64 65* Menu: 66 67* History:: History 68* How It Works:: How It Works 69* What BFD Version 2 Can Do:: What BFD Version 2 Can Do 70 71 72File: bfd.info, Node: History, Next: How It Works, Prev: Overview, Up: Overview 73 741.1 History 75=========== 76 77One spur behind BFD was the desire, on the part of the GNU 960 team at 78Intel Oregon, for interoperability of applications on their COFF and 79b.out file formats. Cygnus was providing GNU support for the team, and 80was contracted to provide the required functionality. 81 82 The name came from a conversation David Wallace was having with 83Richard Stallman about the library: RMS said that it would be quite 84hard--David said "BFD". Stallman was right, but the name stuck. 85 86 At the same time, Ready Systems wanted much the same thing, but for 87different object file formats: IEEE-695, Oasys, Srecords, a.out and 68k 88coff. 89 90 BFD was first implemented by members of Cygnus Support; Steve 91Chamberlain (`sac@cygnus.com'), John Gilmore (`gnu@cygnus.com'), K. 92Richard Pixley (`rich@cygnus.com') and David Henkel-Wallace 93(`gumby@cygnus.com'). 94 95 96File: bfd.info, Node: How It Works, Next: What BFD Version 2 Can Do, Prev: History, Up: Overview 97 981.2 How To Use BFD 99================== 100 101To use the library, include `bfd.h' and link with `libbfd.a'. 102 103 BFD provides a common interface to the parts of an object file for a 104calling application. 105 106 When an application successfully opens a target file (object, 107archive, or whatever), a pointer to an internal structure is returned. 108This pointer points to a structure called `bfd', described in `bfd.h'. 109Our convention is to call this pointer a BFD, and instances of it 110within code `abfd'. All operations on the target object file are 111applied as methods to the BFD. The mapping is defined within `bfd.h' 112in a set of macros, all beginning with `bfd_' to reduce namespace 113pollution. 114 115 For example, this sequence does what you would probably expect: 116return the number of sections in an object file attached to a BFD 117`abfd'. 118 119 #include "bfd.h" 120 121 unsigned int number_of_sections (abfd) 122 bfd *abfd; 123 { 124 return bfd_count_sections (abfd); 125 } 126 127 The abstraction used within BFD is that an object file has: 128 129 * a header, 130 131 * a number of sections containing raw data (*note Sections::), 132 133 * a set of relocations (*note Relocations::), and 134 135 * some symbol information (*note Symbols::). 136 Also, BFDs opened for archives have the additional attribute of an 137index and contain subordinate BFDs. This approach is fine for a.out and 138coff, but loses efficiency when applied to formats such as S-records and 139IEEE-695. 140 141 142File: bfd.info, Node: What BFD Version 2 Can Do, Prev: How It Works, Up: Overview 143 1441.3 What BFD Version 2 Can Do 145============================= 146 147When an object file is opened, BFD subroutines automatically determine 148the format of the input object file. They then build a descriptor in 149memory with pointers to routines that will be used to access elements of 150the object file's data structures. 151 152 As different information from the object files is required, BFD 153reads from different sections of the file and processes them. For 154example, a very common operation for the linker is processing symbol 155tables. Each BFD back end provides a routine for converting between 156the object file's representation of symbols and an internal canonical 157format. When the linker asks for the symbol table of an object file, it 158calls through a memory pointer to the routine from the relevant BFD 159back end which reads and converts the table into a canonical form. The 160linker then operates upon the canonical form. When the link is finished 161and the linker writes the output file's symbol table, another BFD back 162end routine is called to take the newly created symbol table and 163convert it into the chosen output format. 164 165* Menu: 166 167* BFD information loss:: Information Loss 168* Canonical format:: The BFD canonical object-file format 169 170 171File: bfd.info, Node: BFD information loss, Next: Canonical format, Up: What BFD Version 2 Can Do 172 1731.3.1 Information Loss 174---------------------- 175 176_Information can be lost during output._ The output formats supported 177by BFD do not provide identical facilities, and information which can 178be described in one form has nowhere to go in another format. One 179example of this is alignment information in `b.out'. There is nowhere 180in an `a.out' format file to store alignment information on the 181contained data, so when a file is linked from `b.out' and an `a.out' 182image is produced, alignment information will not propagate to the 183output file. (The linker will still use the alignment information 184internally, so the link is performed correctly). 185 186 Another example is COFF section names. COFF files may contain an 187unlimited number of sections, each one with a textual section name. If 188the target of the link is a format which does not have many sections 189(e.g., `a.out') or has sections without names (e.g., the Oasys format), 190the link cannot be done simply. You can circumvent this problem by 191describing the desired input-to-output section mapping with the linker 192command language. 193 194 _Information can be lost during canonicalization._ The BFD internal 195canonical form of the external formats is not exhaustive; there are 196structures in input formats for which there is no direct representation 197internally. This means that the BFD back ends cannot maintain all 198possible data richness through the transformation between external to 199internal and back to external formats. 200 201 This limitation is only a problem when an application reads one 202format and writes another. Each BFD back end is responsible for 203maintaining as much data as possible, and the internal BFD canonical 204form has structures which are opaque to the BFD core, and exported only 205to the back ends. When a file is read in one format, the canonical form 206is generated for BFD and the application. At the same time, the back 207end saves away any information which may otherwise be lost. If the data 208is then written back in the same format, the back end routine will be 209able to use the canonical form provided by the BFD core as well as the 210information it prepared earlier. Since there is a great deal of 211commonality between back ends, there is no information lost when 212linking or copying big endian COFF to little endian COFF, or `a.out' to 213`b.out'. When a mixture of formats is linked, the information is only 214lost from the files whose format differs from the destination. 215 216 217File: bfd.info, Node: Canonical format, Prev: BFD information loss, Up: What BFD Version 2 Can Do 218 2191.3.2 The BFD canonical object-file format 220------------------------------------------ 221 222The greatest potential for loss of information occurs when there is the 223least overlap between the information provided by the source format, 224that stored by the canonical format, and that needed by the destination 225format. A brief description of the canonical form may help you 226understand which kinds of data you can count on preserving across 227conversions. 228 229_files_ 230 Information stored on a per-file basis includes target machine 231 architecture, particular implementation format type, a demand 232 pageable bit, and a write protected bit. Information like Unix 233 magic numbers is not stored here--only the magic numbers' meaning, 234 so a `ZMAGIC' file would have both the demand pageable bit and the 235 write protected text bit set. The byte order of the target is 236 stored on a per-file basis, so that big- and little-endian object 237 files may be used with one another. 238 239_sections_ 240 Each section in the input file contains the name of the section, 241 the section's original address in the object file, size and 242 alignment information, various flags, and pointers into other BFD 243 data structures. 244 245_symbols_ 246 Each symbol contains a pointer to the information for the object 247 file which originally defined it, its name, its value, and various 248 flag bits. When a BFD back end reads in a symbol table, it 249 relocates all symbols to make them relative to the base of the 250 section where they were defined. Doing this ensures that each 251 symbol points to its containing section. Each symbol also has a 252 varying amount of hidden private data for the BFD back end. Since 253 the symbol points to the original file, the private data format 254 for that symbol is accessible. `ld' can operate on a collection 255 of symbols of wildly different formats without problems. 256 257 Normal global and simple local symbols are maintained on output, 258 so an output file (no matter its format) will retain symbols 259 pointing to functions and to global, static, and common variables. 260 Some symbol information is not worth retaining; in `a.out', type 261 information is stored in the symbol table as long symbol names. 262 This information would be useless to most COFF debuggers; the 263 linker has command line switches to allow users to throw it away. 264 265 There is one word of type information within the symbol, so if the 266 format supports symbol type information within symbols (for 267 example, COFF, IEEE, Oasys) and the type is simple enough to fit 268 within one word (nearly everything but aggregates), the 269 information will be preserved. 270 271_relocation level_ 272 Each canonical BFD relocation record contains a pointer to the 273 symbol to relocate to, the offset of the data to relocate, the 274 section the data is in, and a pointer to a relocation type 275 descriptor. Relocation is performed by passing messages through 276 the relocation type descriptor and the symbol pointer. Therefore, 277 relocations can be performed on output data using a relocation 278 method that is only available in one of the input formats. For 279 instance, Oasys provides a byte relocation format. A relocation 280 record requesting this relocation type would point indirectly to a 281 routine to perform this, so the relocation may be performed on a 282 byte being written to a 68k COFF file, even though 68k COFF has no 283 such relocation type. 284 285_line numbers_ 286 Object formats can contain, for debugging purposes, some form of 287 mapping between symbols, source line numbers, and addresses in the 288 output file. These addresses have to be relocated along with the 289 symbol information. Each symbol with an associated list of line 290 number records points to the first record of the list. The head 291 of a line number list consists of a pointer to the symbol, which 292 allows finding out the address of the function whose line number 293 is being described. The rest of the list is made up of pairs: 294 offsets into the section and line numbers. Any format which can 295 simply derive this information can pass it successfully between 296 formats (COFF, IEEE and Oasys). 297 298 299File: bfd.info, Node: BFD front end, Next: BFD back ends, Prev: Overview, Up: Top 300 3012 BFD Front End 302*************** 303 3042.1 `typedef bfd' 305================= 306 307A BFD has type `bfd'; objects of this type are the cornerstone of any 308application using BFD. Using BFD consists of making references though 309the BFD and to data in the BFD. 310 311 Here is the structure that defines the type `bfd'. It contains the 312major data about the file and pointers to the rest of the data. 313 314 315 struct bfd 316 { 317 /* A unique identifier of the BFD */ 318 unsigned int id; 319 320 /* The filename the application opened the BFD with. */ 321 const char *filename; 322 323 /* A pointer to the target jump table. */ 324 const struct bfd_target *xvec; 325 326 /* The IOSTREAM, and corresponding IO vector that provide access 327 to the file backing the BFD. */ 328 void *iostream; 329 const struct bfd_iovec *iovec; 330 331 /* Is the file descriptor being cached? That is, can it be closed as 332 needed, and re-opened when accessed later? */ 333 bfd_boolean cacheable; 334 335 /* Marks whether there was a default target specified when the 336 BFD was opened. This is used to select which matching algorithm 337 to use to choose the back end. */ 338 bfd_boolean target_defaulted; 339 340 /* The caching routines use these to maintain a 341 least-recently-used list of BFDs. */ 342 struct bfd *lru_prev, *lru_next; 343 344 /* When a file is closed by the caching routines, BFD retains 345 state information on the file here... */ 346 ufile_ptr where; 347 348 /* ... and here: (``once'' means at least once). */ 349 bfd_boolean opened_once; 350 351 /* Set if we have a locally maintained mtime value, rather than 352 getting it from the file each time. */ 353 bfd_boolean mtime_set; 354 355 /* File modified time, if mtime_set is TRUE. */ 356 long mtime; 357 358 /* Reserved for an unimplemented file locking extension. */ 359 int ifd; 360 361 /* The format which belongs to the BFD. (object, core, etc.) */ 362 bfd_format format; 363 364 /* The direction with which the BFD was opened. */ 365 enum bfd_direction 366 { 367 no_direction = 0, 368 read_direction = 1, 369 write_direction = 2, 370 both_direction = 3 371 } 372 direction; 373 374 /* Format_specific flags. */ 375 flagword flags; 376 377 /* Currently my_archive is tested before adding origin to 378 anything. I believe that this can become always an add of 379 origin, with origin set to 0 for non archive files. */ 380 ufile_ptr origin; 381 382 /* Remember when output has begun, to stop strange things 383 from happening. */ 384 bfd_boolean output_has_begun; 385 386 /* A hash table for section names. */ 387 struct bfd_hash_table section_htab; 388 389 /* Pointer to linked list of sections. */ 390 struct bfd_section *sections; 391 392 /* The last section on the section list. */ 393 struct bfd_section *section_last; 394 395 /* The number of sections. */ 396 unsigned int section_count; 397 398 /* Stuff only useful for object files: 399 The start address. */ 400 bfd_vma start_address; 401 402 /* Used for input and output. */ 403 unsigned int symcount; 404 405 /* Symbol table for output BFD (with symcount entries). */ 406 struct bfd_symbol **outsymbols; 407 408 /* Used for slurped dynamic symbol tables. */ 409 unsigned int dynsymcount; 410 411 /* Pointer to structure which contains architecture information. */ 412 const struct bfd_arch_info *arch_info; 413 414 /* Flag set if symbols from this BFD should not be exported. */ 415 bfd_boolean no_export; 416 417 /* Stuff only useful for archives. */ 418 void *arelt_data; 419 struct bfd *my_archive; /* The containing archive BFD. */ 420 struct bfd *archive_next; /* The next BFD in the archive. */ 421 struct bfd *archive_head; /* The first BFD in the archive. */ 422 bfd_boolean has_armap; 423 424 /* A chain of BFD structures involved in a link. */ 425 struct bfd *link_next; 426 427 /* A field used by _bfd_generic_link_add_archive_symbols. This will 428 be used only for archive elements. */ 429 int archive_pass; 430 431 /* Used by the back end to hold private data. */ 432 union 433 { 434 struct aout_data_struct *aout_data; 435 struct artdata *aout_ar_data; 436 struct _oasys_data *oasys_obj_data; 437 struct _oasys_ar_data *oasys_ar_data; 438 struct coff_tdata *coff_obj_data; 439 struct pe_tdata *pe_obj_data; 440 struct xcoff_tdata *xcoff_obj_data; 441 struct ecoff_tdata *ecoff_obj_data; 442 struct ieee_data_struct *ieee_data; 443 struct ieee_ar_data_struct *ieee_ar_data; 444 struct srec_data_struct *srec_data; 445 struct ihex_data_struct *ihex_data; 446 struct tekhex_data_struct *tekhex_data; 447 struct elf_obj_tdata *elf_obj_data; 448 struct nlm_obj_tdata *nlm_obj_data; 449 struct bout_data_struct *bout_data; 450 struct mmo_data_struct *mmo_data; 451 struct sun_core_struct *sun_core_data; 452 struct sco5_core_struct *sco5_core_data; 453 struct trad_core_struct *trad_core_data; 454 struct som_data_struct *som_data; 455 struct hpux_core_struct *hpux_core_data; 456 struct hppabsd_core_struct *hppabsd_core_data; 457 struct sgi_core_struct *sgi_core_data; 458 struct lynx_core_struct *lynx_core_data; 459 struct osf_core_struct *osf_core_data; 460 struct cisco_core_struct *cisco_core_data; 461 struct versados_data_struct *versados_data; 462 struct netbsd_core_struct *netbsd_core_data; 463 struct mach_o_data_struct *mach_o_data; 464 struct mach_o_fat_data_struct *mach_o_fat_data; 465 struct bfd_pef_data_struct *pef_data; 466 struct bfd_pef_xlib_data_struct *pef_xlib_data; 467 struct bfd_sym_data_struct *sym_data; 468 void *any; 469 } 470 tdata; 471 472 /* Used by the application to hold private data. */ 473 void *usrdata; 474 475 /* Where all the allocated stuff under this BFD goes. This is a 476 struct objalloc *, but we use void * to avoid requiring the inclusion 477 of objalloc.h. */ 478 void *memory; 479 }; 480 4812.2 Error reporting 482=================== 483 484Most BFD functions return nonzero on success (check their individual 485documentation for precise semantics). On an error, they call 486`bfd_set_error' to set an error condition that callers can check by 487calling `bfd_get_error'. If that returns `bfd_error_system_call', then 488check `errno'. 489 490 The easiest way to report a BFD error to the user is to use 491`bfd_perror'. 492 4932.2.1 Type `bfd_error_type' 494--------------------------- 495 496The values returned by `bfd_get_error' are defined by the enumerated 497type `bfd_error_type'. 498 499 500 typedef enum bfd_error 501 { 502 bfd_error_no_error = 0, 503 bfd_error_system_call, 504 bfd_error_invalid_target, 505 bfd_error_wrong_format, 506 bfd_error_wrong_object_format, 507 bfd_error_invalid_operation, 508 bfd_error_no_memory, 509 bfd_error_no_symbols, 510 bfd_error_no_armap, 511 bfd_error_no_more_archived_files, 512 bfd_error_malformed_archive, 513 bfd_error_file_not_recognized, 514 bfd_error_file_ambiguously_recognized, 515 bfd_error_no_contents, 516 bfd_error_nonrepresentable_section, 517 bfd_error_no_debug_section, 518 bfd_error_bad_value, 519 bfd_error_file_truncated, 520 bfd_error_file_too_big, 521 bfd_error_on_input, 522 bfd_error_invalid_error_code 523 } 524 bfd_error_type; 525 5262.2.1.1 `bfd_get_error' 527....................... 528 529*Synopsis* 530 bfd_error_type bfd_get_error (void); 531 *Description* 532Return the current BFD error condition. 533 5342.2.1.2 `bfd_set_error' 535....................... 536 537*Synopsis* 538 void bfd_set_error (bfd_error_type error_tag, ...); 539 *Description* 540Set the BFD error condition to be ERROR_TAG. If ERROR_TAG is 541bfd_error_on_input, then this function takes two more parameters, the 542input bfd where the error occurred, and the bfd_error_type error. 543 5442.2.1.3 `bfd_errmsg' 545.................... 546 547*Synopsis* 548 const char *bfd_errmsg (bfd_error_type error_tag); 549 *Description* 550Return a string describing the error ERROR_TAG, or the system error if 551ERROR_TAG is `bfd_error_system_call'. 552 5532.2.1.4 `bfd_perror' 554.................... 555 556*Synopsis* 557 void bfd_perror (const char *message); 558 *Description* 559Print to the standard error stream a string describing the last BFD 560error that occurred, or the last system error if the last BFD error was 561a system call failure. If MESSAGE is non-NULL and non-empty, the error 562string printed is preceded by MESSAGE, a colon, and a space. It is 563followed by a newline. 564 5652.2.2 BFD error handler 566----------------------- 567 568Some BFD functions want to print messages describing the problem. They 569call a BFD error handler function. This function may be overridden by 570the program. 571 572 The BFD error handler acts like printf. 573 574 575 typedef void (*bfd_error_handler_type) (const char *, ...); 576 5772.2.2.1 `bfd_set_error_handler' 578............................... 579 580*Synopsis* 581 bfd_error_handler_type bfd_set_error_handler (bfd_error_handler_type); 582 *Description* 583Set the BFD error handler function. Returns the previous function. 584 5852.2.2.2 `bfd_set_error_program_name' 586.................................... 587 588*Synopsis* 589 void bfd_set_error_program_name (const char *); 590 *Description* 591Set the program name to use when printing a BFD error. This is printed 592before the error message followed by a colon and space. The string 593must not be changed after it is passed to this function. 594 5952.2.2.3 `bfd_get_error_handler' 596............................... 597 598*Synopsis* 599 bfd_error_handler_type bfd_get_error_handler (void); 600 *Description* 601Return the BFD error handler function. 602 6032.3 Miscellaneous 604================= 605 6062.3.1 Miscellaneous functions 607----------------------------- 608 6092.3.1.1 `bfd_get_reloc_upper_bound' 610................................... 611 612*Synopsis* 613 long bfd_get_reloc_upper_bound (bfd *abfd, asection *sect); 614 *Description* 615Return the number of bytes required to store the relocation information 616associated with section SECT attached to bfd ABFD. If an error occurs, 617return -1. 618 6192.3.1.2 `bfd_canonicalize_reloc' 620................................ 621 622*Synopsis* 623 long bfd_canonicalize_reloc 624 (bfd *abfd, asection *sec, arelent **loc, asymbol **syms); 625 *Description* 626Call the back end associated with the open BFD ABFD and translate the 627external form of the relocation information attached to SEC into the 628internal canonical form. Place the table into memory at LOC, which has 629been preallocated, usually by a call to `bfd_get_reloc_upper_bound'. 630Returns the number of relocs, or -1 on error. 631 632 The SYMS table is also needed for horrible internal magic reasons. 633 6342.3.1.3 `bfd_set_reloc' 635....................... 636 637*Synopsis* 638 void bfd_set_reloc 639 (bfd *abfd, asection *sec, arelent **rel, unsigned int count); 640 *Description* 641Set the relocation pointer and count within section SEC to the values 642REL and COUNT. The argument ABFD is ignored. 643 6442.3.1.4 `bfd_set_file_flags' 645............................ 646 647*Synopsis* 648 bfd_boolean bfd_set_file_flags (bfd *abfd, flagword flags); 649 *Description* 650Set the flag word in the BFD ABFD to the value FLAGS. 651 652 Possible errors are: 653 * `bfd_error_wrong_format' - The target bfd was not of object format. 654 655 * `bfd_error_invalid_operation' - The target bfd was open for 656 reading. 657 658 * `bfd_error_invalid_operation' - The flag word contained a bit 659 which was not applicable to the type of file. E.g., an attempt 660 was made to set the `D_PAGED' bit on a BFD format which does not 661 support demand paging. 662 6632.3.1.5 `bfd_get_arch_size' 664........................... 665 666*Synopsis* 667 int bfd_get_arch_size (bfd *abfd); 668 *Description* 669Returns the architecture address size, in bits, as determined by the 670object file's format. For ELF, this information is included in the 671header. 672 673 *Returns* 674Returns the arch size in bits if known, `-1' otherwise. 675 6762.3.1.6 `bfd_get_sign_extend_vma' 677................................. 678 679*Synopsis* 680 int bfd_get_sign_extend_vma (bfd *abfd); 681 *Description* 682Indicates if the target architecture "naturally" sign extends an 683address. Some architectures implicitly sign extend address values when 684they are converted to types larger than the size of an address. For 685instance, bfd_get_start_address() will return an address sign extended 686to fill a bfd_vma when this is the case. 687 688 *Returns* 689Returns `1' if the target architecture is known to sign extend 690addresses, `0' if the target architecture is known to not sign extend 691addresses, and `-1' otherwise. 692 6932.3.1.7 `bfd_set_start_address' 694............................... 695 696*Synopsis* 697 bfd_boolean bfd_set_start_address (bfd *abfd, bfd_vma vma); 698 *Description* 699Make VMA the entry point of output BFD ABFD. 700 701 *Returns* 702Returns `TRUE' on success, `FALSE' otherwise. 703 7042.3.1.8 `bfd_get_gp_size' 705......................... 706 707*Synopsis* 708 unsigned int bfd_get_gp_size (bfd *abfd); 709 *Description* 710Return the maximum size of objects to be optimized using the GP 711register under MIPS ECOFF. This is typically set by the `-G' argument 712to the compiler, assembler or linker. 713 7142.3.1.9 `bfd_set_gp_size' 715......................... 716 717*Synopsis* 718 void bfd_set_gp_size (bfd *abfd, unsigned int i); 719 *Description* 720Set the maximum size of objects to be optimized using the GP register 721under ECOFF or MIPS ELF. This is typically set by the `-G' argument to 722the compiler, assembler or linker. 723 7242.3.1.10 `bfd_scan_vma' 725....................... 726 727*Synopsis* 728 bfd_vma bfd_scan_vma (const char *string, const char **end, int base); 729 *Description* 730Convert, like `strtoul', a numerical expression STRING into a `bfd_vma' 731integer, and return that integer. (Though without as many bells and 732whistles as `strtoul'.) The expression is assumed to be unsigned 733(i.e., positive). If given a BASE, it is used as the base for 734conversion. A base of 0 causes the function to interpret the string in 735hex if a leading "0x" or "0X" is found, otherwise in octal if a leading 736zero is found, otherwise in decimal. 737 738 If the value would overflow, the maximum `bfd_vma' value is returned. 739 7402.3.1.11 `bfd_copy_private_header_data' 741....................................... 742 743*Synopsis* 744 bfd_boolean bfd_copy_private_header_data (bfd *ibfd, bfd *obfd); 745 *Description* 746Copy private BFD header information from the BFD IBFD to the the BFD 747OBFD. This copies information that may require sections to exist, but 748does not require symbol tables. Return `true' on success, `false' on 749error. Possible error returns are: 750 751 * `bfd_error_no_memory' - Not enough memory exists to create private 752 data for OBFD. 753 754 #define bfd_copy_private_header_data(ibfd, obfd) \ 755 BFD_SEND (obfd, _bfd_copy_private_header_data, \ 756 (ibfd, obfd)) 757 7582.3.1.12 `bfd_copy_private_bfd_data' 759.................................... 760 761*Synopsis* 762 bfd_boolean bfd_copy_private_bfd_data (bfd *ibfd, bfd *obfd); 763 *Description* 764Copy private BFD information from the BFD IBFD to the the BFD OBFD. 765Return `TRUE' on success, `FALSE' on error. Possible error returns are: 766 767 * `bfd_error_no_memory' - Not enough memory exists to create private 768 data for OBFD. 769 770 #define bfd_copy_private_bfd_data(ibfd, obfd) \ 771 BFD_SEND (obfd, _bfd_copy_private_bfd_data, \ 772 (ibfd, obfd)) 773 7742.3.1.13 `bfd_merge_private_bfd_data' 775..................................... 776 777*Synopsis* 778 bfd_boolean bfd_merge_private_bfd_data (bfd *ibfd, bfd *obfd); 779 *Description* 780Merge private BFD information from the BFD IBFD to the the output file 781BFD OBFD when linking. Return `TRUE' on success, `FALSE' on error. 782Possible error returns are: 783 784 * `bfd_error_no_memory' - Not enough memory exists to create private 785 data for OBFD. 786 787 #define bfd_merge_private_bfd_data(ibfd, obfd) \ 788 BFD_SEND (obfd, _bfd_merge_private_bfd_data, \ 789 (ibfd, obfd)) 790 7912.3.1.14 `bfd_set_private_flags' 792................................ 793 794*Synopsis* 795 bfd_boolean bfd_set_private_flags (bfd *abfd, flagword flags); 796 *Description* 797Set private BFD flag information in the BFD ABFD. Return `TRUE' on 798success, `FALSE' on error. Possible error returns are: 799 800 * `bfd_error_no_memory' - Not enough memory exists to create private 801 data for OBFD. 802 803 #define bfd_set_private_flags(abfd, flags) \ 804 BFD_SEND (abfd, _bfd_set_private_flags, (abfd, flags)) 805 8062.3.1.15 `Other functions' 807.......................... 808 809*Description* 810The following functions exist but have not yet been documented. 811 #define bfd_sizeof_headers(abfd, info) \ 812 BFD_SEND (abfd, _bfd_sizeof_headers, (abfd, info)) 813 814 #define bfd_find_nearest_line(abfd, sec, syms, off, file, func, line) \ 815 BFD_SEND (abfd, _bfd_find_nearest_line, \ 816 (abfd, sec, syms, off, file, func, line)) 817 818 #define bfd_find_line(abfd, syms, sym, file, line) \ 819 BFD_SEND (abfd, _bfd_find_line, \ 820 (abfd, syms, sym, file, line)) 821 822 #define bfd_find_inliner_info(abfd, file, func, line) \ 823 BFD_SEND (abfd, _bfd_find_inliner_info, \ 824 (abfd, file, func, line)) 825 826 #define bfd_debug_info_start(abfd) \ 827 BFD_SEND (abfd, _bfd_debug_info_start, (abfd)) 828 829 #define bfd_debug_info_end(abfd) \ 830 BFD_SEND (abfd, _bfd_debug_info_end, (abfd)) 831 832 #define bfd_debug_info_accumulate(abfd, section) \ 833 BFD_SEND (abfd, _bfd_debug_info_accumulate, (abfd, section)) 834 835 #define bfd_stat_arch_elt(abfd, stat) \ 836 BFD_SEND (abfd, _bfd_stat_arch_elt,(abfd, stat)) 837 838 #define bfd_update_armap_timestamp(abfd) \ 839 BFD_SEND (abfd, _bfd_update_armap_timestamp, (abfd)) 840 841 #define bfd_set_arch_mach(abfd, arch, mach)\ 842 BFD_SEND ( abfd, _bfd_set_arch_mach, (abfd, arch, mach)) 843 844 #define bfd_relax_section(abfd, section, link_info, again) \ 845 BFD_SEND (abfd, _bfd_relax_section, (abfd, section, link_info, again)) 846 847 #define bfd_gc_sections(abfd, link_info) \ 848 BFD_SEND (abfd, _bfd_gc_sections, (abfd, link_info)) 849 850 #define bfd_merge_sections(abfd, link_info) \ 851 BFD_SEND (abfd, _bfd_merge_sections, (abfd, link_info)) 852 853 #define bfd_is_group_section(abfd, sec) \ 854 BFD_SEND (abfd, _bfd_is_group_section, (abfd, sec)) 855 856 #define bfd_discard_group(abfd, sec) \ 857 BFD_SEND (abfd, _bfd_discard_group, (abfd, sec)) 858 859 #define bfd_link_hash_table_create(abfd) \ 860 BFD_SEND (abfd, _bfd_link_hash_table_create, (abfd)) 861 862 #define bfd_link_hash_table_free(abfd, hash) \ 863 BFD_SEND (abfd, _bfd_link_hash_table_free, (hash)) 864 865 #define bfd_link_add_symbols(abfd, info) \ 866 BFD_SEND (abfd, _bfd_link_add_symbols, (abfd, info)) 867 868 #define bfd_link_just_syms(abfd, sec, info) \ 869 BFD_SEND (abfd, _bfd_link_just_syms, (sec, info)) 870 871 #define bfd_final_link(abfd, info) \ 872 BFD_SEND (abfd, _bfd_final_link, (abfd, info)) 873 874 #define bfd_free_cached_info(abfd) \ 875 BFD_SEND (abfd, _bfd_free_cached_info, (abfd)) 876 877 #define bfd_get_dynamic_symtab_upper_bound(abfd) \ 878 BFD_SEND (abfd, _bfd_get_dynamic_symtab_upper_bound, (abfd)) 879 880 #define bfd_print_private_bfd_data(abfd, file)\ 881 BFD_SEND (abfd, _bfd_print_private_bfd_data, (abfd, file)) 882 883 #define bfd_canonicalize_dynamic_symtab(abfd, asymbols) \ 884 BFD_SEND (abfd, _bfd_canonicalize_dynamic_symtab, (abfd, asymbols)) 885 886 #define bfd_get_synthetic_symtab(abfd, count, syms, dyncount, dynsyms, ret) \ 887 BFD_SEND (abfd, _bfd_get_synthetic_symtab, (abfd, count, syms, \ 888 dyncount, dynsyms, ret)) 889 890 #define bfd_get_dynamic_reloc_upper_bound(abfd) \ 891 BFD_SEND (abfd, _bfd_get_dynamic_reloc_upper_bound, (abfd)) 892 893 #define bfd_canonicalize_dynamic_reloc(abfd, arels, asyms) \ 894 BFD_SEND (abfd, _bfd_canonicalize_dynamic_reloc, (abfd, arels, asyms)) 895 896 extern bfd_byte *bfd_get_relocated_section_contents 897 (bfd *, struct bfd_link_info *, struct bfd_link_order *, bfd_byte *, 898 bfd_boolean, asymbol **); 899 9002.3.1.16 `bfd_alt_mach_code' 901............................ 902 903*Synopsis* 904 bfd_boolean bfd_alt_mach_code (bfd *abfd, int alternative); 905 *Description* 906When more than one machine code number is available for the same 907machine type, this function can be used to switch between the preferred 908one (alternative == 0) and any others. Currently, only ELF supports 909this feature, with up to two alternate machine codes. 910 911 struct bfd_preserve 912 { 913 void *marker; 914 void *tdata; 915 flagword flags; 916 const struct bfd_arch_info *arch_info; 917 struct bfd_section *sections; 918 struct bfd_section *section_last; 919 unsigned int section_count; 920 struct bfd_hash_table section_htab; 921 }; 922 9232.3.1.17 `bfd_preserve_save' 924............................ 925 926*Synopsis* 927 bfd_boolean bfd_preserve_save (bfd *, struct bfd_preserve *); 928 *Description* 929When testing an object for compatibility with a particular target 930back-end, the back-end object_p function needs to set up certain fields 931in the bfd on successfully recognizing the object. This typically 932happens in a piecemeal fashion, with failures possible at many points. 933On failure, the bfd is supposed to be restored to its initial state, 934which is virtually impossible. However, restoring a subset of the bfd 935state works in practice. This function stores the subset and 936reinitializes the bfd. 937 9382.3.1.18 `bfd_preserve_restore' 939............................... 940 941*Synopsis* 942 void bfd_preserve_restore (bfd *, struct bfd_preserve *); 943 *Description* 944This function restores bfd state saved by bfd_preserve_save. If MARKER 945is non-NULL in struct bfd_preserve then that block and all subsequently 946bfd_alloc'd memory is freed. 947 9482.3.1.19 `bfd_preserve_finish' 949.............................. 950 951*Synopsis* 952 void bfd_preserve_finish (bfd *, struct bfd_preserve *); 953 *Description* 954This function should be called when the bfd state saved by 955bfd_preserve_save is no longer needed. ie. when the back-end object_p 956function returns with success. 957 9582.3.1.20 `bfd_emul_get_maxpagesize' 959................................... 960 961*Synopsis* 962 bfd_vma bfd_emul_get_maxpagesize (const char *); 963 *Description* 964Returns the maximum page size, in bytes, as determined by emulation. 965 966 *Returns* 967Returns the maximum page size in bytes for ELF, abort otherwise. 968 9692.3.1.21 `bfd_emul_set_maxpagesize' 970................................... 971 972*Synopsis* 973 void bfd_emul_set_maxpagesize (const char *, bfd_vma); 974 *Description* 975For ELF, set the maximum page size for the emulation. It is a no-op 976for other formats. 977 9782.3.1.22 `bfd_emul_get_commonpagesize' 979...................................... 980 981*Synopsis* 982 bfd_vma bfd_emul_get_commonpagesize (const char *); 983 *Description* 984Returns the common page size, in bytes, as determined by emulation. 985 986 *Returns* 987Returns the common page size in bytes for ELF, abort otherwise. 988 9892.3.1.23 `bfd_emul_set_commonpagesize' 990...................................... 991 992*Synopsis* 993 void bfd_emul_set_commonpagesize (const char *, bfd_vma); 994 *Description* 995For ELF, set the common page size for the emulation. It is a no-op for 996other formats. 997 9982.3.1.24 `bfd_demangle' 999....................... 1000 1001*Synopsis* 1002 char *bfd_demangle (bfd *, const char *, int); 1003 *Description* 1004Wrapper around cplus_demangle. Strips leading underscores and other 1005such chars that would otherwise confuse the demangler. If passed a g++ 1006v3 ABI mangled name, returns a buffer allocated with malloc holding the 1007demangled name. Returns NULL otherwise and on memory alloc failure. 1008 10092.3.1.25 `struct bfd_iovec' 1010........................... 1011 1012*Description* 1013The `struct bfd_iovec' contains the internal file I/O class. Each 1014`BFD' has an instance of this class and all file I/O is routed through 1015it (it is assumed that the instance implements all methods listed 1016below). 1017 struct bfd_iovec 1018 { 1019 /* To avoid problems with macros, a "b" rather than "f" 1020 prefix is prepended to each method name. */ 1021 /* Attempt to read/write NBYTES on ABFD's IOSTREAM storing/fetching 1022 bytes starting at PTR. Return the number of bytes actually 1023 transfered (a read past end-of-file returns less than NBYTES), 1024 or -1 (setting `bfd_error') if an error occurs. */ 1025 file_ptr (*bread) (struct bfd *abfd, void *ptr, file_ptr nbytes); 1026 file_ptr (*bwrite) (struct bfd *abfd, const void *ptr, 1027 file_ptr nbytes); 1028 /* Return the current IOSTREAM file offset, or -1 (setting `bfd_error' 1029 if an error occurs. */ 1030 file_ptr (*btell) (struct bfd *abfd); 1031 /* For the following, on successful completion a value of 0 is returned. 1032 Otherwise, a value of -1 is returned (and `bfd_error' is set). */ 1033 int (*bseek) (struct bfd *abfd, file_ptr offset, int whence); 1034 int (*bclose) (struct bfd *abfd); 1035 int (*bflush) (struct bfd *abfd); 1036 int (*bstat) (struct bfd *abfd, struct stat *sb); 1037 }; 1038 10392.3.1.26 `bfd_get_mtime' 1040........................ 1041 1042*Synopsis* 1043 long bfd_get_mtime (bfd *abfd); 1044 *Description* 1045Return the file modification time (as read from the file system, or 1046from the archive header for archive members). 1047 10482.3.1.27 `bfd_get_size' 1049....................... 1050 1051*Synopsis* 1052 file_ptr bfd_get_size (bfd *abfd); 1053 *Description* 1054Return the file size (as read from file system) for the file associated 1055with BFD ABFD. 1056 1057 The initial motivation for, and use of, this routine is not so we 1058can get the exact size of the object the BFD applies to, since that 1059might not be generally possible (archive members for example). It 1060would be ideal if someone could eventually modify it so that such 1061results were guaranteed. 1062 1063 Instead, we want to ask questions like "is this NNN byte sized 1064object I'm about to try read from file offset YYY reasonable?" As as 1065example of where we might do this, some object formats use string 1066tables for which the first `sizeof (long)' bytes of the table contain 1067the size of the table itself, including the size bytes. If an 1068application tries to read what it thinks is one of these string tables, 1069without some way to validate the size, and for some reason the size is 1070wrong (byte swapping error, wrong location for the string table, etc.), 1071the only clue is likely to be a read error when it tries to read the 1072table, or a "virtual memory exhausted" error when it tries to allocate 107315 bazillon bytes of space for the 15 bazillon byte table it is about 1074to read. This function at least allows us to answer the question, "is 1075the size reasonable?". 1076 1077* Menu: 1078 1079* Memory Usage:: 1080* Initialization:: 1081* Sections:: 1082* Symbols:: 1083* Archives:: 1084* Formats:: 1085* Relocations:: 1086* Core Files:: 1087* Targets:: 1088* Architectures:: 1089* Opening and Closing:: 1090* Internal:: 1091* File Caching:: 1092* Linker Functions:: 1093* Hash Tables:: 1094 1095 1096File: bfd.info, Node: Memory Usage, Next: Initialization, Prev: BFD front end, Up: BFD front end 1097 10982.4 Memory Usage 1099================ 1100 1101BFD keeps all of its internal structures in obstacks. There is one 1102obstack per open BFD file, into which the current state is stored. When 1103a BFD is closed, the obstack is deleted, and so everything which has 1104been allocated by BFD for the closing file is thrown away. 1105 1106 BFD does not free anything created by an application, but pointers 1107into `bfd' structures become invalid on a `bfd_close'; for example, 1108after a `bfd_close' the vector passed to `bfd_canonicalize_symtab' is 1109still around, since it has been allocated by the application, but the 1110data that it pointed to are lost. 1111 1112 The general rule is to not close a BFD until all operations dependent 1113upon data from the BFD have been completed, or all the data from within 1114the file has been copied. To help with the management of memory, there 1115is a function (`bfd_alloc_size') which returns the number of bytes in 1116obstacks associated with the supplied BFD. This could be used to select 1117the greediest open BFD, close it to reclaim the memory, perform some 1118operation and reopen the BFD again, to get a fresh copy of the data 1119structures. 1120 1121 1122File: bfd.info, Node: Initialization, Next: Sections, Prev: Memory Usage, Up: BFD front end 1123 11242.5 Initialization 1125================== 1126 11272.5.1 Initialization functions 1128------------------------------ 1129 1130These are the functions that handle initializing a BFD. 1131 11322.5.1.1 `bfd_init' 1133.................. 1134 1135*Synopsis* 1136 void bfd_init (void); 1137 *Description* 1138This routine must be called before any other BFD function to initialize 1139magical internal data structures. 1140 1141 1142File: bfd.info, Node: Sections, Next: Symbols, Prev: Initialization, Up: BFD front end 1143 11442.6 Sections 1145============ 1146 1147The raw data contained within a BFD is maintained through the section 1148abstraction. A single BFD may have any number of sections. It keeps 1149hold of them by pointing to the first; each one points to the next in 1150the list. 1151 1152 Sections are supported in BFD in `section.c'. 1153 1154* Menu: 1155 1156* Section Input:: 1157* Section Output:: 1158* typedef asection:: 1159* section prototypes:: 1160 1161 1162File: bfd.info, Node: Section Input, Next: Section Output, Prev: Sections, Up: Sections 1163 11642.6.1 Section input 1165------------------- 1166 1167When a BFD is opened for reading, the section structures are created 1168and attached to the BFD. 1169 1170 Each section has a name which describes the section in the outside 1171world--for example, `a.out' would contain at least three sections, 1172called `.text', `.data' and `.bss'. 1173 1174 Names need not be unique; for example a COFF file may have several 1175sections named `.data'. 1176 1177 Sometimes a BFD will contain more than the "natural" number of 1178sections. A back end may attach other sections containing constructor 1179data, or an application may add a section (using `bfd_make_section') to 1180the sections attached to an already open BFD. For example, the linker 1181creates an extra section `COMMON' for each input file's BFD to hold 1182information about common storage. 1183 1184 The raw data is not necessarily read in when the section descriptor 1185is created. Some targets may leave the data in place until a 1186`bfd_get_section_contents' call is made. Other back ends may read in 1187all the data at once. For example, an S-record file has to be read 1188once to determine the size of the data. An IEEE-695 file doesn't 1189contain raw data in sections, but data and relocation expressions 1190intermixed, so the data area has to be parsed to get out the data and 1191relocations. 1192 1193 1194File: bfd.info, Node: Section Output, Next: typedef asection, Prev: Section Input, Up: Sections 1195 11962.6.2 Section output 1197-------------------- 1198 1199To write a new object style BFD, the various sections to be written 1200have to be created. They are attached to the BFD in the same way as 1201input sections; data is written to the sections using 1202`bfd_set_section_contents'. 1203 1204 Any program that creates or combines sections (e.g., the assembler 1205and linker) must use the `asection' fields `output_section' and 1206`output_offset' to indicate the file sections to which each section 1207must be written. (If the section is being created from scratch, 1208`output_section' should probably point to the section itself and 1209`output_offset' should probably be zero.) 1210 1211 The data to be written comes from input sections attached (via 1212`output_section' pointers) to the output sections. The output section 1213structure can be considered a filter for the input section: the output 1214section determines the vma of the output data and the name, but the 1215input section determines the offset into the output section of the data 1216to be written. 1217 1218 E.g., to create a section "O", starting at 0x100, 0x123 long, 1219containing two subsections, "A" at offset 0x0 (i.e., at vma 0x100) and 1220"B" at offset 0x20 (i.e., at vma 0x120) the `asection' structures would 1221look like: 1222 1223 section name "A" 1224 output_offset 0x00 1225 size 0x20 1226 output_section -----------> section name "O" 1227 | vma 0x100 1228 section name "B" | size 0x123 1229 output_offset 0x20 | 1230 size 0x103 | 1231 output_section --------| 1232 12332.6.3 Link orders 1234----------------- 1235 1236The data within a section is stored in a "link_order". These are much 1237like the fixups in `gas'. The link_order abstraction allows a section 1238to grow and shrink within itself. 1239 1240 A link_order knows how big it is, and which is the next link_order 1241and where the raw data for it is; it also points to a list of 1242relocations which apply to it. 1243 1244 The link_order is used by the linker to perform relaxing on final 1245code. The compiler creates code which is as big as necessary to make 1246it work without relaxing, and the user can select whether to relax. 1247Sometimes relaxing takes a lot of time. The linker runs around the 1248relocations to see if any are attached to data which can be shrunk, if 1249so it does it on a link_order by link_order basis. 1250 1251 1252File: bfd.info, Node: typedef asection, Next: section prototypes, Prev: Section Output, Up: Sections 1253 12542.6.4 typedef asection 1255---------------------- 1256 1257Here is the section structure: 1258 1259 1260 typedef struct bfd_section 1261 { 1262 /* The name of the section; the name isn't a copy, the pointer is 1263 the same as that passed to bfd_make_section. */ 1264 const char *name; 1265 1266 /* A unique sequence number. */ 1267 int id; 1268 1269 /* Which section in the bfd; 0..n-1 as sections are created in a bfd. */ 1270 int index; 1271 1272 /* The next section in the list belonging to the BFD, or NULL. */ 1273 struct bfd_section *next; 1274 1275 /* The previous section in the list belonging to the BFD, or NULL. */ 1276 struct bfd_section *prev; 1277 1278 /* The field flags contains attributes of the section. Some 1279 flags are read in from the object file, and some are 1280 synthesized from other information. */ 1281 flagword flags; 1282 1283 #define SEC_NO_FLAGS 0x000 1284 1285 /* Tells the OS to allocate space for this section when loading. 1286 This is clear for a section containing debug information only. */ 1287 #define SEC_ALLOC 0x001 1288 1289 /* Tells the OS to load the section from the file when loading. 1290 This is clear for a .bss section. */ 1291 #define SEC_LOAD 0x002 1292 1293 /* The section contains data still to be relocated, so there is 1294 some relocation information too. */ 1295 #define SEC_RELOC 0x004 1296 1297 /* A signal to the OS that the section contains read only data. */ 1298 #define SEC_READONLY 0x008 1299 1300 /* The section contains code only. */ 1301 #define SEC_CODE 0x010 1302 1303 /* The section contains data only. */ 1304 #define SEC_DATA 0x020 1305 1306 /* The section will reside in ROM. */ 1307 #define SEC_ROM 0x040 1308 1309 /* The section contains constructor information. This section 1310 type is used by the linker to create lists of constructors and 1311 destructors used by `g++'. When a back end sees a symbol 1312 which should be used in a constructor list, it creates a new 1313 section for the type of name (e.g., `__CTOR_LIST__'), attaches 1314 the symbol to it, and builds a relocation. To build the lists 1315 of constructors, all the linker has to do is catenate all the 1316 sections called `__CTOR_LIST__' and relocate the data 1317 contained within - exactly the operations it would peform on 1318 standard data. */ 1319 #define SEC_CONSTRUCTOR 0x080 1320 1321 /* The section has contents - a data section could be 1322 `SEC_ALLOC' | `SEC_HAS_CONTENTS'; a debug section could be 1323 `SEC_HAS_CONTENTS' */ 1324 #define SEC_HAS_CONTENTS 0x100 1325 1326 /* An instruction to the linker to not output the section 1327 even if it has information which would normally be written. */ 1328 #define SEC_NEVER_LOAD 0x200 1329 1330 /* The section contains thread local data. */ 1331 #define SEC_THREAD_LOCAL 0x400 1332 1333 /* The section has GOT references. This flag is only for the 1334 linker, and is currently only used by the elf32-hppa back end. 1335 It will be set if global offset table references were detected 1336 in this section, which indicate to the linker that the section 1337 contains PIC code, and must be handled specially when doing a 1338 static link. */ 1339 #define SEC_HAS_GOT_REF 0x800 1340 1341 /* The section contains common symbols (symbols may be defined 1342 multiple times, the value of a symbol is the amount of 1343 space it requires, and the largest symbol value is the one 1344 used). Most targets have exactly one of these (which we 1345 translate to bfd_com_section_ptr), but ECOFF has two. */ 1346 #define SEC_IS_COMMON 0x1000 1347 1348 /* The section contains only debugging information. For 1349 example, this is set for ELF .debug and .stab sections. 1350 strip tests this flag to see if a section can be 1351 discarded. */ 1352 #define SEC_DEBUGGING 0x2000 1353 1354 /* The contents of this section are held in memory pointed to 1355 by the contents field. This is checked by bfd_get_section_contents, 1356 and the data is retrieved from memory if appropriate. */ 1357 #define SEC_IN_MEMORY 0x4000 1358 1359 /* The contents of this section are to be excluded by the 1360 linker for executable and shared objects unless those 1361 objects are to be further relocated. */ 1362 #define SEC_EXCLUDE 0x8000 1363 1364 /* The contents of this section are to be sorted based on the sum of 1365 the symbol and addend values specified by the associated relocation 1366 entries. Entries without associated relocation entries will be 1367 appended to the end of the section in an unspecified order. */ 1368 #define SEC_SORT_ENTRIES 0x10000 1369 1370 /* When linking, duplicate sections of the same name should be 1371 discarded, rather than being combined into a single section as 1372 is usually done. This is similar to how common symbols are 1373 handled. See SEC_LINK_DUPLICATES below. */ 1374 #define SEC_LINK_ONCE 0x20000 1375 1376 /* If SEC_LINK_ONCE is set, this bitfield describes how the linker 1377 should handle duplicate sections. */ 1378 #define SEC_LINK_DUPLICATES 0x40000 1379 1380 /* This value for SEC_LINK_DUPLICATES means that duplicate 1381 sections with the same name should simply be discarded. */ 1382 #define SEC_LINK_DUPLICATES_DISCARD 0x0 1383 1384 /* This value for SEC_LINK_DUPLICATES means that the linker 1385 should warn if there are any duplicate sections, although 1386 it should still only link one copy. */ 1387 #define SEC_LINK_DUPLICATES_ONE_ONLY 0x80000 1388 1389 /* This value for SEC_LINK_DUPLICATES means that the linker 1390 should warn if any duplicate sections are a different size. */ 1391 #define SEC_LINK_DUPLICATES_SAME_SIZE 0x100000 1392 1393 /* This value for SEC_LINK_DUPLICATES means that the linker 1394 should warn if any duplicate sections contain different 1395 contents. */ 1396 #define SEC_LINK_DUPLICATES_SAME_CONTENTS \ 1397 (SEC_LINK_DUPLICATES_ONE_ONLY | SEC_LINK_DUPLICATES_SAME_SIZE) 1398 1399 /* This section was created by the linker as part of dynamic 1400 relocation or other arcane processing. It is skipped when 1401 going through the first-pass output, trusting that someone 1402 else up the line will take care of it later. */ 1403 #define SEC_LINKER_CREATED 0x200000 1404 1405 /* This section should not be subject to garbage collection. 1406 Also set to inform the linker that this section should not be 1407 listed in the link map as discarded. */ 1408 #define SEC_KEEP 0x400000 1409 1410 /* This section contains "short" data, and should be placed 1411 "near" the GP. */ 1412 #define SEC_SMALL_DATA 0x800000 1413 1414 /* Attempt to merge identical entities in the section. 1415 Entity size is given in the entsize field. */ 1416 #define SEC_MERGE 0x1000000 1417 1418 /* If given with SEC_MERGE, entities to merge are zero terminated 1419 strings where entsize specifies character size instead of fixed 1420 size entries. */ 1421 #define SEC_STRINGS 0x2000000 1422 1423 /* This section contains data about section groups. */ 1424 #define SEC_GROUP 0x4000000 1425 1426 /* The section is a COFF shared library section. This flag is 1427 only for the linker. If this type of section appears in 1428 the input file, the linker must copy it to the output file 1429 without changing the vma or size. FIXME: Although this 1430 was originally intended to be general, it really is COFF 1431 specific (and the flag was renamed to indicate this). It 1432 might be cleaner to have some more general mechanism to 1433 allow the back end to control what the linker does with 1434 sections. */ 1435 #define SEC_COFF_SHARED_LIBRARY 0x10000000 1436 1437 /* This section contains data which may be shared with other 1438 executables or shared objects. This is for COFF only. */ 1439 #define SEC_COFF_SHARED 0x20000000 1440 1441 /* When a section with this flag is being linked, then if the size of 1442 the input section is less than a page, it should not cross a page 1443 boundary. If the size of the input section is one page or more, 1444 it should be aligned on a page boundary. This is for TI 1445 TMS320C54X only. */ 1446 #define SEC_TIC54X_BLOCK 0x40000000 1447 1448 /* Conditionally link this section; do not link if there are no 1449 references found to any symbol in the section. This is for TI 1450 TMS320C54X only. */ 1451 #define SEC_TIC54X_CLINK 0x80000000 1452 1453 /* End of section flags. */ 1454 1455 /* Some internal packed boolean fields. */ 1456 1457 /* See the vma field. */ 1458 unsigned int user_set_vma : 1; 1459 1460 /* A mark flag used by some of the linker backends. */ 1461 unsigned int linker_mark : 1; 1462 1463 /* Another mark flag used by some of the linker backends. Set for 1464 output sections that have an input section. */ 1465 unsigned int linker_has_input : 1; 1466 1467 /* Mark flags used by some linker backends for garbage collection. */ 1468 unsigned int gc_mark : 1; 1469 unsigned int gc_mark_from_eh : 1; 1470 1471 /* The following flags are used by the ELF linker. */ 1472 1473 /* Mark sections which have been allocated to segments. */ 1474 unsigned int segment_mark : 1; 1475 1476 /* Type of sec_info information. */ 1477 unsigned int sec_info_type:3; 1478 #define ELF_INFO_TYPE_NONE 0 1479 #define ELF_INFO_TYPE_STABS 1 1480 #define ELF_INFO_TYPE_MERGE 2 1481 #define ELF_INFO_TYPE_EH_FRAME 3 1482 #define ELF_INFO_TYPE_JUST_SYMS 4 1483 1484 /* Nonzero if this section uses RELA relocations, rather than REL. */ 1485 unsigned int use_rela_p:1; 1486 1487 /* Bits used by various backends. The generic code doesn't touch 1488 these fields. */ 1489 1490 /* Nonzero if this section has TLS related relocations. */ 1491 unsigned int has_tls_reloc:1; 1492 1493 /* Nonzero if this section has a gp reloc. */ 1494 unsigned int has_gp_reloc:1; 1495 1496 /* Nonzero if this section needs the relax finalize pass. */ 1497 unsigned int need_finalize_relax:1; 1498 1499 /* Whether relocations have been processed. */ 1500 unsigned int reloc_done : 1; 1501 1502 /* End of internal packed boolean fields. */ 1503 1504 /* The virtual memory address of the section - where it will be 1505 at run time. The symbols are relocated against this. The 1506 user_set_vma flag is maintained by bfd; if it's not set, the 1507 backend can assign addresses (for example, in `a.out', where 1508 the default address for `.data' is dependent on the specific 1509 target and various flags). */ 1510 bfd_vma vma; 1511 1512 /* The load address of the section - where it would be in a 1513 rom image; really only used for writing section header 1514 information. */ 1515 bfd_vma lma; 1516 1517 /* The size of the section in octets, as it will be output. 1518 Contains a value even if the section has no contents (e.g., the 1519 size of `.bss'). */ 1520 bfd_size_type size; 1521 1522 /* For input sections, the original size on disk of the section, in 1523 octets. This field is used by the linker relaxation code. It is 1524 currently only set for sections where the linker relaxation scheme 1525 doesn't cache altered section and reloc contents (stabs, eh_frame, 1526 SEC_MERGE, some coff relaxing targets), and thus the original size 1527 needs to be kept to read the section multiple times. 1528 For output sections, rawsize holds the section size calculated on 1529 a previous linker relaxation pass. */ 1530 bfd_size_type rawsize; 1531 1532 /* If this section is going to be output, then this value is the 1533 offset in *bytes* into the output section of the first byte in the 1534 input section (byte ==> smallest addressable unit on the 1535 target). In most cases, if this was going to start at the 1536 100th octet (8-bit quantity) in the output section, this value 1537 would be 100. However, if the target byte size is 16 bits 1538 (bfd_octets_per_byte is "2"), this value would be 50. */ 1539 bfd_vma output_offset; 1540 1541 /* The output section through which to map on output. */ 1542 struct bfd_section *output_section; 1543 1544 /* The alignment requirement of the section, as an exponent of 2 - 1545 e.g., 3 aligns to 2^3 (or 8). */ 1546 unsigned int alignment_power; 1547 1548 /* If an input section, a pointer to a vector of relocation 1549 records for the data in this section. */ 1550 struct reloc_cache_entry *relocation; 1551 1552 /* If an output section, a pointer to a vector of pointers to 1553 relocation records for the data in this section. */ 1554 struct reloc_cache_entry **orelocation; 1555 1556 /* The number of relocation records in one of the above. */ 1557 unsigned reloc_count; 1558 1559 /* Information below is back end specific - and not always used 1560 or updated. */ 1561 1562 /* File position of section data. */ 1563 file_ptr filepos; 1564 1565 /* File position of relocation info. */ 1566 file_ptr rel_filepos; 1567 1568 /* File position of line data. */ 1569 file_ptr line_filepos; 1570 1571 /* Pointer to data for applications. */ 1572 void *userdata; 1573 1574 /* If the SEC_IN_MEMORY flag is set, this points to the actual 1575 contents. */ 1576 unsigned char *contents; 1577 1578 /* Attached line number information. */ 1579 alent *lineno; 1580 1581 /* Number of line number records. */ 1582 unsigned int lineno_count; 1583 1584 /* Entity size for merging purposes. */ 1585 unsigned int entsize; 1586 1587 /* Points to the kept section if this section is a link-once section, 1588 and is discarded. */ 1589 struct bfd_section *kept_section; 1590 1591 /* When a section is being output, this value changes as more 1592 linenumbers are written out. */ 1593 file_ptr moving_line_filepos; 1594 1595 /* What the section number is in the target world. */ 1596 int target_index; 1597 1598 void *used_by_bfd; 1599 1600 /* If this is a constructor section then here is a list of the 1601 relocations created to relocate items within it. */ 1602 struct relent_chain *constructor_chain; 1603 1604 /* The BFD which owns the section. */ 1605 bfd *owner; 1606 1607 /* A symbol which points at this section only. */ 1608 struct bfd_symbol *symbol; 1609 struct bfd_symbol **symbol_ptr_ptr; 1610 1611 /* Early in the link process, map_head and map_tail are used to build 1612 a list of input sections attached to an output section. Later, 1613 output sections use these fields for a list of bfd_link_order 1614 structs. */ 1615 union { 1616 struct bfd_link_order *link_order; 1617 struct bfd_section *s; 1618 } map_head, map_tail; 1619 } asection; 1620 1621 /* These sections are global, and are managed by BFD. The application 1622 and target back end are not permitted to change the values in 1623 these sections. New code should use the section_ptr macros rather 1624 than referring directly to the const sections. The const sections 1625 may eventually vanish. */ 1626 #define BFD_ABS_SECTION_NAME "*ABS*" 1627 #define BFD_UND_SECTION_NAME "*UND*" 1628 #define BFD_COM_SECTION_NAME "*COM*" 1629 #define BFD_IND_SECTION_NAME "*IND*" 1630 1631 /* The absolute section. */ 1632 extern asection bfd_abs_section; 1633 #define bfd_abs_section_ptr ((asection *) &bfd_abs_section) 1634 #define bfd_is_abs_section(sec) ((sec) == bfd_abs_section_ptr) 1635 /* Pointer to the undefined section. */ 1636 extern asection bfd_und_section; 1637 #define bfd_und_section_ptr ((asection *) &bfd_und_section) 1638 #define bfd_is_und_section(sec) ((sec) == bfd_und_section_ptr) 1639 /* Pointer to the common section. */ 1640 extern asection bfd_com_section; 1641 #define bfd_com_section_ptr ((asection *) &bfd_com_section) 1642 /* Pointer to the indirect section. */ 1643 extern asection bfd_ind_section; 1644 #define bfd_ind_section_ptr ((asection *) &bfd_ind_section) 1645 #define bfd_is_ind_section(sec) ((sec) == bfd_ind_section_ptr) 1646 1647 #define bfd_is_const_section(SEC) \ 1648 ( ((SEC) == bfd_abs_section_ptr) \ 1649 || ((SEC) == bfd_und_section_ptr) \ 1650 || ((SEC) == bfd_com_section_ptr) \ 1651 || ((SEC) == bfd_ind_section_ptr)) 1652 1653 /* Macros to handle insertion and deletion of a bfd's sections. These 1654 only handle the list pointers, ie. do not adjust section_count, 1655 target_index etc. */ 1656 #define bfd_section_list_remove(ABFD, S) \ 1657 do \ 1658 { \ 1659 asection *_s = S; \ 1660 asection *_next = _s->next; \ 1661 asection *_prev = _s->prev; \ 1662 if (_prev) \ 1663 _prev->next = _next; \ 1664 else \ 1665 (ABFD)->sections = _next; \ 1666 if (_next) \ 1667 _next->prev = _prev; \ 1668 else \ 1669 (ABFD)->section_last = _prev; \ 1670 } \ 1671 while (0) 1672 #define bfd_section_list_append(ABFD, S) \ 1673 do \ 1674 { \ 1675 asection *_s = S; \ 1676 bfd *_abfd = ABFD; \ 1677 _s->next = NULL; \ 1678 if (_abfd->section_last) \ 1679 { \ 1680 _s->prev = _abfd->section_last; \ 1681 _abfd->section_last->next = _s; \ 1682 } \ 1683 else \ 1684 { \ 1685 _s->prev = NULL; \ 1686 _abfd->sections = _s; \ 1687 } \ 1688 _abfd->section_last = _s; \ 1689 } \ 1690 while (0) 1691 #define bfd_section_list_prepend(ABFD, S) \ 1692 do \ 1693 { \ 1694 asection *_s = S; \ 1695 bfd *_abfd = ABFD; \ 1696 _s->prev = NULL; \ 1697 if (_abfd->sections) \ 1698 { \ 1699 _s->next = _abfd->sections; \ 1700 _abfd->sections->prev = _s; \ 1701 } \ 1702 else \ 1703 { \ 1704 _s->next = NULL; \ 1705 _abfd->section_last = _s; \ 1706 } \ 1707 _abfd->sections = _s; \ 1708 } \ 1709 while (0) 1710 #define bfd_section_list_insert_after(ABFD, A, S) \ 1711 do \ 1712 { \ 1713 asection *_a = A; \ 1714 asection *_s = S; \ 1715 asection *_next = _a->next; \ 1716 _s->next = _next; \ 1717 _s->prev = _a; \ 1718 _a->next = _s; \ 1719 if (_next) \ 1720 _next->prev = _s; \ 1721 else \ 1722 (ABFD)->section_last = _s; \ 1723 } \ 1724 while (0) 1725 #define bfd_section_list_insert_before(ABFD, B, S) \ 1726 do \ 1727 { \ 1728 asection *_b = B; \ 1729 asection *_s = S; \ 1730 asection *_prev = _b->prev; \ 1731 _s->prev = _prev; \ 1732 _s->next = _b; \ 1733 _b->prev = _s; \ 1734 if (_prev) \ 1735 _prev->next = _s; \ 1736 else \ 1737 (ABFD)->sections = _s; \ 1738 } \ 1739 while (0) 1740 #define bfd_section_removed_from_list(ABFD, S) \ 1741 ((S)->next == NULL ? (ABFD)->section_last != (S) : (S)->next->prev != (S)) 1742 1743 #define BFD_FAKE_SECTION(SEC, FLAGS, SYM, NAME, IDX) \ 1744 /* name, id, index, next, prev, flags, user_set_vma, */ \ 1745 { NAME, IDX, 0, NULL, NULL, FLAGS, 0, \ 1746 \ 1747 /* linker_mark, linker_has_input, gc_mark, gc_mark_from_eh, */ \ 1748 0, 0, 1, 0, \ 1749 \ 1750 /* segment_mark, sec_info_type, use_rela_p, has_tls_reloc, */ \ 1751 0, 0, 0, 0, \ 1752 \ 1753 /* has_gp_reloc, need_finalize_relax, reloc_done, */ \ 1754 0, 0, 0, \ 1755 \ 1756 /* vma, lma, size, rawsize */ \ 1757 0, 0, 0, 0, \ 1758 \ 1759 /* output_offset, output_section, alignment_power, */ \ 1760 0, (struct bfd_section *) &SEC, 0, \ 1761 \ 1762 /* relocation, orelocation, reloc_count, filepos, rel_filepos, */ \ 1763 NULL, NULL, 0, 0, 0, \ 1764 \ 1765 /* line_filepos, userdata, contents, lineno, lineno_count, */ \ 1766 0, NULL, NULL, NULL, 0, \ 1767 \ 1768 /* entsize, kept_section, moving_line_filepos, */ \ 1769 0, NULL, 0, \ 1770 \ 1771 /* target_index, used_by_bfd, constructor_chain, owner, */ \ 1772 0, NULL, NULL, NULL, \ 1773 \ 1774 /* symbol, symbol_ptr_ptr, */ \ 1775 (struct bfd_symbol *) SYM, &SEC.symbol, \ 1776 \ 1777 /* map_head, map_tail */ \ 1778 { NULL }, { NULL } \ 1779 } 1780 1781 1782File: bfd.info, Node: section prototypes, Prev: typedef asection, Up: Sections 1783 17842.6.5 Section prototypes 1785------------------------ 1786 1787These are the functions exported by the section handling part of BFD. 1788 17892.6.5.1 `bfd_section_list_clear' 1790................................ 1791 1792*Synopsis* 1793 void bfd_section_list_clear (bfd *); 1794 *Description* 1795Clears the section list, and also resets the section count and hash 1796table entries. 1797 17982.6.5.2 `bfd_get_section_by_name' 1799................................. 1800 1801*Synopsis* 1802 asection *bfd_get_section_by_name (bfd *abfd, const char *name); 1803 *Description* 1804Run through ABFD and return the one of the `asection's whose name 1805matches NAME, otherwise `NULL'. *Note Sections::, for more information. 1806 1807 This should only be used in special cases; the normal way to process 1808all sections of a given name is to use `bfd_map_over_sections' and 1809`strcmp' on the name (or better yet, base it on the section flags or 1810something else) for each section. 1811 18122.6.5.3 `bfd_get_section_by_name_if' 1813.................................... 1814 1815*Synopsis* 1816 asection *bfd_get_section_by_name_if 1817 (bfd *abfd, 1818 const char *name, 1819 bfd_boolean (*func) (bfd *abfd, asection *sect, void *obj), 1820 void *obj); 1821 *Description* 1822Call the provided function FUNC for each section attached to the BFD 1823ABFD whose name matches NAME, passing OBJ as an argument. The function 1824will be called as if by 1825 1826 func (abfd, the_section, obj); 1827 1828 It returns the first section for which FUNC returns true, otherwise 1829`NULL'. 1830 18312.6.5.4 `bfd_get_unique_section_name' 1832..................................... 1833 1834*Synopsis* 1835 char *bfd_get_unique_section_name 1836 (bfd *abfd, const char *templat, int *count); 1837 *Description* 1838Invent a section name that is unique in ABFD by tacking a dot and a 1839digit suffix onto the original TEMPLAT. If COUNT is non-NULL, then it 1840specifies the first number tried as a suffix to generate a unique name. 1841The value pointed to by COUNT will be incremented in this case. 1842 18432.6.5.5 `bfd_make_section_old_way' 1844.................................. 1845 1846*Synopsis* 1847 asection *bfd_make_section_old_way (bfd *abfd, const char *name); 1848 *Description* 1849Create a new empty section called NAME and attach it to the end of the 1850chain of sections for the BFD ABFD. An attempt to create a section with 1851a name which is already in use returns its pointer without changing the 1852section chain. 1853 1854 It has the funny name since this is the way it used to be before it 1855was rewritten.... 1856 1857 Possible errors are: 1858 * `bfd_error_invalid_operation' - If output has already started for 1859 this BFD. 1860 1861 * `bfd_error_no_memory' - If memory allocation fails. 1862 18632.6.5.6 `bfd_make_section_anyway_with_flags' 1864............................................ 1865 1866*Synopsis* 1867 asection *bfd_make_section_anyway_with_flags 1868 (bfd *abfd, const char *name, flagword flags); 1869 *Description* 1870Create a new empty section called NAME and attach it to the end of the 1871chain of sections for ABFD. Create a new section even if there is 1872already a section with that name. Also set the attributes of the new 1873section to the value FLAGS. 1874 1875 Return `NULL' and set `bfd_error' on error; possible errors are: 1876 * `bfd_error_invalid_operation' - If output has already started for 1877 ABFD. 1878 1879 * `bfd_error_no_memory' - If memory allocation fails. 1880 18812.6.5.7 `bfd_make_section_anyway' 1882................................. 1883 1884*Synopsis* 1885 asection *bfd_make_section_anyway (bfd *abfd, const char *name); 1886 *Description* 1887Create a new empty section called NAME and attach it to the end of the 1888chain of sections for ABFD. Create a new section even if there is 1889already a section with that name. 1890 1891 Return `NULL' and set `bfd_error' on error; possible errors are: 1892 * `bfd_error_invalid_operation' - If output has already started for 1893 ABFD. 1894 1895 * `bfd_error_no_memory' - If memory allocation fails. 1896 18972.6.5.8 `bfd_make_section_with_flags' 1898..................................... 1899 1900*Synopsis* 1901 asection *bfd_make_section_with_flags 1902 (bfd *, const char *name, flagword flags); 1903 *Description* 1904Like `bfd_make_section_anyway', but return `NULL' (without calling 1905bfd_set_error ()) without changing the section chain if there is 1906already a section named NAME. Also set the attributes of the new 1907section to the value FLAGS. If there is an error, return `NULL' and set 1908`bfd_error'. 1909 19102.6.5.9 `bfd_make_section' 1911.......................... 1912 1913*Synopsis* 1914 asection *bfd_make_section (bfd *, const char *name); 1915 *Description* 1916Like `bfd_make_section_anyway', but return `NULL' (without calling 1917bfd_set_error ()) without changing the section chain if there is 1918already a section named NAME. If there is an error, return `NULL' and 1919set `bfd_error'. 1920 19212.6.5.10 `bfd_set_section_flags' 1922................................ 1923 1924*Synopsis* 1925 bfd_boolean bfd_set_section_flags 1926 (bfd *abfd, asection *sec, flagword flags); 1927 *Description* 1928Set the attributes of the section SEC in the BFD ABFD to the value 1929FLAGS. Return `TRUE' on success, `FALSE' on error. Possible error 1930returns are: 1931 1932 * `bfd_error_invalid_operation' - The section cannot have one or 1933 more of the attributes requested. For example, a .bss section in 1934 `a.out' may not have the `SEC_HAS_CONTENTS' field set. 1935 19362.6.5.11 `bfd_map_over_sections' 1937................................ 1938 1939*Synopsis* 1940 void bfd_map_over_sections 1941 (bfd *abfd, 1942 void (*func) (bfd *abfd, asection *sect, void *obj), 1943 void *obj); 1944 *Description* 1945Call the provided function FUNC for each section attached to the BFD 1946ABFD, passing OBJ as an argument. The function will be called as if by 1947 1948 func (abfd, the_section, obj); 1949 1950 This is the preferred method for iterating over sections; an 1951alternative would be to use a loop: 1952 1953 section *p; 1954 for (p = abfd->sections; p != NULL; p = p->next) 1955 func (abfd, p, ...) 1956 19572.6.5.12 `bfd_sections_find_if' 1958............................... 1959 1960*Synopsis* 1961 asection *bfd_sections_find_if 1962 (bfd *abfd, 1963 bfd_boolean (*operation) (bfd *abfd, asection *sect, void *obj), 1964 void *obj); 1965 *Description* 1966Call the provided function OPERATION for each section attached to the 1967BFD ABFD, passing OBJ as an argument. The function will be called as if 1968by 1969 1970 operation (abfd, the_section, obj); 1971 1972 It returns the first section for which OPERATION returns true. 1973 19742.6.5.13 `bfd_set_section_size' 1975............................... 1976 1977*Synopsis* 1978 bfd_boolean bfd_set_section_size 1979 (bfd *abfd, asection *sec, bfd_size_type val); 1980 *Description* 1981Set SEC to the size VAL. If the operation is ok, then `TRUE' is 1982returned, else `FALSE'. 1983 1984 Possible error returns: 1985 * `bfd_error_invalid_operation' - Writing has started to the BFD, so 1986 setting the size is invalid. 1987 19882.6.5.14 `bfd_set_section_contents' 1989................................... 1990 1991*Synopsis* 1992 bfd_boolean bfd_set_section_contents 1993 (bfd *abfd, asection *section, const void *data, 1994 file_ptr offset, bfd_size_type count); 1995 *Description* 1996Sets the contents of the section SECTION in BFD ABFD to the data 1997starting in memory at DATA. The data is written to the output section 1998starting at offset OFFSET for COUNT octets. 1999 2000 Normally `TRUE' is returned, else `FALSE'. Possible error returns 2001are: 2002 * `bfd_error_no_contents' - The output section does not have the 2003 `SEC_HAS_CONTENTS' attribute, so nothing can be written to it. 2004 2005 * and some more too 2006 This routine is front end to the back end function 2007`_bfd_set_section_contents'. 2008 20092.6.5.15 `bfd_get_section_contents' 2010................................... 2011 2012*Synopsis* 2013 bfd_boolean bfd_get_section_contents 2014 (bfd *abfd, asection *section, void *location, file_ptr offset, 2015 bfd_size_type count); 2016 *Description* 2017Read data from SECTION in BFD ABFD into memory starting at LOCATION. 2018The data is read at an offset of OFFSET from the start of the input 2019section, and is read for COUNT bytes. 2020 2021 If the contents of a constructor with the `SEC_CONSTRUCTOR' flag set 2022are requested or if the section does not have the `SEC_HAS_CONTENTS' 2023flag set, then the LOCATION is filled with zeroes. If no errors occur, 2024`TRUE' is returned, else `FALSE'. 2025 20262.6.5.16 `bfd_malloc_and_get_section' 2027..................................... 2028 2029*Synopsis* 2030 bfd_boolean bfd_malloc_and_get_section 2031 (bfd *abfd, asection *section, bfd_byte **buf); 2032 *Description* 2033Read all data from SECTION in BFD ABFD into a buffer, *BUF, malloc'd by 2034this function. 2035 20362.6.5.17 `bfd_copy_private_section_data' 2037........................................ 2038 2039*Synopsis* 2040 bfd_boolean bfd_copy_private_section_data 2041 (bfd *ibfd, asection *isec, bfd *obfd, asection *osec); 2042 *Description* 2043Copy private section information from ISEC in the BFD IBFD to the 2044section OSEC in the BFD OBFD. Return `TRUE' on success, `FALSE' on 2045error. Possible error returns are: 2046 2047 * `bfd_error_no_memory' - Not enough memory exists to create private 2048 data for OSEC. 2049 2050 #define bfd_copy_private_section_data(ibfd, isection, obfd, osection) \ 2051 BFD_SEND (obfd, _bfd_copy_private_section_data, \ 2052 (ibfd, isection, obfd, osection)) 2053 20542.6.5.18 `bfd_generic_is_group_section' 2055....................................... 2056 2057*Synopsis* 2058 bfd_boolean bfd_generic_is_group_section (bfd *, const asection *sec); 2059 *Description* 2060Returns TRUE if SEC is a member of a group. 2061 20622.6.5.19 `bfd_generic_discard_group' 2063.................................... 2064 2065*Synopsis* 2066 bfd_boolean bfd_generic_discard_group (bfd *abfd, asection *group); 2067 *Description* 2068Remove all members of GROUP from the output. 2069 2070 2071File: bfd.info, Node: Symbols, Next: Archives, Prev: Sections, Up: BFD front end 2072 20732.7 Symbols 2074=========== 2075 2076BFD tries to maintain as much symbol information as it can when it 2077moves information from file to file. BFD passes information to 2078applications though the `asymbol' structure. When the application 2079requests the symbol table, BFD reads the table in the native form and 2080translates parts of it into the internal format. To maintain more than 2081the information passed to applications, some targets keep some 2082information "behind the scenes" in a structure only the particular back 2083end knows about. For example, the coff back end keeps the original 2084symbol table structure as well as the canonical structure when a BFD is 2085read in. On output, the coff back end can reconstruct the output symbol 2086table so that no information is lost, even information unique to coff 2087which BFD doesn't know or understand. If a coff symbol table were read, 2088but were written through an a.out back end, all the coff specific 2089information would be lost. The symbol table of a BFD is not necessarily 2090read in until a canonicalize request is made. Then the BFD back end 2091fills in a table provided by the application with pointers to the 2092canonical information. To output symbols, the application provides BFD 2093with a table of pointers to pointers to `asymbol's. This allows 2094applications like the linker to output a symbol as it was read, since 2095the "behind the scenes" information will be still available. 2096 2097* Menu: 2098 2099* Reading Symbols:: 2100* Writing Symbols:: 2101* Mini Symbols:: 2102* typedef asymbol:: 2103* symbol handling functions:: 2104 2105 2106File: bfd.info, Node: Reading Symbols, Next: Writing Symbols, Prev: Symbols, Up: Symbols 2107 21082.7.1 Reading symbols 2109--------------------- 2110 2111There are two stages to reading a symbol table from a BFD: allocating 2112storage, and the actual reading process. This is an excerpt from an 2113application which reads the symbol table: 2114 2115 long storage_needed; 2116 asymbol **symbol_table; 2117 long number_of_symbols; 2118 long i; 2119 2120 storage_needed = bfd_get_symtab_upper_bound (abfd); 2121 2122 if (storage_needed < 0) 2123 FAIL 2124 2125 if (storage_needed == 0) 2126 return; 2127 2128 symbol_table = xmalloc (storage_needed); 2129 ... 2130 number_of_symbols = 2131 bfd_canonicalize_symtab (abfd, symbol_table); 2132 2133 if (number_of_symbols < 0) 2134 FAIL 2135 2136 for (i = 0; i < number_of_symbols; i++) 2137 process_symbol (symbol_table[i]); 2138 2139 All storage for the symbols themselves is in an objalloc connected 2140to the BFD; it is freed when the BFD is closed. 2141 2142 2143File: bfd.info, Node: Writing Symbols, Next: Mini Symbols, Prev: Reading Symbols, Up: Symbols 2144 21452.7.2 Writing symbols 2146--------------------- 2147 2148Writing of a symbol table is automatic when a BFD open for writing is 2149closed. The application attaches a vector of pointers to pointers to 2150symbols to the BFD being written, and fills in the symbol count. The 2151close and cleanup code reads through the table provided and performs 2152all the necessary operations. The BFD output code must always be 2153provided with an "owned" symbol: one which has come from another BFD, 2154or one which has been created using `bfd_make_empty_symbol'. Here is an 2155example showing the creation of a symbol table with only one element: 2156 2157 #include "bfd.h" 2158 int main (void) 2159 { 2160 bfd *abfd; 2161 asymbol *ptrs[2]; 2162 asymbol *new; 2163 2164 abfd = bfd_openw ("foo","a.out-sunos-big"); 2165 bfd_set_format (abfd, bfd_object); 2166 new = bfd_make_empty_symbol (abfd); 2167 new->name = "dummy_symbol"; 2168 new->section = bfd_make_section_old_way (abfd, ".text"); 2169 new->flags = BSF_GLOBAL; 2170 new->value = 0x12345; 2171 2172 ptrs[0] = new; 2173 ptrs[1] = 0; 2174 2175 bfd_set_symtab (abfd, ptrs, 1); 2176 bfd_close (abfd); 2177 return 0; 2178 } 2179 2180 ./makesym 2181 nm foo 2182 00012345 A dummy_symbol 2183 2184 Many formats cannot represent arbitrary symbol information; for 2185instance, the `a.out' object format does not allow an arbitrary number 2186of sections. A symbol pointing to a section which is not one of 2187`.text', `.data' or `.bss' cannot be described. 2188 2189 2190File: bfd.info, Node: Mini Symbols, Next: typedef asymbol, Prev: Writing Symbols, Up: Symbols 2191 21922.7.3 Mini Symbols 2193------------------ 2194 2195Mini symbols provide read-only access to the symbol table. They use 2196less memory space, but require more time to access. They can be useful 2197for tools like nm or objdump, which may have to handle symbol tables of 2198extremely large executables. 2199 2200 The `bfd_read_minisymbols' function will read the symbols into 2201memory in an internal form. It will return a `void *' pointer to a 2202block of memory, a symbol count, and the size of each symbol. The 2203pointer is allocated using `malloc', and should be freed by the caller 2204when it is no longer needed. 2205 2206 The function `bfd_minisymbol_to_symbol' will take a pointer to a 2207minisymbol, and a pointer to a structure returned by 2208`bfd_make_empty_symbol', and return a `asymbol' structure. The return 2209value may or may not be the same as the value from 2210`bfd_make_empty_symbol' which was passed in. 2211 2212 2213File: bfd.info, Node: typedef asymbol, Next: symbol handling functions, Prev: Mini Symbols, Up: Symbols 2214 22152.7.4 typedef asymbol 2216--------------------- 2217 2218An `asymbol' has the form: 2219 2220 2221 typedef struct bfd_symbol 2222 { 2223 /* A pointer to the BFD which owns the symbol. This information 2224 is necessary so that a back end can work out what additional 2225 information (invisible to the application writer) is carried 2226 with the symbol. 2227 2228 This field is *almost* redundant, since you can use section->owner 2229 instead, except that some symbols point to the global sections 2230 bfd_{abs,com,und}_section. This could be fixed by making 2231 these globals be per-bfd (or per-target-flavor). FIXME. */ 2232 struct bfd *the_bfd; /* Use bfd_asymbol_bfd(sym) to access this field. */ 2233 2234 /* The text of the symbol. The name is left alone, and not copied; the 2235 application may not alter it. */ 2236 const char *name; 2237 2238 /* The value of the symbol. This really should be a union of a 2239 numeric value with a pointer, since some flags indicate that 2240 a pointer to another symbol is stored here. */ 2241 symvalue value; 2242 2243 /* Attributes of a symbol. */ 2244 #define BSF_NO_FLAGS 0x00 2245 2246 /* The symbol has local scope; `static' in `C'. The value 2247 is the offset into the section of the data. */ 2248 #define BSF_LOCAL 0x01 2249 2250 /* The symbol has global scope; initialized data in `C'. The 2251 value is the offset into the section of the data. */ 2252 #define BSF_GLOBAL 0x02 2253 2254 /* The symbol has global scope and is exported. The value is 2255 the offset into the section of the data. */ 2256 #define BSF_EXPORT BSF_GLOBAL /* No real difference. */ 2257 2258 /* A normal C symbol would be one of: 2259 `BSF_LOCAL', `BSF_FORT_COMM', `BSF_UNDEFINED' or 2260 `BSF_GLOBAL'. */ 2261 2262 /* The symbol is a debugging record. The value has an arbitrary 2263 meaning, unless BSF_DEBUGGING_RELOC is also set. */ 2264 #define BSF_DEBUGGING 0x08 2265 2266 /* The symbol denotes a function entry point. Used in ELF, 2267 perhaps others someday. */ 2268 #define BSF_FUNCTION 0x10 2269 2270 /* Used by the linker. */ 2271 #define BSF_KEEP 0x20 2272 #define BSF_KEEP_G 0x40 2273 2274 /* A weak global symbol, overridable without warnings by 2275 a regular global symbol of the same name. */ 2276 #define BSF_WEAK 0x80 2277 2278 /* This symbol was created to point to a section, e.g. ELF's 2279 STT_SECTION symbols. */ 2280 #define BSF_SECTION_SYM 0x100 2281 2282 /* The symbol used to be a common symbol, but now it is 2283 allocated. */ 2284 #define BSF_OLD_COMMON 0x200 2285 2286 /* The default value for common data. */ 2287 #define BFD_FORT_COMM_DEFAULT_VALUE 0 2288 2289 /* In some files the type of a symbol sometimes alters its 2290 location in an output file - ie in coff a `ISFCN' symbol 2291 which is also `C_EXT' symbol appears where it was 2292 declared and not at the end of a section. This bit is set 2293 by the target BFD part to convey this information. */ 2294 #define BSF_NOT_AT_END 0x400 2295 2296 /* Signal that the symbol is the label of constructor section. */ 2297 #define BSF_CONSTRUCTOR 0x800 2298 2299 /* Signal that the symbol is a warning symbol. The name is a 2300 warning. The name of the next symbol is the one to warn about; 2301 if a reference is made to a symbol with the same name as the next 2302 symbol, a warning is issued by the linker. */ 2303 #define BSF_WARNING 0x1000 2304 2305 /* Signal that the symbol is indirect. This symbol is an indirect 2306 pointer to the symbol with the same name as the next symbol. */ 2307 #define BSF_INDIRECT 0x2000 2308 2309 /* BSF_FILE marks symbols that contain a file name. This is used 2310 for ELF STT_FILE symbols. */ 2311 #define BSF_FILE 0x4000 2312 2313 /* Symbol is from dynamic linking information. */ 2314 #define BSF_DYNAMIC 0x8000 2315 2316 /* The symbol denotes a data object. Used in ELF, and perhaps 2317 others someday. */ 2318 #define BSF_OBJECT 0x10000 2319 2320 /* This symbol is a debugging symbol. The value is the offset 2321 into the section of the data. BSF_DEBUGGING should be set 2322 as well. */ 2323 #define BSF_DEBUGGING_RELOC 0x20000 2324 2325 /* This symbol is thread local. Used in ELF. */ 2326 #define BSF_THREAD_LOCAL 0x40000 2327 2328 /* This symbol represents a complex relocation expression, 2329 with the expression tree serialized in the symbol name. */ 2330 #define BSF_RELC 0x80000 2331 2332 /* This symbol represents a signed complex relocation expression, 2333 with the expression tree serialized in the symbol name. */ 2334 #define BSF_SRELC 0x100000 2335 2336 flagword flags; 2337 2338 /* A pointer to the section to which this symbol is 2339 relative. This will always be non NULL, there are special 2340 sections for undefined and absolute symbols. */ 2341 struct bfd_section *section; 2342 2343 /* Back end special data. */ 2344 union 2345 { 2346 void *p; 2347 bfd_vma i; 2348 } 2349 udata; 2350 } 2351 asymbol; 2352 2353 2354File: bfd.info, Node: symbol handling functions, Prev: typedef asymbol, Up: Symbols 2355 23562.7.5 Symbol handling functions 2357------------------------------- 2358 23592.7.5.1 `bfd_get_symtab_upper_bound' 2360.................................... 2361 2362*Description* 2363Return the number of bytes required to store a vector of pointers to 2364`asymbols' for all the symbols in the BFD ABFD, including a terminal 2365NULL pointer. If there are no symbols in the BFD, then return 0. If an 2366error occurs, return -1. 2367 #define bfd_get_symtab_upper_bound(abfd) \ 2368 BFD_SEND (abfd, _bfd_get_symtab_upper_bound, (abfd)) 2369 23702.7.5.2 `bfd_is_local_label' 2371............................ 2372 2373*Synopsis* 2374 bfd_boolean bfd_is_local_label (bfd *abfd, asymbol *sym); 2375 *Description* 2376Return TRUE if the given symbol SYM in the BFD ABFD is a compiler 2377generated local label, else return FALSE. 2378 23792.7.5.3 `bfd_is_local_label_name' 2380................................. 2381 2382*Synopsis* 2383 bfd_boolean bfd_is_local_label_name (bfd *abfd, const char *name); 2384 *Description* 2385Return TRUE if a symbol with the name NAME in the BFD ABFD is a 2386compiler generated local label, else return FALSE. This just checks 2387whether the name has the form of a local label. 2388 #define bfd_is_local_label_name(abfd, name) \ 2389 BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name)) 2390 23912.7.5.4 `bfd_is_target_special_symbol' 2392...................................... 2393 2394*Synopsis* 2395 bfd_boolean bfd_is_target_special_symbol (bfd *abfd, asymbol *sym); 2396 *Description* 2397Return TRUE iff a symbol SYM in the BFD ABFD is something special to 2398the particular target represented by the BFD. Such symbols should 2399normally not be mentioned to the user. 2400 #define bfd_is_target_special_symbol(abfd, sym) \ 2401 BFD_SEND (abfd, _bfd_is_target_special_symbol, (abfd, sym)) 2402 24032.7.5.5 `bfd_canonicalize_symtab' 2404................................. 2405 2406*Description* 2407Read the symbols from the BFD ABFD, and fills in the vector LOCATION 2408with pointers to the symbols and a trailing NULL. Return the actual 2409number of symbol pointers, not including the NULL. 2410 #define bfd_canonicalize_symtab(abfd, location) \ 2411 BFD_SEND (abfd, _bfd_canonicalize_symtab, (abfd, location)) 2412 24132.7.5.6 `bfd_set_symtab' 2414........................ 2415 2416*Synopsis* 2417 bfd_boolean bfd_set_symtab 2418 (bfd *abfd, asymbol **location, unsigned int count); 2419 *Description* 2420Arrange that when the output BFD ABFD is closed, the table LOCATION of 2421COUNT pointers to symbols will be written. 2422 24232.7.5.7 `bfd_print_symbol_vandf' 2424................................ 2425 2426*Synopsis* 2427 void bfd_print_symbol_vandf (bfd *abfd, void *file, asymbol *symbol); 2428 *Description* 2429Print the value and flags of the SYMBOL supplied to the stream FILE. 2430 24312.7.5.8 `bfd_make_empty_symbol' 2432............................... 2433 2434*Description* 2435Create a new `asymbol' structure for the BFD ABFD and return a pointer 2436to it. 2437 2438 This routine is necessary because each back end has private 2439information surrounding the `asymbol'. Building your own `asymbol' and 2440pointing to it will not create the private information, and will cause 2441problems later on. 2442 #define bfd_make_empty_symbol(abfd) \ 2443 BFD_SEND (abfd, _bfd_make_empty_symbol, (abfd)) 2444 24452.7.5.9 `_bfd_generic_make_empty_symbol' 2446........................................ 2447 2448*Synopsis* 2449 asymbol *_bfd_generic_make_empty_symbol (bfd *); 2450 *Description* 2451Create a new `asymbol' structure for the BFD ABFD and return a pointer 2452to it. Used by core file routines, binary back-end and anywhere else 2453where no private info is needed. 2454 24552.7.5.10 `bfd_make_debug_symbol' 2456................................ 2457 2458*Description* 2459Create a new `asymbol' structure for the BFD ABFD, to be used as a 2460debugging symbol. Further details of its use have yet to be worked out. 2461 #define bfd_make_debug_symbol(abfd,ptr,size) \ 2462 BFD_SEND (abfd, _bfd_make_debug_symbol, (abfd, ptr, size)) 2463 24642.7.5.11 `bfd_decode_symclass' 2465.............................. 2466 2467*Description* 2468Return a character corresponding to the symbol class of SYMBOL, or '?' 2469for an unknown class. 2470 2471 *Synopsis* 2472 int bfd_decode_symclass (asymbol *symbol); 2473 24742.7.5.12 `bfd_is_undefined_symclass' 2475.................................... 2476 2477*Description* 2478Returns non-zero if the class symbol returned by bfd_decode_symclass 2479represents an undefined symbol. Returns zero otherwise. 2480 2481 *Synopsis* 2482 bfd_boolean bfd_is_undefined_symclass (int symclass); 2483 24842.7.5.13 `bfd_symbol_info' 2485.......................... 2486 2487*Description* 2488Fill in the basic info about symbol that nm needs. Additional info may 2489be added by the back-ends after calling this function. 2490 2491 *Synopsis* 2492 void bfd_symbol_info (asymbol *symbol, symbol_info *ret); 2493 24942.7.5.14 `bfd_copy_private_symbol_data' 2495....................................... 2496 2497*Synopsis* 2498 bfd_boolean bfd_copy_private_symbol_data 2499 (bfd *ibfd, asymbol *isym, bfd *obfd, asymbol *osym); 2500 *Description* 2501Copy private symbol information from ISYM in the BFD IBFD to the symbol 2502OSYM in the BFD OBFD. Return `TRUE' on success, `FALSE' on error. 2503Possible error returns are: 2504 2505 * `bfd_error_no_memory' - Not enough memory exists to create private 2506 data for OSEC. 2507 2508 #define bfd_copy_private_symbol_data(ibfd, isymbol, obfd, osymbol) \ 2509 BFD_SEND (obfd, _bfd_copy_private_symbol_data, \ 2510 (ibfd, isymbol, obfd, osymbol)) 2511 2512 2513File: bfd.info, Node: Archives, Next: Formats, Prev: Symbols, Up: BFD front end 2514 25152.8 Archives 2516============ 2517 2518*Description* 2519An archive (or library) is just another BFD. It has a symbol table, 2520although there's not much a user program will do with it. 2521 2522 The big difference between an archive BFD and an ordinary BFD is 2523that the archive doesn't have sections. Instead it has a chain of BFDs 2524that are considered its contents. These BFDs can be manipulated like 2525any other. The BFDs contained in an archive opened for reading will 2526all be opened for reading. You may put either input or output BFDs 2527into an archive opened for output; they will be handled correctly when 2528the archive is closed. 2529 2530 Use `bfd_openr_next_archived_file' to step through the contents of 2531an archive opened for input. You don't have to read the entire archive 2532if you don't want to! Read it until you find what you want. 2533 2534 Archive contents of output BFDs are chained through the `next' 2535pointer in a BFD. The first one is findable through the `archive_head' 2536slot of the archive. Set it with `bfd_set_archive_head' (q.v.). A 2537given BFD may be in only one open output archive at a time. 2538 2539 As expected, the BFD archive code is more general than the archive 2540code of any given environment. BFD archives may contain files of 2541different formats (e.g., a.out and coff) and even different 2542architectures. You may even place archives recursively into archives! 2543 2544 This can cause unexpected confusion, since some archive formats are 2545more expressive than others. For instance, Intel COFF archives can 2546preserve long filenames; SunOS a.out archives cannot. If you move a 2547file from the first to the second format and back again, the filename 2548may be truncated. Likewise, different a.out environments have different 2549conventions as to how they truncate filenames, whether they preserve 2550directory names in filenames, etc. When interoperating with native 2551tools, be sure your files are homogeneous. 2552 2553 Beware: most of these formats do not react well to the presence of 2554spaces in filenames. We do the best we can, but can't always handle 2555this case due to restrictions in the format of archives. Many Unix 2556utilities are braindead in regards to spaces and such in filenames 2557anyway, so this shouldn't be much of a restriction. 2558 2559 Archives are supported in BFD in `archive.c'. 2560 25612.8.1 Archive functions 2562----------------------- 2563 25642.8.1.1 `bfd_get_next_mapent' 2565............................. 2566 2567*Synopsis* 2568 symindex bfd_get_next_mapent 2569 (bfd *abfd, symindex previous, carsym **sym); 2570 *Description* 2571Step through archive ABFD's symbol table (if it has one). Successively 2572update SYM with the next symbol's information, returning that symbol's 2573(internal) index into the symbol table. 2574 2575 Supply `BFD_NO_MORE_SYMBOLS' as the PREVIOUS entry to get the first 2576one; returns `BFD_NO_MORE_SYMBOLS' when you've already got the last one. 2577 2578 A `carsym' is a canonical archive symbol. The only user-visible 2579element is its name, a null-terminated string. 2580 25812.8.1.2 `bfd_set_archive_head' 2582.............................. 2583 2584*Synopsis* 2585 bfd_boolean bfd_set_archive_head (bfd *output, bfd *new_head); 2586 *Description* 2587Set the head of the chain of BFDs contained in the archive OUTPUT to 2588NEW_HEAD. 2589 25902.8.1.3 `bfd_openr_next_archived_file' 2591...................................... 2592 2593*Synopsis* 2594 bfd *bfd_openr_next_archived_file (bfd *archive, bfd *previous); 2595 *Description* 2596Provided a BFD, ARCHIVE, containing an archive and NULL, open an input 2597BFD on the first contained element and returns that. Subsequent calls 2598should pass the archive and the previous return value to return a 2599created BFD to the next contained element. NULL is returned when there 2600are no more. 2601 2602 2603File: bfd.info, Node: Formats, Next: Relocations, Prev: Archives, Up: BFD front end 2604 26052.9 File formats 2606================ 2607 2608A format is a BFD concept of high level file contents type. The formats 2609supported by BFD are: 2610 2611 * `bfd_object' 2612 The BFD may contain data, symbols, relocations and debug info. 2613 2614 * `bfd_archive' 2615 The BFD contains other BFDs and an optional index. 2616 2617 * `bfd_core' 2618 The BFD contains the result of an executable core dump. 2619 26202.9.1 File format functions 2621--------------------------- 2622 26232.9.1.1 `bfd_check_format' 2624.......................... 2625 2626*Synopsis* 2627 bfd_boolean bfd_check_format (bfd *abfd, bfd_format format); 2628 *Description* 2629Verify if the file attached to the BFD ABFD is compatible with the 2630format FORMAT (i.e., one of `bfd_object', `bfd_archive' or `bfd_core'). 2631 2632 If the BFD has been set to a specific target before the call, only 2633the named target and format combination is checked. If the target has 2634not been set, or has been set to `default', then all the known target 2635backends is interrogated to determine a match. If the default target 2636matches, it is used. If not, exactly one target must recognize the 2637file, or an error results. 2638 2639 The function returns `TRUE' on success, otherwise `FALSE' with one 2640of the following error codes: 2641 2642 * `bfd_error_invalid_operation' - if `format' is not one of 2643 `bfd_object', `bfd_archive' or `bfd_core'. 2644 2645 * `bfd_error_system_call' - if an error occured during a read - even 2646 some file mismatches can cause bfd_error_system_calls. 2647 2648 * `file_not_recognised' - none of the backends recognised the file 2649 format. 2650 2651 * `bfd_error_file_ambiguously_recognized' - more than one backend 2652 recognised the file format. 2653 26542.9.1.2 `bfd_check_format_matches' 2655.................................. 2656 2657*Synopsis* 2658 bfd_boolean bfd_check_format_matches 2659 (bfd *abfd, bfd_format format, char ***matching); 2660 *Description* 2661Like `bfd_check_format', except when it returns FALSE with `bfd_errno' 2662set to `bfd_error_file_ambiguously_recognized'. In that case, if 2663MATCHING is not NULL, it will be filled in with a NULL-terminated list 2664of the names of the formats that matched, allocated with `malloc'. 2665Then the user may choose a format and try again. 2666 2667 When done with the list that MATCHING points to, the caller should 2668free it. 2669 26702.9.1.3 `bfd_set_format' 2671........................ 2672 2673*Synopsis* 2674 bfd_boolean bfd_set_format (bfd *abfd, bfd_format format); 2675 *Description* 2676This function sets the file format of the BFD ABFD to the format 2677FORMAT. If the target set in the BFD does not support the format 2678requested, the format is invalid, or the BFD is not open for writing, 2679then an error occurs. 2680 26812.9.1.4 `bfd_format_string' 2682........................... 2683 2684*Synopsis* 2685 const char *bfd_format_string (bfd_format format); 2686 *Description* 2687Return a pointer to a const string `invalid', `object', `archive', 2688`core', or `unknown', depending upon the value of FORMAT. 2689 2690 2691File: bfd.info, Node: Relocations, Next: Core Files, Prev: Formats, Up: BFD front end 2692 26932.10 Relocations 2694================ 2695 2696BFD maintains relocations in much the same way it maintains symbols: 2697they are left alone until required, then read in en-masse and 2698translated into an internal form. A common routine 2699`bfd_perform_relocation' acts upon the canonical form to do the fixup. 2700 2701 Relocations are maintained on a per section basis, while symbols are 2702maintained on a per BFD basis. 2703 2704 All that a back end has to do to fit the BFD interface is to create 2705a `struct reloc_cache_entry' for each relocation in a particular 2706section, and fill in the right bits of the structures. 2707 2708* Menu: 2709 2710* typedef arelent:: 2711* howto manager:: 2712 2713 2714File: bfd.info, Node: typedef arelent, Next: howto manager, Prev: Relocations, Up: Relocations 2715 27162.10.1 typedef arelent 2717---------------------- 2718 2719This is the structure of a relocation entry: 2720 2721 2722 typedef enum bfd_reloc_status 2723 { 2724 /* No errors detected. */ 2725 bfd_reloc_ok, 2726 2727 /* The relocation was performed, but there was an overflow. */ 2728 bfd_reloc_overflow, 2729 2730 /* The address to relocate was not within the section supplied. */ 2731 bfd_reloc_outofrange, 2732 2733 /* Used by special functions. */ 2734 bfd_reloc_continue, 2735 2736 /* Unsupported relocation size requested. */ 2737 bfd_reloc_notsupported, 2738 2739 /* Unused. */ 2740 bfd_reloc_other, 2741 2742 /* The symbol to relocate against was undefined. */ 2743 bfd_reloc_undefined, 2744 2745 /* The relocation was performed, but may not be ok - presently 2746 generated only when linking i960 coff files with i960 b.out 2747 symbols. If this type is returned, the error_message argument 2748 to bfd_perform_relocation will be set. */ 2749 bfd_reloc_dangerous 2750 } 2751 bfd_reloc_status_type; 2752 2753 2754 typedef struct reloc_cache_entry 2755 { 2756 /* A pointer into the canonical table of pointers. */ 2757 struct bfd_symbol **sym_ptr_ptr; 2758 2759 /* offset in section. */ 2760 bfd_size_type address; 2761 2762 /* addend for relocation value. */ 2763 bfd_vma addend; 2764 2765 /* Pointer to how to perform the required relocation. */ 2766 reloc_howto_type *howto; 2767 2768 } 2769 arelent; 2770 *Description* 2771Here is a description of each of the fields within an `arelent': 2772 2773 * `sym_ptr_ptr' 2774 The symbol table pointer points to a pointer to the symbol 2775associated with the relocation request. It is the pointer into the 2776table returned by the back end's `canonicalize_symtab' action. *Note 2777Symbols::. The symbol is referenced through a pointer to a pointer so 2778that tools like the linker can fix up all the symbols of the same name 2779by modifying only one pointer. The relocation routine looks in the 2780symbol and uses the base of the section the symbol is attached to and 2781the value of the symbol as the initial relocation offset. If the symbol 2782pointer is zero, then the section provided is looked up. 2783 2784 * `address' 2785 The `address' field gives the offset in bytes from the base of the 2786section data which owns the relocation record to the first byte of 2787relocatable information. The actual data relocated will be relative to 2788this point; for example, a relocation type which modifies the bottom 2789two bytes of a four byte word would not touch the first byte pointed to 2790in a big endian world. 2791 2792 * `addend' 2793 The `addend' is a value provided by the back end to be added (!) to 2794the relocation offset. Its interpretation is dependent upon the howto. 2795For example, on the 68k the code: 2796 2797 char foo[]; 2798 main() 2799 { 2800 return foo[0x12345678]; 2801 } 2802 2803 Could be compiled into: 2804 2805 linkw fp,#-4 2806 moveb @#12345678,d0 2807 extbl d0 2808 unlk fp 2809 rts 2810 2811 This could create a reloc pointing to `foo', but leave the offset in 2812the data, something like: 2813 2814 RELOCATION RECORDS FOR [.text]: 2815 offset type value 2816 00000006 32 _foo 2817 2818 00000000 4e56 fffc ; linkw fp,#-4 2819 00000004 1039 1234 5678 ; moveb @#12345678,d0 2820 0000000a 49c0 ; extbl d0 2821 0000000c 4e5e ; unlk fp 2822 0000000e 4e75 ; rts 2823 2824 Using coff and an 88k, some instructions don't have enough space in 2825them to represent the full address range, and pointers have to be 2826loaded in two parts. So you'd get something like: 2827 2828 or.u r13,r0,hi16(_foo+0x12345678) 2829 ld.b r2,r13,lo16(_foo+0x12345678) 2830 jmp r1 2831 2832 This should create two relocs, both pointing to `_foo', and with 28330x12340000 in their addend field. The data would consist of: 2834 2835 RELOCATION RECORDS FOR [.text]: 2836 offset type value 2837 00000002 HVRT16 _foo+0x12340000 2838 00000006 LVRT16 _foo+0x12340000 2839 2840 00000000 5da05678 ; or.u r13,r0,0x5678 2841 00000004 1c4d5678 ; ld.b r2,r13,0x5678 2842 00000008 f400c001 ; jmp r1 2843 2844 The relocation routine digs out the value from the data, adds it to 2845the addend to get the original offset, and then adds the value of 2846`_foo'. Note that all 32 bits have to be kept around somewhere, to cope 2847with carry from bit 15 to bit 16. 2848 2849 One further example is the sparc and the a.out format. The sparc has 2850a similar problem to the 88k, in that some instructions don't have room 2851for an entire offset, but on the sparc the parts are created in odd 2852sized lumps. The designers of the a.out format chose to not use the 2853data within the section for storing part of the offset; all the offset 2854is kept within the reloc. Anything in the data should be ignored. 2855 2856 save %sp,-112,%sp 2857 sethi %hi(_foo+0x12345678),%g2 2858 ldsb [%g2+%lo(_foo+0x12345678)],%i0 2859 ret 2860 restore 2861 2862 Both relocs contain a pointer to `foo', and the offsets contain junk. 2863 2864 RELOCATION RECORDS FOR [.text]: 2865 offset type value 2866 00000004 HI22 _foo+0x12345678 2867 00000008 LO10 _foo+0x12345678 2868 2869 00000000 9de3bf90 ; save %sp,-112,%sp 2870 00000004 05000000 ; sethi %hi(_foo+0),%g2 2871 00000008 f048a000 ; ldsb [%g2+%lo(_foo+0)],%i0 2872 0000000c 81c7e008 ; ret 2873 00000010 81e80000 ; restore 2874 2875 * `howto' 2876 The `howto' field can be imagined as a relocation instruction. It is 2877a pointer to a structure which contains information on what to do with 2878all of the other information in the reloc record and data section. A 2879back end would normally have a relocation instruction set and turn 2880relocations into pointers to the correct structure on input - but it 2881would be possible to create each howto field on demand. 2882 28832.10.1.1 `enum complain_overflow' 2884................................. 2885 2886Indicates what sort of overflow checking should be done when performing 2887a relocation. 2888 2889 2890 enum complain_overflow 2891 { 2892 /* Do not complain on overflow. */ 2893 complain_overflow_dont, 2894 2895 /* Complain if the value overflows when considered as a signed 2896 number one bit larger than the field. ie. A bitfield of N bits 2897 is allowed to represent -2**n to 2**n-1. */ 2898 complain_overflow_bitfield, 2899 2900 /* Complain if the value overflows when considered as a signed 2901 number. */ 2902 complain_overflow_signed, 2903 2904 /* Complain if the value overflows when considered as an 2905 unsigned number. */ 2906 complain_overflow_unsigned 2907 }; 2908 29092.10.1.2 `reloc_howto_type' 2910........................... 2911 2912The `reloc_howto_type' is a structure which contains all the 2913information that libbfd needs to know to tie up a back end's data. 2914 2915 struct bfd_symbol; /* Forward declaration. */ 2916 2917 struct reloc_howto_struct 2918 { 2919 /* The type field has mainly a documentary use - the back end can 2920 do what it wants with it, though normally the back end's 2921 external idea of what a reloc number is stored 2922 in this field. For example, a PC relative word relocation 2923 in a coff environment has the type 023 - because that's 2924 what the outside world calls a R_PCRWORD reloc. */ 2925 unsigned int type; 2926 2927 /* The value the final relocation is shifted right by. This drops 2928 unwanted data from the relocation. */ 2929 unsigned int rightshift; 2930 2931 /* The size of the item to be relocated. This is *not* a 2932 power-of-two measure. To get the number of bytes operated 2933 on by a type of relocation, use bfd_get_reloc_size. */ 2934 int size; 2935 2936 /* The number of bits in the item to be relocated. This is used 2937 when doing overflow checking. */ 2938 unsigned int bitsize; 2939 2940 /* Notes that the relocation is relative to the location in the 2941 data section of the addend. The relocation function will 2942 subtract from the relocation value the address of the location 2943 being relocated. */ 2944 bfd_boolean pc_relative; 2945 2946 /* The bit position of the reloc value in the destination. 2947 The relocated value is left shifted by this amount. */ 2948 unsigned int bitpos; 2949 2950 /* What type of overflow error should be checked for when 2951 relocating. */ 2952 enum complain_overflow complain_on_overflow; 2953 2954 /* If this field is non null, then the supplied function is 2955 called rather than the normal function. This allows really 2956 strange relocation methods to be accommodated (e.g., i960 callj 2957 instructions). */ 2958 bfd_reloc_status_type (*special_function) 2959 (bfd *, arelent *, struct bfd_symbol *, void *, asection *, 2960 bfd *, char **); 2961 2962 /* The textual name of the relocation type. */ 2963 char *name; 2964 2965 /* Some formats record a relocation addend in the section contents 2966 rather than with the relocation. For ELF formats this is the 2967 distinction between USE_REL and USE_RELA (though the code checks 2968 for USE_REL == 1/0). The value of this field is TRUE if the 2969 addend is recorded with the section contents; when performing a 2970 partial link (ld -r) the section contents (the data) will be 2971 modified. The value of this field is FALSE if addends are 2972 recorded with the relocation (in arelent.addend); when performing 2973 a partial link the relocation will be modified. 2974 All relocations for all ELF USE_RELA targets should set this field 2975 to FALSE (values of TRUE should be looked on with suspicion). 2976 However, the converse is not true: not all relocations of all ELF 2977 USE_REL targets set this field to TRUE. Why this is so is peculiar 2978 to each particular target. For relocs that aren't used in partial 2979 links (e.g. GOT stuff) it doesn't matter what this is set to. */ 2980 bfd_boolean partial_inplace; 2981 2982 /* src_mask selects the part of the instruction (or data) to be used 2983 in the relocation sum. If the target relocations don't have an 2984 addend in the reloc, eg. ELF USE_REL, src_mask will normally equal 2985 dst_mask to extract the addend from the section contents. If 2986 relocations do have an addend in the reloc, eg. ELF USE_RELA, this 2987 field should be zero. Non-zero values for ELF USE_RELA targets are 2988 bogus as in those cases the value in the dst_mask part of the 2989 section contents should be treated as garbage. */ 2990 bfd_vma src_mask; 2991 2992 /* dst_mask selects which parts of the instruction (or data) are 2993 replaced with a relocated value. */ 2994 bfd_vma dst_mask; 2995 2996 /* When some formats create PC relative instructions, they leave 2997 the value of the pc of the place being relocated in the offset 2998 slot of the instruction, so that a PC relative relocation can 2999 be made just by adding in an ordinary offset (e.g., sun3 a.out). 3000 Some formats leave the displacement part of an instruction 3001 empty (e.g., m88k bcs); this flag signals the fact. */ 3002 bfd_boolean pcrel_offset; 3003 }; 3004 30052.10.1.3 `The HOWTO Macro' 3006.......................... 3007 3008*Description* 3009The HOWTO define is horrible and will go away. 3010 #define HOWTO(C, R, S, B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC) \ 3011 { (unsigned) C, R, S, B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC } 3012 3013 *Description* 3014And will be replaced with the totally magic way. But for the moment, we 3015are compatible, so do it this way. 3016 #define NEWHOWTO(FUNCTION, NAME, SIZE, REL, IN) \ 3017 HOWTO (0, 0, SIZE, 0, REL, 0, complain_overflow_dont, FUNCTION, \ 3018 NAME, FALSE, 0, 0, IN) 3019 3020 *Description* 3021This is used to fill in an empty howto entry in an array. 3022 #define EMPTY_HOWTO(C) \ 3023 HOWTO ((C), 0, 0, 0, FALSE, 0, complain_overflow_dont, NULL, \ 3024 NULL, FALSE, 0, 0, FALSE) 3025 3026 *Description* 3027Helper routine to turn a symbol into a relocation value. 3028 #define HOWTO_PREPARE(relocation, symbol) \ 3029 { \ 3030 if (symbol != NULL) \ 3031 { \ 3032 if (bfd_is_com_section (symbol->section)) \ 3033 { \ 3034 relocation = 0; \ 3035 } \ 3036 else \ 3037 { \ 3038 relocation = symbol->value; \ 3039 } \ 3040 } \ 3041 } 3042 30432.10.1.4 `bfd_get_reloc_size' 3044............................. 3045 3046*Synopsis* 3047 unsigned int bfd_get_reloc_size (reloc_howto_type *); 3048 *Description* 3049For a reloc_howto_type that operates on a fixed number of bytes, this 3050returns the number of bytes operated on. 3051 30522.10.1.5 `arelent_chain' 3053........................ 3054 3055*Description* 3056How relocs are tied together in an `asection': 3057 typedef struct relent_chain 3058 { 3059 arelent relent; 3060 struct relent_chain *next; 3061 } 3062 arelent_chain; 3063 30642.10.1.6 `bfd_check_overflow' 3065............................. 3066 3067*Synopsis* 3068 bfd_reloc_status_type bfd_check_overflow 3069 (enum complain_overflow how, 3070 unsigned int bitsize, 3071 unsigned int rightshift, 3072 unsigned int addrsize, 3073 bfd_vma relocation); 3074 *Description* 3075Perform overflow checking on RELOCATION which has BITSIZE significant 3076bits and will be shifted right by RIGHTSHIFT bits, on a machine with 3077addresses containing ADDRSIZE significant bits. The result is either of 3078`bfd_reloc_ok' or `bfd_reloc_overflow'. 3079 30802.10.1.7 `bfd_perform_relocation' 3081................................. 3082 3083*Synopsis* 3084 bfd_reloc_status_type bfd_perform_relocation 3085 (bfd *abfd, 3086 arelent *reloc_entry, 3087 void *data, 3088 asection *input_section, 3089 bfd *output_bfd, 3090 char **error_message); 3091 *Description* 3092If OUTPUT_BFD is supplied to this function, the generated image will be 3093relocatable; the relocations are copied to the output file after they 3094have been changed to reflect the new state of the world. There are two 3095ways of reflecting the results of partial linkage in an output file: by 3096modifying the output data in place, and by modifying the relocation 3097record. Some native formats (e.g., basic a.out and basic coff) have no 3098way of specifying an addend in the relocation type, so the addend has 3099to go in the output data. This is no big deal since in these formats 3100the output data slot will always be big enough for the addend. Complex 3101reloc types with addends were invented to solve just this problem. The 3102ERROR_MESSAGE argument is set to an error message if this return 3103`bfd_reloc_dangerous'. 3104 31052.10.1.8 `bfd_install_relocation' 3106................................. 3107 3108*Synopsis* 3109 bfd_reloc_status_type bfd_install_relocation 3110 (bfd *abfd, 3111 arelent *reloc_entry, 3112 void *data, bfd_vma data_start, 3113 asection *input_section, 3114 char **error_message); 3115 *Description* 3116This looks remarkably like `bfd_perform_relocation', except it does not 3117expect that the section contents have been filled in. I.e., it's 3118suitable for use when creating, rather than applying a relocation. 3119 3120 For now, this function should be considered reserved for the 3121assembler. 3122 3123 3124File: bfd.info, Node: howto manager, Prev: typedef arelent, Up: Relocations 3125 31262.10.2 The howto manager 3127------------------------ 3128 3129When an application wants to create a relocation, but doesn't know what 3130the target machine might call it, it can find out by using this bit of 3131code. 3132 31332.10.2.1 `bfd_reloc_code_type' 3134.............................. 3135 3136*Description* 3137The insides of a reloc code. The idea is that, eventually, there will 3138be one enumerator for every type of relocation we ever do. Pass one of 3139these values to `bfd_reloc_type_lookup', and it'll return a howto 3140pointer. 3141 3142 This does mean that the application must determine the correct 3143enumerator value; you can't get a howto pointer from a random set of 3144attributes. 3145 3146 Here are the possible values for `enum bfd_reloc_code_real': 3147 3148 -- : BFD_RELOC_64 3149 -- : BFD_RELOC_32 3150 -- : BFD_RELOC_26 3151 -- : BFD_RELOC_24 3152 -- : BFD_RELOC_16 3153 -- : BFD_RELOC_14 3154 -- : BFD_RELOC_8 3155 Basic absolute relocations of N bits. 3156 3157 -- : BFD_RELOC_64_PCREL 3158 -- : BFD_RELOC_32_PCREL 3159 -- : BFD_RELOC_24_PCREL 3160 -- : BFD_RELOC_16_PCREL 3161 -- : BFD_RELOC_12_PCREL 3162 -- : BFD_RELOC_8_PCREL 3163 PC-relative relocations. Sometimes these are relative to the 3164 address of the relocation itself; sometimes they are relative to 3165 the start of the section containing the relocation. It depends on 3166 the specific target. 3167 3168 The 24-bit relocation is used in some Intel 960 configurations. 3169 3170 -- : BFD_RELOC_32_SECREL 3171 Section relative relocations. Some targets need this for DWARF2. 3172 3173 -- : BFD_RELOC_32_GOT_PCREL 3174 -- : BFD_RELOC_16_GOT_PCREL 3175 -- : BFD_RELOC_8_GOT_PCREL 3176 -- : BFD_RELOC_32_GOTOFF 3177 -- : BFD_RELOC_16_GOTOFF 3178 -- : BFD_RELOC_LO16_GOTOFF 3179 -- : BFD_RELOC_HI16_GOTOFF 3180 -- : BFD_RELOC_HI16_S_GOTOFF 3181 -- : BFD_RELOC_8_GOTOFF 3182 -- : BFD_RELOC_64_PLT_PCREL 3183 -- : BFD_RELOC_32_PLT_PCREL 3184 -- : BFD_RELOC_24_PLT_PCREL 3185 -- : BFD_RELOC_16_PLT_PCREL 3186 -- : BFD_RELOC_8_PLT_PCREL 3187 -- : BFD_RELOC_64_PLTOFF 3188 -- : BFD_RELOC_32_PLTOFF 3189 -- : BFD_RELOC_16_PLTOFF 3190 -- : BFD_RELOC_LO16_PLTOFF 3191 -- : BFD_RELOC_HI16_PLTOFF 3192 -- : BFD_RELOC_HI16_S_PLTOFF 3193 -- : BFD_RELOC_8_PLTOFF 3194 For ELF. 3195 3196 -- : BFD_RELOC_68K_GLOB_DAT 3197 -- : BFD_RELOC_68K_JMP_SLOT 3198 -- : BFD_RELOC_68K_RELATIVE 3199 Relocations used by 68K ELF. 3200 3201 -- : BFD_RELOC_32_BASEREL 3202 -- : BFD_RELOC_16_BASEREL 3203 -- : BFD_RELOC_LO16_BASEREL 3204 -- : BFD_RELOC_HI16_BASEREL 3205 -- : BFD_RELOC_HI16_S_BASEREL 3206 -- : BFD_RELOC_8_BASEREL 3207 -- : BFD_RELOC_RVA 3208 Linkage-table relative. 3209 3210 -- : BFD_RELOC_8_FFnn 3211 Absolute 8-bit relocation, but used to form an address like 0xFFnn. 3212 3213 -- : BFD_RELOC_32_PCREL_S2 3214 -- : BFD_RELOC_16_PCREL_S2 3215 -- : BFD_RELOC_23_PCREL_S2 3216 These PC-relative relocations are stored as word displacements - 3217 i.e., byte displacements shifted right two bits. The 30-bit word 3218 displacement (<<32_PCREL_S2>> - 32 bits, shifted 2) is used on the 3219 SPARC. (SPARC tools generally refer to this as <<WDISP30>>.) The 3220 signed 16-bit displacement is used on the MIPS, and the 23-bit 3221 displacement is used on the Alpha. 3222 3223 -- : BFD_RELOC_HI22 3224 -- : BFD_RELOC_LO10 3225 High 22 bits and low 10 bits of 32-bit value, placed into lower 3226 bits of the target word. These are used on the SPARC. 3227 3228 -- : BFD_RELOC_GPREL16 3229 -- : BFD_RELOC_GPREL32 3230 For systems that allocate a Global Pointer register, these are 3231 displacements off that register. These relocation types are 3232 handled specially, because the value the register will have is 3233 decided relatively late. 3234 3235 -- : BFD_RELOC_I960_CALLJ 3236 Reloc types used for i960/b.out. 3237 3238 -- : BFD_RELOC_NONE 3239 -- : BFD_RELOC_SPARC_WDISP22 3240 -- : BFD_RELOC_SPARC22 3241 -- : BFD_RELOC_SPARC13 3242 -- : BFD_RELOC_SPARC_GOT10 3243 -- : BFD_RELOC_SPARC_GOT13 3244 -- : BFD_RELOC_SPARC_GOT22 3245 -- : BFD_RELOC_SPARC_PC10 3246 -- : BFD_RELOC_SPARC_PC22 3247 -- : BFD_RELOC_SPARC_WPLT30 3248 -- : BFD_RELOC_SPARC_COPY 3249 -- : BFD_RELOC_SPARC_GLOB_DAT 3250 -- : BFD_RELOC_SPARC_JMP_SLOT 3251 -- : BFD_RELOC_SPARC_RELATIVE 3252 -- : BFD_RELOC_SPARC_UA16 3253 -- : BFD_RELOC_SPARC_UA32 3254 -- : BFD_RELOC_SPARC_UA64 3255 SPARC ELF relocations. There is probably some overlap with other 3256 relocation types already defined. 3257 3258 -- : BFD_RELOC_SPARC_BASE13 3259 -- : BFD_RELOC_SPARC_BASE22 3260 I think these are specific to SPARC a.out (e.g., Sun 4). 3261 3262 -- : BFD_RELOC_SPARC_64 3263 -- : BFD_RELOC_SPARC_10 3264 -- : BFD_RELOC_SPARC_11 3265 -- : BFD_RELOC_SPARC_OLO10 3266 -- : BFD_RELOC_SPARC_HH22 3267 -- : BFD_RELOC_SPARC_HM10 3268 -- : BFD_RELOC_SPARC_LM22 3269 -- : BFD_RELOC_SPARC_PC_HH22 3270 -- : BFD_RELOC_SPARC_PC_HM10 3271 -- : BFD_RELOC_SPARC_PC_LM22 3272 -- : BFD_RELOC_SPARC_WDISP16 3273 -- : BFD_RELOC_SPARC_WDISP19 3274 -- : BFD_RELOC_SPARC_7 3275 -- : BFD_RELOC_SPARC_6 3276 -- : BFD_RELOC_SPARC_5 3277 -- : BFD_RELOC_SPARC_DISP64 3278 -- : BFD_RELOC_SPARC_PLT32 3279 -- : BFD_RELOC_SPARC_PLT64 3280 -- : BFD_RELOC_SPARC_HIX22 3281 -- : BFD_RELOC_SPARC_LOX10 3282 -- : BFD_RELOC_SPARC_H44 3283 -- : BFD_RELOC_SPARC_M44 3284 -- : BFD_RELOC_SPARC_L44 3285 -- : BFD_RELOC_SPARC_REGISTER 3286 SPARC64 relocations 3287 3288 -- : BFD_RELOC_SPARC_REV32 3289 SPARC little endian relocation 3290 3291 -- : BFD_RELOC_SPARC_TLS_GD_HI22 3292 -- : BFD_RELOC_SPARC_TLS_GD_LO10 3293 -- : BFD_RELOC_SPARC_TLS_GD_ADD 3294 -- : BFD_RELOC_SPARC_TLS_GD_CALL 3295 -- : BFD_RELOC_SPARC_TLS_LDM_HI22 3296 -- : BFD_RELOC_SPARC_TLS_LDM_LO10 3297 -- : BFD_RELOC_SPARC_TLS_LDM_ADD 3298 -- : BFD_RELOC_SPARC_TLS_LDM_CALL 3299 -- : BFD_RELOC_SPARC_TLS_LDO_HIX22 3300 -- : BFD_RELOC_SPARC_TLS_LDO_LOX10 3301 -- : BFD_RELOC_SPARC_TLS_LDO_ADD 3302 -- : BFD_RELOC_SPARC_TLS_IE_HI22 3303 -- : BFD_RELOC_SPARC_TLS_IE_LO10 3304 -- : BFD_RELOC_SPARC_TLS_IE_LD 3305 -- : BFD_RELOC_SPARC_TLS_IE_LDX 3306 -- : BFD_RELOC_SPARC_TLS_IE_ADD 3307 -- : BFD_RELOC_SPARC_TLS_LE_HIX22 3308 -- : BFD_RELOC_SPARC_TLS_LE_LOX10 3309 -- : BFD_RELOC_SPARC_TLS_DTPMOD32 3310 -- : BFD_RELOC_SPARC_TLS_DTPMOD64 3311 -- : BFD_RELOC_SPARC_TLS_DTPOFF32 3312 -- : BFD_RELOC_SPARC_TLS_DTPOFF64 3313 -- : BFD_RELOC_SPARC_TLS_TPOFF32 3314 -- : BFD_RELOC_SPARC_TLS_TPOFF64 3315 SPARC TLS relocations 3316 3317 -- : BFD_RELOC_SPU_IMM7 3318 -- : BFD_RELOC_SPU_IMM8 3319 -- : BFD_RELOC_SPU_IMM10 3320 -- : BFD_RELOC_SPU_IMM10W 3321 -- : BFD_RELOC_SPU_IMM16 3322 -- : BFD_RELOC_SPU_IMM16W 3323 -- : BFD_RELOC_SPU_IMM18 3324 -- : BFD_RELOC_SPU_PCREL9a 3325 -- : BFD_RELOC_SPU_PCREL9b 3326 -- : BFD_RELOC_SPU_PCREL16 3327 -- : BFD_RELOC_SPU_LO16 3328 -- : BFD_RELOC_SPU_HI16 3329 -- : BFD_RELOC_SPU_PPU32 3330 -- : BFD_RELOC_SPU_PPU64 3331 SPU Relocations. 3332 3333 -- : BFD_RELOC_ALPHA_GPDISP_HI16 3334 Alpha ECOFF and ELF relocations. Some of these treat the symbol or 3335 "addend" in some special way. For GPDISP_HI16 ("gpdisp") 3336 relocations, the symbol is ignored when writing; when reading, it 3337 will be the absolute section symbol. The addend is the 3338 displacement in bytes of the "lda" instruction from the "ldah" 3339 instruction (which is at the address of this reloc). 3340 3341 -- : BFD_RELOC_ALPHA_GPDISP_LO16 3342 For GPDISP_LO16 ("ignore") relocations, the symbol is handled as 3343 with GPDISP_HI16 relocs. The addend is ignored when writing the 3344 relocations out, and is filled in with the file's GP value on 3345 reading, for convenience. 3346 3347 -- : BFD_RELOC_ALPHA_GPDISP 3348 The ELF GPDISP relocation is exactly the same as the GPDISP_HI16 3349 relocation except that there is no accompanying GPDISP_LO16 3350 relocation. 3351 3352 -- : BFD_RELOC_ALPHA_LITERAL 3353 -- : BFD_RELOC_ALPHA_ELF_LITERAL 3354 -- : BFD_RELOC_ALPHA_LITUSE 3355 The Alpha LITERAL/LITUSE relocs are produced by a symbol reference; 3356 the assembler turns it into a LDQ instruction to load the address 3357 of the symbol, and then fills in a register in the real 3358 instruction. 3359 3360 The LITERAL reloc, at the LDQ instruction, refers to the .lita 3361 section symbol. The addend is ignored when writing, but is filled 3362 in with the file's GP value on reading, for convenience, as with 3363 the GPDISP_LO16 reloc. 3364 3365 The ELF_LITERAL reloc is somewhere between 16_GOTOFF and 3366 GPDISP_LO16. It should refer to the symbol to be referenced, as 3367 with 16_GOTOFF, but it generates output not based on the position 3368 within the .got section, but relative to the GP value chosen for 3369 the file during the final link stage. 3370 3371 The LITUSE reloc, on the instruction using the loaded address, 3372 gives information to the linker that it might be able to use to 3373 optimize away some literal section references. The symbol is 3374 ignored (read as the absolute section symbol), and the "addend" 3375 indicates the type of instruction using the register: 1 - "memory" 3376 fmt insn 2 - byte-manipulation (byte offset reg) 3 - jsr (target 3377 of branch) 3378 3379 -- : BFD_RELOC_ALPHA_HINT 3380 The HINT relocation indicates a value that should be filled into 3381 the "hint" field of a jmp/jsr/ret instruction, for possible branch- 3382 prediction logic which may be provided on some processors. 3383 3384 -- : BFD_RELOC_ALPHA_LINKAGE 3385 The LINKAGE relocation outputs a linkage pair in the object file, 3386 which is filled by the linker. 3387 3388 -- : BFD_RELOC_ALPHA_CODEADDR 3389 The CODEADDR relocation outputs a STO_CA in the object file, which 3390 is filled by the linker. 3391 3392 -- : BFD_RELOC_ALPHA_GPREL_HI16 3393 -- : BFD_RELOC_ALPHA_GPREL_LO16 3394 The GPREL_HI/LO relocations together form a 32-bit offset from the 3395 GP register. 3396 3397 -- : BFD_RELOC_ALPHA_BRSGP 3398 Like BFD_RELOC_23_PCREL_S2, except that the source and target must 3399 share a common GP, and the target address is adjusted for 3400 STO_ALPHA_STD_GPLOAD. 3401 3402 -- : BFD_RELOC_ALPHA_TLSGD 3403 -- : BFD_RELOC_ALPHA_TLSLDM 3404 -- : BFD_RELOC_ALPHA_DTPMOD64 3405 -- : BFD_RELOC_ALPHA_GOTDTPREL16 3406 -- : BFD_RELOC_ALPHA_DTPREL64 3407 -- : BFD_RELOC_ALPHA_DTPREL_HI16 3408 -- : BFD_RELOC_ALPHA_DTPREL_LO16 3409 -- : BFD_RELOC_ALPHA_DTPREL16 3410 -- : BFD_RELOC_ALPHA_GOTTPREL16 3411 -- : BFD_RELOC_ALPHA_TPREL64 3412 -- : BFD_RELOC_ALPHA_TPREL_HI16 3413 -- : BFD_RELOC_ALPHA_TPREL_LO16 3414 -- : BFD_RELOC_ALPHA_TPREL16 3415 Alpha thread-local storage relocations. 3416 3417 -- : BFD_RELOC_MIPS_JMP 3418 Bits 27..2 of the relocation address shifted right 2 bits; simple 3419 reloc otherwise. 3420 3421 -- : BFD_RELOC_MIPS16_JMP 3422 The MIPS16 jump instruction. 3423 3424 -- : BFD_RELOC_MIPS16_GPREL 3425 MIPS16 GP relative reloc. 3426 3427 -- : BFD_RELOC_HI16 3428 High 16 bits of 32-bit value; simple reloc. 3429 3430 -- : BFD_RELOC_HI16_S 3431 High 16 bits of 32-bit value but the low 16 bits will be sign 3432 extended and added to form the final result. If the low 16 bits 3433 form a negative number, we need to add one to the high value to 3434 compensate for the borrow when the low bits are added. 3435 3436 -- : BFD_RELOC_LO16 3437 Low 16 bits. 3438 3439 -- : BFD_RELOC_HI16_PCREL 3440 High 16 bits of 32-bit pc-relative value 3441 3442 -- : BFD_RELOC_HI16_S_PCREL 3443 High 16 bits of 32-bit pc-relative value, adjusted 3444 3445 -- : BFD_RELOC_LO16_PCREL 3446 Low 16 bits of pc-relative value 3447 3448 -- : BFD_RELOC_MIPS16_HI16 3449 MIPS16 high 16 bits of 32-bit value. 3450 3451 -- : BFD_RELOC_MIPS16_HI16_S 3452 MIPS16 high 16 bits of 32-bit value but the low 16 bits will be 3453 sign extended and added to form the final result. If the low 16 3454 bits form a negative number, we need to add one to the high value 3455 to compensate for the borrow when the low bits are added. 3456 3457 -- : BFD_RELOC_MIPS16_LO16 3458 MIPS16 low 16 bits. 3459 3460 -- : BFD_RELOC_MIPS_LITERAL 3461 Relocation against a MIPS literal section. 3462 3463 -- : BFD_RELOC_MIPS_GOT16 3464 -- : BFD_RELOC_MIPS_CALL16 3465 -- : BFD_RELOC_MIPS_GOT_HI16 3466 -- : BFD_RELOC_MIPS_GOT_LO16 3467 -- : BFD_RELOC_MIPS_CALL_HI16 3468 -- : BFD_RELOC_MIPS_CALL_LO16 3469 -- : BFD_RELOC_MIPS_SUB 3470 -- : BFD_RELOC_MIPS_GOT_PAGE 3471 -- : BFD_RELOC_MIPS_GOT_OFST 3472 -- : BFD_RELOC_MIPS_GOT_DISP 3473 -- : BFD_RELOC_MIPS_SHIFT5 3474 -- : BFD_RELOC_MIPS_SHIFT6 3475 -- : BFD_RELOC_MIPS_INSERT_A 3476 -- : BFD_RELOC_MIPS_INSERT_B 3477 -- : BFD_RELOC_MIPS_DELETE 3478 -- : BFD_RELOC_MIPS_HIGHEST 3479 -- : BFD_RELOC_MIPS_HIGHER 3480 -- : BFD_RELOC_MIPS_SCN_DISP 3481 -- : BFD_RELOC_MIPS_REL16 3482 -- : BFD_RELOC_MIPS_RELGOT 3483 -- : BFD_RELOC_MIPS_JALR 3484 -- : BFD_RELOC_MIPS_TLS_DTPMOD32 3485 -- : BFD_RELOC_MIPS_TLS_DTPREL32 3486 -- : BFD_RELOC_MIPS_TLS_DTPMOD64 3487 -- : BFD_RELOC_MIPS_TLS_DTPREL64 3488 -- : BFD_RELOC_MIPS_TLS_GD 3489 -- : BFD_RELOC_MIPS_TLS_LDM 3490 -- : BFD_RELOC_MIPS_TLS_DTPREL_HI16 3491 -- : BFD_RELOC_MIPS_TLS_DTPREL_LO16 3492 -- : BFD_RELOC_MIPS_TLS_GOTTPREL 3493 -- : BFD_RELOC_MIPS_TLS_TPREL32 3494 -- : BFD_RELOC_MIPS_TLS_TPREL64 3495 -- : BFD_RELOC_MIPS_TLS_TPREL_HI16 3496 -- : BFD_RELOC_MIPS_TLS_TPREL_LO16 3497 MIPS ELF relocations. 3498 3499 -- : BFD_RELOC_MIPS_COPY 3500 -- : BFD_RELOC_MIPS_JUMP_SLOT 3501 MIPS ELF relocations (VxWorks extensions). 3502 3503 -- : BFD_RELOC_FRV_LABEL16 3504 -- : BFD_RELOC_FRV_LABEL24 3505 -- : BFD_RELOC_FRV_LO16 3506 -- : BFD_RELOC_FRV_HI16 3507 -- : BFD_RELOC_FRV_GPREL12 3508 -- : BFD_RELOC_FRV_GPRELU12 3509 -- : BFD_RELOC_FRV_GPREL32 3510 -- : BFD_RELOC_FRV_GPRELHI 3511 -- : BFD_RELOC_FRV_GPRELLO 3512 -- : BFD_RELOC_FRV_GOT12 3513 -- : BFD_RELOC_FRV_GOTHI 3514 -- : BFD_RELOC_FRV_GOTLO 3515 -- : BFD_RELOC_FRV_FUNCDESC 3516 -- : BFD_RELOC_FRV_FUNCDESC_GOT12 3517 -- : BFD_RELOC_FRV_FUNCDESC_GOTHI 3518 -- : BFD_RELOC_FRV_FUNCDESC_GOTLO 3519 -- : BFD_RELOC_FRV_FUNCDESC_VALUE 3520 -- : BFD_RELOC_FRV_FUNCDESC_GOTOFF12 3521 -- : BFD_RELOC_FRV_FUNCDESC_GOTOFFHI 3522 -- : BFD_RELOC_FRV_FUNCDESC_GOTOFFLO 3523 -- : BFD_RELOC_FRV_GOTOFF12 3524 -- : BFD_RELOC_FRV_GOTOFFHI 3525 -- : BFD_RELOC_FRV_GOTOFFLO 3526 -- : BFD_RELOC_FRV_GETTLSOFF 3527 -- : BFD_RELOC_FRV_TLSDESC_VALUE 3528 -- : BFD_RELOC_FRV_GOTTLSDESC12 3529 -- : BFD_RELOC_FRV_GOTTLSDESCHI 3530 -- : BFD_RELOC_FRV_GOTTLSDESCLO 3531 -- : BFD_RELOC_FRV_TLSMOFF12 3532 -- : BFD_RELOC_FRV_TLSMOFFHI 3533 -- : BFD_RELOC_FRV_TLSMOFFLO 3534 -- : BFD_RELOC_FRV_GOTTLSOFF12 3535 -- : BFD_RELOC_FRV_GOTTLSOFFHI 3536 -- : BFD_RELOC_FRV_GOTTLSOFFLO 3537 -- : BFD_RELOC_FRV_TLSOFF 3538 -- : BFD_RELOC_FRV_TLSDESC_RELAX 3539 -- : BFD_RELOC_FRV_GETTLSOFF_RELAX 3540 -- : BFD_RELOC_FRV_TLSOFF_RELAX 3541 -- : BFD_RELOC_FRV_TLSMOFF 3542 Fujitsu Frv Relocations. 3543 3544 -- : BFD_RELOC_MN10300_GOTOFF24 3545 This is a 24bit GOT-relative reloc for the mn10300. 3546 3547 -- : BFD_RELOC_MN10300_GOT32 3548 This is a 32bit GOT-relative reloc for the mn10300, offset by two 3549 bytes in the instruction. 3550 3551 -- : BFD_RELOC_MN10300_GOT24 3552 This is a 24bit GOT-relative reloc for the mn10300, offset by two 3553 bytes in the instruction. 3554 3555 -- : BFD_RELOC_MN10300_GOT16 3556 This is a 16bit GOT-relative reloc for the mn10300, offset by two 3557 bytes in the instruction. 3558 3559 -- : BFD_RELOC_MN10300_COPY 3560 Copy symbol at runtime. 3561 3562 -- : BFD_RELOC_MN10300_GLOB_DAT 3563 Create GOT entry. 3564 3565 -- : BFD_RELOC_MN10300_JMP_SLOT 3566 Create PLT entry. 3567 3568 -- : BFD_RELOC_MN10300_RELATIVE 3569 Adjust by program base. 3570 3571 -- : BFD_RELOC_386_GOT32 3572 -- : BFD_RELOC_386_PLT32 3573 -- : BFD_RELOC_386_COPY 3574 -- : BFD_RELOC_386_GLOB_DAT 3575 -- : BFD_RELOC_386_JUMP_SLOT 3576 -- : BFD_RELOC_386_RELATIVE 3577 -- : BFD_RELOC_386_GOTOFF 3578 -- : BFD_RELOC_386_GOTPC 3579 -- : BFD_RELOC_386_TLS_TPOFF 3580 -- : BFD_RELOC_386_TLS_IE 3581 -- : BFD_RELOC_386_TLS_GOTIE 3582 -- : BFD_RELOC_386_TLS_LE 3583 -- : BFD_RELOC_386_TLS_GD 3584 -- : BFD_RELOC_386_TLS_LDM 3585 -- : BFD_RELOC_386_TLS_LDO_32 3586 -- : BFD_RELOC_386_TLS_IE_32 3587 -- : BFD_RELOC_386_TLS_LE_32 3588 -- : BFD_RELOC_386_TLS_DTPMOD32 3589 -- : BFD_RELOC_386_TLS_DTPOFF32 3590 -- : BFD_RELOC_386_TLS_TPOFF32 3591 -- : BFD_RELOC_386_TLS_GOTDESC 3592 -- : BFD_RELOC_386_TLS_DESC_CALL 3593 -- : BFD_RELOC_386_TLS_DESC 3594 i386/elf relocations 3595 3596 -- : BFD_RELOC_X86_64_GOT32 3597 -- : BFD_RELOC_X86_64_PLT32 3598 -- : BFD_RELOC_X86_64_COPY 3599 -- : BFD_RELOC_X86_64_GLOB_DAT 3600 -- : BFD_RELOC_X86_64_JUMP_SLOT 3601 -- : BFD_RELOC_X86_64_RELATIVE 3602 -- : BFD_RELOC_X86_64_GOTPCREL 3603 -- : BFD_RELOC_X86_64_32S 3604 -- : BFD_RELOC_X86_64_DTPMOD64 3605 -- : BFD_RELOC_X86_64_DTPOFF64 3606 -- : BFD_RELOC_X86_64_TPOFF64 3607 -- : BFD_RELOC_X86_64_TLSGD 3608 -- : BFD_RELOC_X86_64_TLSLD 3609 -- : BFD_RELOC_X86_64_DTPOFF32 3610 -- : BFD_RELOC_X86_64_GOTTPOFF 3611 -- : BFD_RELOC_X86_64_TPOFF32 3612 -- : BFD_RELOC_X86_64_GOTOFF64 3613 -- : BFD_RELOC_X86_64_GOTPC32 3614 -- : BFD_RELOC_X86_64_GOT64 3615 -- : BFD_RELOC_X86_64_GOTPCREL64 3616 -- : BFD_RELOC_X86_64_GOTPC64 3617 -- : BFD_RELOC_X86_64_GOTPLT64 3618 -- : BFD_RELOC_X86_64_PLTOFF64 3619 -- : BFD_RELOC_X86_64_GOTPC32_TLSDESC 3620 -- : BFD_RELOC_X86_64_TLSDESC_CALL 3621 -- : BFD_RELOC_X86_64_TLSDESC 3622 x86-64/elf relocations 3623 3624 -- : BFD_RELOC_NS32K_IMM_8 3625 -- : BFD_RELOC_NS32K_IMM_16 3626 -- : BFD_RELOC_NS32K_IMM_32 3627 -- : BFD_RELOC_NS32K_IMM_8_PCREL 3628 -- : BFD_RELOC_NS32K_IMM_16_PCREL 3629 -- : BFD_RELOC_NS32K_IMM_32_PCREL 3630 -- : BFD_RELOC_NS32K_DISP_8 3631 -- : BFD_RELOC_NS32K_DISP_16 3632 -- : BFD_RELOC_NS32K_DISP_32 3633 -- : BFD_RELOC_NS32K_DISP_8_PCREL 3634 -- : BFD_RELOC_NS32K_DISP_16_PCREL 3635 -- : BFD_RELOC_NS32K_DISP_32_PCREL 3636 ns32k relocations 3637 3638 -- : BFD_RELOC_PDP11_DISP_8_PCREL 3639 -- : BFD_RELOC_PDP11_DISP_6_PCREL 3640 PDP11 relocations 3641 3642 -- : BFD_RELOC_PJ_CODE_HI16 3643 -- : BFD_RELOC_PJ_CODE_LO16 3644 -- : BFD_RELOC_PJ_CODE_DIR16 3645 -- : BFD_RELOC_PJ_CODE_DIR32 3646 -- : BFD_RELOC_PJ_CODE_REL16 3647 -- : BFD_RELOC_PJ_CODE_REL32 3648 Picojava relocs. Not all of these appear in object files. 3649 3650 -- : BFD_RELOC_PPC_B26 3651 -- : BFD_RELOC_PPC_BA26 3652 -- : BFD_RELOC_PPC_TOC16 3653 -- : BFD_RELOC_PPC_B16 3654 -- : BFD_RELOC_PPC_B16_BRTAKEN 3655 -- : BFD_RELOC_PPC_B16_BRNTAKEN 3656 -- : BFD_RELOC_PPC_BA16 3657 -- : BFD_RELOC_PPC_BA16_BRTAKEN 3658 -- : BFD_RELOC_PPC_BA16_BRNTAKEN 3659 -- : BFD_RELOC_PPC_COPY 3660 -- : BFD_RELOC_PPC_GLOB_DAT 3661 -- : BFD_RELOC_PPC_JMP_SLOT 3662 -- : BFD_RELOC_PPC_RELATIVE 3663 -- : BFD_RELOC_PPC_LOCAL24PC 3664 -- : BFD_RELOC_PPC_EMB_NADDR32 3665 -- : BFD_RELOC_PPC_EMB_NADDR16 3666 -- : BFD_RELOC_PPC_EMB_NADDR16_LO 3667 -- : BFD_RELOC_PPC_EMB_NADDR16_HI 3668 -- : BFD_RELOC_PPC_EMB_NADDR16_HA 3669 -- : BFD_RELOC_PPC_EMB_SDAI16 3670 -- : BFD_RELOC_PPC_EMB_SDA2I16 3671 -- : BFD_RELOC_PPC_EMB_SDA2REL 3672 -- : BFD_RELOC_PPC_EMB_SDA21 3673 -- : BFD_RELOC_PPC_EMB_MRKREF 3674 -- : BFD_RELOC_PPC_EMB_RELSEC16 3675 -- : BFD_RELOC_PPC_EMB_RELST_LO 3676 -- : BFD_RELOC_PPC_EMB_RELST_HI 3677 -- : BFD_RELOC_PPC_EMB_RELST_HA 3678 -- : BFD_RELOC_PPC_EMB_BIT_FLD 3679 -- : BFD_RELOC_PPC_EMB_RELSDA 3680 -- : BFD_RELOC_PPC64_HIGHER 3681 -- : BFD_RELOC_PPC64_HIGHER_S 3682 -- : BFD_RELOC_PPC64_HIGHEST 3683 -- : BFD_RELOC_PPC64_HIGHEST_S 3684 -- : BFD_RELOC_PPC64_TOC16_LO 3685 -- : BFD_RELOC_PPC64_TOC16_HI 3686 -- : BFD_RELOC_PPC64_TOC16_HA 3687 -- : BFD_RELOC_PPC64_TOC 3688 -- : BFD_RELOC_PPC64_PLTGOT16 3689 -- : BFD_RELOC_PPC64_PLTGOT16_LO 3690 -- : BFD_RELOC_PPC64_PLTGOT16_HI 3691 -- : BFD_RELOC_PPC64_PLTGOT16_HA 3692 -- : BFD_RELOC_PPC64_ADDR16_DS 3693 -- : BFD_RELOC_PPC64_ADDR16_LO_DS 3694 -- : BFD_RELOC_PPC64_GOT16_DS 3695 -- : BFD_RELOC_PPC64_GOT16_LO_DS 3696 -- : BFD_RELOC_PPC64_PLT16_LO_DS 3697 -- : BFD_RELOC_PPC64_SECTOFF_DS 3698 -- : BFD_RELOC_PPC64_SECTOFF_LO_DS 3699 -- : BFD_RELOC_PPC64_TOC16_DS 3700 -- : BFD_RELOC_PPC64_TOC16_LO_DS 3701 -- : BFD_RELOC_PPC64_PLTGOT16_DS 3702 -- : BFD_RELOC_PPC64_PLTGOT16_LO_DS 3703 Power(rs6000) and PowerPC relocations. 3704 3705 -- : BFD_RELOC_PPC_TLS 3706 -- : BFD_RELOC_PPC_DTPMOD 3707 -- : BFD_RELOC_PPC_TPREL16 3708 -- : BFD_RELOC_PPC_TPREL16_LO 3709 -- : BFD_RELOC_PPC_TPREL16_HI 3710 -- : BFD_RELOC_PPC_TPREL16_HA 3711 -- : BFD_RELOC_PPC_TPREL 3712 -- : BFD_RELOC_PPC_DTPREL16 3713 -- : BFD_RELOC_PPC_DTPREL16_LO 3714 -- : BFD_RELOC_PPC_DTPREL16_HI 3715 -- : BFD_RELOC_PPC_DTPREL16_HA 3716 -- : BFD_RELOC_PPC_DTPREL 3717 -- : BFD_RELOC_PPC_GOT_TLSGD16 3718 -- : BFD_RELOC_PPC_GOT_TLSGD16_LO 3719 -- : BFD_RELOC_PPC_GOT_TLSGD16_HI 3720 -- : BFD_RELOC_PPC_GOT_TLSGD16_HA 3721 -- : BFD_RELOC_PPC_GOT_TLSLD16 3722 -- : BFD_RELOC_PPC_GOT_TLSLD16_LO 3723 -- : BFD_RELOC_PPC_GOT_TLSLD16_HI 3724 -- : BFD_RELOC_PPC_GOT_TLSLD16_HA 3725 -- : BFD_RELOC_PPC_GOT_TPREL16 3726 -- : BFD_RELOC_PPC_GOT_TPREL16_LO 3727 -- : BFD_RELOC_PPC_GOT_TPREL16_HI 3728 -- : BFD_RELOC_PPC_GOT_TPREL16_HA 3729 -- : BFD_RELOC_PPC_GOT_DTPREL16 3730 -- : BFD_RELOC_PPC_GOT_DTPREL16_LO 3731 -- : BFD_RELOC_PPC_GOT_DTPREL16_HI 3732 -- : BFD_RELOC_PPC_GOT_DTPREL16_HA 3733 -- : BFD_RELOC_PPC64_TPREL16_DS 3734 -- : BFD_RELOC_PPC64_TPREL16_LO_DS 3735 -- : BFD_RELOC_PPC64_TPREL16_HIGHER 3736 -- : BFD_RELOC_PPC64_TPREL16_HIGHERA 3737 -- : BFD_RELOC_PPC64_TPREL16_HIGHEST 3738 -- : BFD_RELOC_PPC64_TPREL16_HIGHESTA 3739 -- : BFD_RELOC_PPC64_DTPREL16_DS 3740 -- : BFD_RELOC_PPC64_DTPREL16_LO_DS 3741 -- : BFD_RELOC_PPC64_DTPREL16_HIGHER 3742 -- : BFD_RELOC_PPC64_DTPREL16_HIGHERA 3743 -- : BFD_RELOC_PPC64_DTPREL16_HIGHEST 3744 -- : BFD_RELOC_PPC64_DTPREL16_HIGHESTA 3745 PowerPC and PowerPC64 thread-local storage relocations. 3746 3747 -- : BFD_RELOC_I370_D12 3748 IBM 370/390 relocations 3749 3750 -- : BFD_RELOC_CTOR 3751 The type of reloc used to build a constructor table - at the moment 3752 probably a 32 bit wide absolute relocation, but the target can 3753 choose. It generally does map to one of the other relocation 3754 types. 3755 3756 -- : BFD_RELOC_ARM_PCREL_BRANCH 3757 ARM 26 bit pc-relative branch. The lowest two bits must be zero 3758 and are not stored in the instruction. 3759 3760 -- : BFD_RELOC_ARM_PCREL_BLX 3761 ARM 26 bit pc-relative branch. The lowest bit must be zero and is 3762 not stored in the instruction. The 2nd lowest bit comes from a 1 3763 bit field in the instruction. 3764 3765 -- : BFD_RELOC_THUMB_PCREL_BLX 3766 Thumb 22 bit pc-relative branch. The lowest bit must be zero and 3767 is not stored in the instruction. The 2nd lowest bit comes from a 3768 1 bit field in the instruction. 3769 3770 -- : BFD_RELOC_ARM_PCREL_CALL 3771 ARM 26-bit pc-relative branch for an unconditional BL or BLX 3772 instruction. 3773 3774 -- : BFD_RELOC_ARM_PCREL_JUMP 3775 ARM 26-bit pc-relative branch for B or conditional BL instruction. 3776 3777 -- : BFD_RELOC_THUMB_PCREL_BRANCH7 3778 -- : BFD_RELOC_THUMB_PCREL_BRANCH9 3779 -- : BFD_RELOC_THUMB_PCREL_BRANCH12 3780 -- : BFD_RELOC_THUMB_PCREL_BRANCH20 3781 -- : BFD_RELOC_THUMB_PCREL_BRANCH23 3782 -- : BFD_RELOC_THUMB_PCREL_BRANCH25 3783 Thumb 7-, 9-, 12-, 20-, 23-, and 25-bit pc-relative branches. The 3784 lowest bit must be zero and is not stored in the instruction. 3785 Note that the corresponding ELF R_ARM_THM_JUMPnn constant has an 3786 "nn" one smaller in all cases. Note further that BRANCH23 3787 corresponds to R_ARM_THM_CALL. 3788 3789 -- : BFD_RELOC_ARM_OFFSET_IMM 3790 12-bit immediate offset, used in ARM-format ldr and str 3791 instructions. 3792 3793 -- : BFD_RELOC_ARM_THUMB_OFFSET 3794 5-bit immediate offset, used in Thumb-format ldr and str 3795 instructions. 3796 3797 -- : BFD_RELOC_ARM_TARGET1 3798 Pc-relative or absolute relocation depending on target. Used for 3799 entries in .init_array sections. 3800 3801 -- : BFD_RELOC_ARM_ROSEGREL32 3802 Read-only segment base relative address. 3803 3804 -- : BFD_RELOC_ARM_SBREL32 3805 Data segment base relative address. 3806 3807 -- : BFD_RELOC_ARM_TARGET2 3808 This reloc is used for references to RTTI data from exception 3809 handling tables. The actual definition depends on the target. It 3810 may be a pc-relative or some form of GOT-indirect relocation. 3811 3812 -- : BFD_RELOC_ARM_PREL31 3813 31-bit PC relative address. 3814 3815 -- : BFD_RELOC_ARM_MOVW 3816 -- : BFD_RELOC_ARM_MOVT 3817 -- : BFD_RELOC_ARM_MOVW_PCREL 3818 -- : BFD_RELOC_ARM_MOVT_PCREL 3819 -- : BFD_RELOC_ARM_THUMB_MOVW 3820 -- : BFD_RELOC_ARM_THUMB_MOVT 3821 -- : BFD_RELOC_ARM_THUMB_MOVW_PCREL 3822 -- : BFD_RELOC_ARM_THUMB_MOVT_PCREL 3823 Low and High halfword relocations for MOVW and MOVT instructions. 3824 3825 -- : BFD_RELOC_ARM_JUMP_SLOT 3826 -- : BFD_RELOC_ARM_GLOB_DAT 3827 -- : BFD_RELOC_ARM_GOT32 3828 -- : BFD_RELOC_ARM_PLT32 3829 -- : BFD_RELOC_ARM_RELATIVE 3830 -- : BFD_RELOC_ARM_GOTOFF 3831 -- : BFD_RELOC_ARM_GOTPC 3832 Relocations for setting up GOTs and PLTs for shared libraries. 3833 3834 -- : BFD_RELOC_ARM_TLS_GD32 3835 -- : BFD_RELOC_ARM_TLS_LDO32 3836 -- : BFD_RELOC_ARM_TLS_LDM32 3837 -- : BFD_RELOC_ARM_TLS_DTPOFF32 3838 -- : BFD_RELOC_ARM_TLS_DTPMOD32 3839 -- : BFD_RELOC_ARM_TLS_TPOFF32 3840 -- : BFD_RELOC_ARM_TLS_IE32 3841 -- : BFD_RELOC_ARM_TLS_LE32 3842 ARM thread-local storage relocations. 3843 3844 -- : BFD_RELOC_ARM_ALU_PC_G0_NC 3845 -- : BFD_RELOC_ARM_ALU_PC_G0 3846 -- : BFD_RELOC_ARM_ALU_PC_G1_NC 3847 -- : BFD_RELOC_ARM_ALU_PC_G1 3848 -- : BFD_RELOC_ARM_ALU_PC_G2 3849 -- : BFD_RELOC_ARM_LDR_PC_G0 3850 -- : BFD_RELOC_ARM_LDR_PC_G1 3851 -- : BFD_RELOC_ARM_LDR_PC_G2 3852 -- : BFD_RELOC_ARM_LDRS_PC_G0 3853 -- : BFD_RELOC_ARM_LDRS_PC_G1 3854 -- : BFD_RELOC_ARM_LDRS_PC_G2 3855 -- : BFD_RELOC_ARM_LDC_PC_G0 3856 -- : BFD_RELOC_ARM_LDC_PC_G1 3857 -- : BFD_RELOC_ARM_LDC_PC_G2 3858 -- : BFD_RELOC_ARM_ALU_SB_G0_NC 3859 -- : BFD_RELOC_ARM_ALU_SB_G0 3860 -- : BFD_RELOC_ARM_ALU_SB_G1_NC 3861 -- : BFD_RELOC_ARM_ALU_SB_G1 3862 -- : BFD_RELOC_ARM_ALU_SB_G2 3863 -- : BFD_RELOC_ARM_LDR_SB_G0 3864 -- : BFD_RELOC_ARM_LDR_SB_G1 3865 -- : BFD_RELOC_ARM_LDR_SB_G2 3866 -- : BFD_RELOC_ARM_LDRS_SB_G0 3867 -- : BFD_RELOC_ARM_LDRS_SB_G1 3868 -- : BFD_RELOC_ARM_LDRS_SB_G2 3869 -- : BFD_RELOC_ARM_LDC_SB_G0 3870 -- : BFD_RELOC_ARM_LDC_SB_G1 3871 -- : BFD_RELOC_ARM_LDC_SB_G2 3872 ARM group relocations. 3873 3874 -- : BFD_RELOC_ARM_IMMEDIATE 3875 -- : BFD_RELOC_ARM_ADRL_IMMEDIATE 3876 -- : BFD_RELOC_ARM_T32_IMMEDIATE 3877 -- : BFD_RELOC_ARM_T32_ADD_IMM 3878 -- : BFD_RELOC_ARM_T32_IMM12 3879 -- : BFD_RELOC_ARM_T32_ADD_PC12 3880 -- : BFD_RELOC_ARM_SHIFT_IMM 3881 -- : BFD_RELOC_ARM_SMC 3882 -- : BFD_RELOC_ARM_SWI 3883 -- : BFD_RELOC_ARM_MULTI 3884 -- : BFD_RELOC_ARM_CP_OFF_IMM 3885 -- : BFD_RELOC_ARM_CP_OFF_IMM_S2 3886 -- : BFD_RELOC_ARM_T32_CP_OFF_IMM 3887 -- : BFD_RELOC_ARM_T32_CP_OFF_IMM_S2 3888 -- : BFD_RELOC_ARM_ADR_IMM 3889 -- : BFD_RELOC_ARM_LDR_IMM 3890 -- : BFD_RELOC_ARM_LITERAL 3891 -- : BFD_RELOC_ARM_IN_POOL 3892 -- : BFD_RELOC_ARM_OFFSET_IMM8 3893 -- : BFD_RELOC_ARM_T32_OFFSET_U8 3894 -- : BFD_RELOC_ARM_T32_OFFSET_IMM 3895 -- : BFD_RELOC_ARM_HWLITERAL 3896 -- : BFD_RELOC_ARM_THUMB_ADD 3897 -- : BFD_RELOC_ARM_THUMB_IMM 3898 -- : BFD_RELOC_ARM_THUMB_SHIFT 3899 These relocs are only used within the ARM assembler. They are not 3900 (at present) written to any object files. 3901 3902 -- : BFD_RELOC_SH_PCDISP8BY2 3903 -- : BFD_RELOC_SH_PCDISP12BY2 3904 -- : BFD_RELOC_SH_IMM3 3905 -- : BFD_RELOC_SH_IMM3U 3906 -- : BFD_RELOC_SH_DISP12 3907 -- : BFD_RELOC_SH_DISP12BY2 3908 -- : BFD_RELOC_SH_DISP12BY4 3909 -- : BFD_RELOC_SH_DISP12BY8 3910 -- : BFD_RELOC_SH_DISP20 3911 -- : BFD_RELOC_SH_DISP20BY8 3912 -- : BFD_RELOC_SH_IMM4 3913 -- : BFD_RELOC_SH_IMM4BY2 3914 -- : BFD_RELOC_SH_IMM4BY4 3915 -- : BFD_RELOC_SH_IMM8 3916 -- : BFD_RELOC_SH_IMM8BY2 3917 -- : BFD_RELOC_SH_IMM8BY4 3918 -- : BFD_RELOC_SH_PCRELIMM8BY2 3919 -- : BFD_RELOC_SH_PCRELIMM8BY4 3920 -- : BFD_RELOC_SH_SWITCH16 3921 -- : BFD_RELOC_SH_SWITCH32 3922 -- : BFD_RELOC_SH_USES 3923 -- : BFD_RELOC_SH_COUNT 3924 -- : BFD_RELOC_SH_ALIGN 3925 -- : BFD_RELOC_SH_CODE 3926 -- : BFD_RELOC_SH_DATA 3927 -- : BFD_RELOC_SH_LABEL 3928 -- : BFD_RELOC_SH_LOOP_START 3929 -- : BFD_RELOC_SH_LOOP_END 3930 -- : BFD_RELOC_SH_COPY 3931 -- : BFD_RELOC_SH_GLOB_DAT 3932 -- : BFD_RELOC_SH_JMP_SLOT 3933 -- : BFD_RELOC_SH_RELATIVE 3934 -- : BFD_RELOC_SH_GOTPC 3935 -- : BFD_RELOC_SH_GOT_LOW16 3936 -- : BFD_RELOC_SH_GOT_MEDLOW16 3937 -- : BFD_RELOC_SH_GOT_MEDHI16 3938 -- : BFD_RELOC_SH_GOT_HI16 3939 -- : BFD_RELOC_SH_GOTPLT_LOW16 3940 -- : BFD_RELOC_SH_GOTPLT_MEDLOW16 3941 -- : BFD_RELOC_SH_GOTPLT_MEDHI16 3942 -- : BFD_RELOC_SH_GOTPLT_HI16 3943 -- : BFD_RELOC_SH_PLT_LOW16 3944 -- : BFD_RELOC_SH_PLT_MEDLOW16 3945 -- : BFD_RELOC_SH_PLT_MEDHI16 3946 -- : BFD_RELOC_SH_PLT_HI16 3947 -- : BFD_RELOC_SH_GOTOFF_LOW16 3948 -- : BFD_RELOC_SH_GOTOFF_MEDLOW16 3949 -- : BFD_RELOC_SH_GOTOFF_MEDHI16 3950 -- : BFD_RELOC_SH_GOTOFF_HI16 3951 -- : BFD_RELOC_SH_GOTPC_LOW16 3952 -- : BFD_RELOC_SH_GOTPC_MEDLOW16 3953 -- : BFD_RELOC_SH_GOTPC_MEDHI16 3954 -- : BFD_RELOC_SH_GOTPC_HI16 3955 -- : BFD_RELOC_SH_COPY64 3956 -- : BFD_RELOC_SH_GLOB_DAT64 3957 -- : BFD_RELOC_SH_JMP_SLOT64 3958 -- : BFD_RELOC_SH_RELATIVE64 3959 -- : BFD_RELOC_SH_GOT10BY4 3960 -- : BFD_RELOC_SH_GOT10BY8 3961 -- : BFD_RELOC_SH_GOTPLT10BY4 3962 -- : BFD_RELOC_SH_GOTPLT10BY8 3963 -- : BFD_RELOC_SH_GOTPLT32 3964 -- : BFD_RELOC_SH_SHMEDIA_CODE 3965 -- : BFD_RELOC_SH_IMMU5 3966 -- : BFD_RELOC_SH_IMMS6 3967 -- : BFD_RELOC_SH_IMMS6BY32 3968 -- : BFD_RELOC_SH_IMMU6 3969 -- : BFD_RELOC_SH_IMMS10 3970 -- : BFD_RELOC_SH_IMMS10BY2 3971 -- : BFD_RELOC_SH_IMMS10BY4 3972 -- : BFD_RELOC_SH_IMMS10BY8 3973 -- : BFD_RELOC_SH_IMMS16 3974 -- : BFD_RELOC_SH_IMMU16 3975 -- : BFD_RELOC_SH_IMM_LOW16 3976 -- : BFD_RELOC_SH_IMM_LOW16_PCREL 3977 -- : BFD_RELOC_SH_IMM_MEDLOW16 3978 -- : BFD_RELOC_SH_IMM_MEDLOW16_PCREL 3979 -- : BFD_RELOC_SH_IMM_MEDHI16 3980 -- : BFD_RELOC_SH_IMM_MEDHI16_PCREL 3981 -- : BFD_RELOC_SH_IMM_HI16 3982 -- : BFD_RELOC_SH_IMM_HI16_PCREL 3983 -- : BFD_RELOC_SH_PT_16 3984 -- : BFD_RELOC_SH_TLS_GD_32 3985 -- : BFD_RELOC_SH_TLS_LD_32 3986 -- : BFD_RELOC_SH_TLS_LDO_32 3987 -- : BFD_RELOC_SH_TLS_IE_32 3988 -- : BFD_RELOC_SH_TLS_LE_32 3989 -- : BFD_RELOC_SH_TLS_DTPMOD32 3990 -- : BFD_RELOC_SH_TLS_DTPOFF32 3991 -- : BFD_RELOC_SH_TLS_TPOFF32 3992 Renesas / SuperH SH relocs. Not all of these appear in object 3993 files. 3994 3995 -- : BFD_RELOC_ARC_B22_PCREL 3996 ARC Cores relocs. ARC 22 bit pc-relative branch. The lowest two 3997 bits must be zero and are not stored in the instruction. The high 3998 20 bits are installed in bits 26 through 7 of the instruction. 3999 4000 -- : BFD_RELOC_ARC_B26 4001 ARC 26 bit absolute branch. The lowest two bits must be zero and 4002 are not stored in the instruction. The high 24 bits are installed 4003 in bits 23 through 0. 4004 4005 -- : BFD_RELOC_BFIN_16_IMM 4006 ADI Blackfin 16 bit immediate absolute reloc. 4007 4008 -- : BFD_RELOC_BFIN_16_HIGH 4009 ADI Blackfin 16 bit immediate absolute reloc higher 16 bits. 4010 4011 -- : BFD_RELOC_BFIN_4_PCREL 4012 ADI Blackfin 'a' part of LSETUP. 4013 4014 -- : BFD_RELOC_BFIN_5_PCREL 4015 ADI Blackfin. 4016 4017 -- : BFD_RELOC_BFIN_16_LOW 4018 ADI Blackfin 16 bit immediate absolute reloc lower 16 bits. 4019 4020 -- : BFD_RELOC_BFIN_10_PCREL 4021 ADI Blackfin. 4022 4023 -- : BFD_RELOC_BFIN_11_PCREL 4024 ADI Blackfin 'b' part of LSETUP. 4025 4026 -- : BFD_RELOC_BFIN_12_PCREL_JUMP 4027 ADI Blackfin. 4028 4029 -- : BFD_RELOC_BFIN_12_PCREL_JUMP_S 4030 ADI Blackfin Short jump, pcrel. 4031 4032 -- : BFD_RELOC_BFIN_24_PCREL_CALL_X 4033 ADI Blackfin Call.x not implemented. 4034 4035 -- : BFD_RELOC_BFIN_24_PCREL_JUMP_L 4036 ADI Blackfin Long Jump pcrel. 4037 4038 -- : BFD_RELOC_BFIN_GOT17M4 4039 -- : BFD_RELOC_BFIN_GOTHI 4040 -- : BFD_RELOC_BFIN_GOTLO 4041 -- : BFD_RELOC_BFIN_FUNCDESC 4042 -- : BFD_RELOC_BFIN_FUNCDESC_GOT17M4 4043 -- : BFD_RELOC_BFIN_FUNCDESC_GOTHI 4044 -- : BFD_RELOC_BFIN_FUNCDESC_GOTLO 4045 -- : BFD_RELOC_BFIN_FUNCDESC_VALUE 4046 -- : BFD_RELOC_BFIN_FUNCDESC_GOTOFF17M4 4047 -- : BFD_RELOC_BFIN_FUNCDESC_GOTOFFHI 4048 -- : BFD_RELOC_BFIN_FUNCDESC_GOTOFFLO 4049 -- : BFD_RELOC_BFIN_GOTOFF17M4 4050 -- : BFD_RELOC_BFIN_GOTOFFHI 4051 -- : BFD_RELOC_BFIN_GOTOFFLO 4052 ADI Blackfin FD-PIC relocations. 4053 4054 -- : BFD_RELOC_BFIN_GOT 4055 ADI Blackfin GOT relocation. 4056 4057 -- : BFD_RELOC_BFIN_PLTPC 4058 ADI Blackfin PLTPC relocation. 4059 4060 -- : BFD_ARELOC_BFIN_PUSH 4061 ADI Blackfin arithmetic relocation. 4062 4063 -- : BFD_ARELOC_BFIN_CONST 4064 ADI Blackfin arithmetic relocation. 4065 4066 -- : BFD_ARELOC_BFIN_ADD 4067 ADI Blackfin arithmetic relocation. 4068 4069 -- : BFD_ARELOC_BFIN_SUB 4070 ADI Blackfin arithmetic relocation. 4071 4072 -- : BFD_ARELOC_BFIN_MULT 4073 ADI Blackfin arithmetic relocation. 4074 4075 -- : BFD_ARELOC_BFIN_DIV 4076 ADI Blackfin arithmetic relocation. 4077 4078 -- : BFD_ARELOC_BFIN_MOD 4079 ADI Blackfin arithmetic relocation. 4080 4081 -- : BFD_ARELOC_BFIN_LSHIFT 4082 ADI Blackfin arithmetic relocation. 4083 4084 -- : BFD_ARELOC_BFIN_RSHIFT 4085 ADI Blackfin arithmetic relocation. 4086 4087 -- : BFD_ARELOC_BFIN_AND 4088 ADI Blackfin arithmetic relocation. 4089 4090 -- : BFD_ARELOC_BFIN_OR 4091 ADI Blackfin arithmetic relocation. 4092 4093 -- : BFD_ARELOC_BFIN_XOR 4094 ADI Blackfin arithmetic relocation. 4095 4096 -- : BFD_ARELOC_BFIN_LAND 4097 ADI Blackfin arithmetic relocation. 4098 4099 -- : BFD_ARELOC_BFIN_LOR 4100 ADI Blackfin arithmetic relocation. 4101 4102 -- : BFD_ARELOC_BFIN_LEN 4103 ADI Blackfin arithmetic relocation. 4104 4105 -- : BFD_ARELOC_BFIN_NEG 4106 ADI Blackfin arithmetic relocation. 4107 4108 -- : BFD_ARELOC_BFIN_COMP 4109 ADI Blackfin arithmetic relocation. 4110 4111 -- : BFD_ARELOC_BFIN_PAGE 4112 ADI Blackfin arithmetic relocation. 4113 4114 -- : BFD_ARELOC_BFIN_HWPAGE 4115 ADI Blackfin arithmetic relocation. 4116 4117 -- : BFD_ARELOC_BFIN_ADDR 4118 ADI Blackfin arithmetic relocation. 4119 4120 -- : BFD_RELOC_D10V_10_PCREL_R 4121 Mitsubishi D10V relocs. This is a 10-bit reloc with the right 2 4122 bits assumed to be 0. 4123 4124 -- : BFD_RELOC_D10V_10_PCREL_L 4125 Mitsubishi D10V relocs. This is a 10-bit reloc with the right 2 4126 bits assumed to be 0. This is the same as the previous reloc 4127 except it is in the left container, i.e., shifted left 15 bits. 4128 4129 -- : BFD_RELOC_D10V_18 4130 This is an 18-bit reloc with the right 2 bits assumed to be 0. 4131 4132 -- : BFD_RELOC_D10V_18_PCREL 4133 This is an 18-bit reloc with the right 2 bits assumed to be 0. 4134 4135 -- : BFD_RELOC_D30V_6 4136 Mitsubishi D30V relocs. This is a 6-bit absolute reloc. 4137 4138 -- : BFD_RELOC_D30V_9_PCREL 4139 This is a 6-bit pc-relative reloc with the right 3 bits assumed to 4140 be 0. 4141 4142 -- : BFD_RELOC_D30V_9_PCREL_R 4143 This is a 6-bit pc-relative reloc with the right 3 bits assumed to 4144 be 0. Same as the previous reloc but on the right side of the 4145 container. 4146 4147 -- : BFD_RELOC_D30V_15 4148 This is a 12-bit absolute reloc with the right 3 bitsassumed to be 4149 0. 4150 4151 -- : BFD_RELOC_D30V_15_PCREL 4152 This is a 12-bit pc-relative reloc with the right 3 bits assumed 4153 to be 0. 4154 4155 -- : BFD_RELOC_D30V_15_PCREL_R 4156 This is a 12-bit pc-relative reloc with the right 3 bits assumed 4157 to be 0. Same as the previous reloc but on the right side of the 4158 container. 4159 4160 -- : BFD_RELOC_D30V_21 4161 This is an 18-bit absolute reloc with the right 3 bits assumed to 4162 be 0. 4163 4164 -- : BFD_RELOC_D30V_21_PCREL 4165 This is an 18-bit pc-relative reloc with the right 3 bits assumed 4166 to be 0. 4167 4168 -- : BFD_RELOC_D30V_21_PCREL_R 4169 This is an 18-bit pc-relative reloc with the right 3 bits assumed 4170 to be 0. Same as the previous reloc but on the right side of the 4171 container. 4172 4173 -- : BFD_RELOC_D30V_32 4174 This is a 32-bit absolute reloc. 4175 4176 -- : BFD_RELOC_D30V_32_PCREL 4177 This is a 32-bit pc-relative reloc. 4178 4179 -- : BFD_RELOC_DLX_HI16_S 4180 DLX relocs 4181 4182 -- : BFD_RELOC_DLX_LO16 4183 DLX relocs 4184 4185 -- : BFD_RELOC_DLX_JMP26 4186 DLX relocs 4187 4188 -- : BFD_RELOC_M32C_HI8 4189 -- : BFD_RELOC_M32C_RL_JUMP 4190 -- : BFD_RELOC_M32C_RL_1ADDR 4191 -- : BFD_RELOC_M32C_RL_2ADDR 4192 Renesas M16C/M32C Relocations. 4193 4194 -- : BFD_RELOC_M32R_24 4195 Renesas M32R (formerly Mitsubishi M32R) relocs. This is a 24 bit 4196 absolute address. 4197 4198 -- : BFD_RELOC_M32R_10_PCREL 4199 This is a 10-bit pc-relative reloc with the right 2 bits assumed 4200 to be 0. 4201 4202 -- : BFD_RELOC_M32R_18_PCREL 4203 This is an 18-bit reloc with the right 2 bits assumed to be 0. 4204 4205 -- : BFD_RELOC_M32R_26_PCREL 4206 This is a 26-bit reloc with the right 2 bits assumed to be 0. 4207 4208 -- : BFD_RELOC_M32R_HI16_ULO 4209 This is a 16-bit reloc containing the high 16 bits of an address 4210 used when the lower 16 bits are treated as unsigned. 4211 4212 -- : BFD_RELOC_M32R_HI16_SLO 4213 This is a 16-bit reloc containing the high 16 bits of an address 4214 used when the lower 16 bits are treated as signed. 4215 4216 -- : BFD_RELOC_M32R_LO16 4217 This is a 16-bit reloc containing the lower 16 bits of an address. 4218 4219 -- : BFD_RELOC_M32R_SDA16 4220 This is a 16-bit reloc containing the small data area offset for 4221 use in add3, load, and store instructions. 4222 4223 -- : BFD_RELOC_M32R_GOT24 4224 -- : BFD_RELOC_M32R_26_PLTREL 4225 -- : BFD_RELOC_M32R_COPY 4226 -- : BFD_RELOC_M32R_GLOB_DAT 4227 -- : BFD_RELOC_M32R_JMP_SLOT 4228 -- : BFD_RELOC_M32R_RELATIVE 4229 -- : BFD_RELOC_M32R_GOTOFF 4230 -- : BFD_RELOC_M32R_GOTOFF_HI_ULO 4231 -- : BFD_RELOC_M32R_GOTOFF_HI_SLO 4232 -- : BFD_RELOC_M32R_GOTOFF_LO 4233 -- : BFD_RELOC_M32R_GOTPC24 4234 -- : BFD_RELOC_M32R_GOT16_HI_ULO 4235 -- : BFD_RELOC_M32R_GOT16_HI_SLO 4236 -- : BFD_RELOC_M32R_GOT16_LO 4237 -- : BFD_RELOC_M32R_GOTPC_HI_ULO 4238 -- : BFD_RELOC_M32R_GOTPC_HI_SLO 4239 -- : BFD_RELOC_M32R_GOTPC_LO 4240 For PIC. 4241 4242 -- : BFD_RELOC_V850_9_PCREL 4243 This is a 9-bit reloc 4244 4245 -- : BFD_RELOC_V850_22_PCREL 4246 This is a 22-bit reloc 4247 4248 -- : BFD_RELOC_V850_SDA_16_16_OFFSET 4249 This is a 16 bit offset from the short data area pointer. 4250 4251 -- : BFD_RELOC_V850_SDA_15_16_OFFSET 4252 This is a 16 bit offset (of which only 15 bits are used) from the 4253 short data area pointer. 4254 4255 -- : BFD_RELOC_V850_ZDA_16_16_OFFSET 4256 This is a 16 bit offset from the zero data area pointer. 4257 4258 -- : BFD_RELOC_V850_ZDA_15_16_OFFSET 4259 This is a 16 bit offset (of which only 15 bits are used) from the 4260 zero data area pointer. 4261 4262 -- : BFD_RELOC_V850_TDA_6_8_OFFSET 4263 This is an 8 bit offset (of which only 6 bits are used) from the 4264 tiny data area pointer. 4265 4266 -- : BFD_RELOC_V850_TDA_7_8_OFFSET 4267 This is an 8bit offset (of which only 7 bits are used) from the 4268 tiny data area pointer. 4269 4270 -- : BFD_RELOC_V850_TDA_7_7_OFFSET 4271 This is a 7 bit offset from the tiny data area pointer. 4272 4273 -- : BFD_RELOC_V850_TDA_16_16_OFFSET 4274 This is a 16 bit offset from the tiny data area pointer. 4275 4276 -- : BFD_RELOC_V850_TDA_4_5_OFFSET 4277 This is a 5 bit offset (of which only 4 bits are used) from the 4278 tiny data area pointer. 4279 4280 -- : BFD_RELOC_V850_TDA_4_4_OFFSET 4281 This is a 4 bit offset from the tiny data area pointer. 4282 4283 -- : BFD_RELOC_V850_SDA_16_16_SPLIT_OFFSET 4284 This is a 16 bit offset from the short data area pointer, with the 4285 bits placed non-contiguously in the instruction. 4286 4287 -- : BFD_RELOC_V850_ZDA_16_16_SPLIT_OFFSET 4288 This is a 16 bit offset from the zero data area pointer, with the 4289 bits placed non-contiguously in the instruction. 4290 4291 -- : BFD_RELOC_V850_CALLT_6_7_OFFSET 4292 This is a 6 bit offset from the call table base pointer. 4293 4294 -- : BFD_RELOC_V850_CALLT_16_16_OFFSET 4295 This is a 16 bit offset from the call table base pointer. 4296 4297 -- : BFD_RELOC_V850_LONGCALL 4298 Used for relaxing indirect function calls. 4299 4300 -- : BFD_RELOC_V850_LONGJUMP 4301 Used for relaxing indirect jumps. 4302 4303 -- : BFD_RELOC_V850_ALIGN 4304 Used to maintain alignment whilst relaxing. 4305 4306 -- : BFD_RELOC_V850_LO16_SPLIT_OFFSET 4307 This is a variation of BFD_RELOC_LO16 that can be used in v850e 4308 ld.bu instructions. 4309 4310 -- : BFD_RELOC_MN10300_32_PCREL 4311 This is a 32bit pcrel reloc for the mn10300, offset by two bytes 4312 in the instruction. 4313 4314 -- : BFD_RELOC_MN10300_16_PCREL 4315 This is a 16bit pcrel reloc for the mn10300, offset by two bytes 4316 in the instruction. 4317 4318 -- : BFD_RELOC_TIC30_LDP 4319 This is a 8bit DP reloc for the tms320c30, where the most 4320 significant 8 bits of a 24 bit word are placed into the least 4321 significant 8 bits of the opcode. 4322 4323 -- : BFD_RELOC_TIC54X_PARTLS7 4324 This is a 7bit reloc for the tms320c54x, where the least 4325 significant 7 bits of a 16 bit word are placed into the least 4326 significant 7 bits of the opcode. 4327 4328 -- : BFD_RELOC_TIC54X_PARTMS9 4329 This is a 9bit DP reloc for the tms320c54x, where the most 4330 significant 9 bits of a 16 bit word are placed into the least 4331 significant 9 bits of the opcode. 4332 4333 -- : BFD_RELOC_TIC54X_23 4334 This is an extended address 23-bit reloc for the tms320c54x. 4335 4336 -- : BFD_RELOC_TIC54X_16_OF_23 4337 This is a 16-bit reloc for the tms320c54x, where the least 4338 significant 16 bits of a 23-bit extended address are placed into 4339 the opcode. 4340 4341 -- : BFD_RELOC_TIC54X_MS7_OF_23 4342 This is a reloc for the tms320c54x, where the most significant 7 4343 bits of a 23-bit extended address are placed into the opcode. 4344 4345 -- : BFD_RELOC_FR30_48 4346 This is a 48 bit reloc for the FR30 that stores 32 bits. 4347 4348 -- : BFD_RELOC_FR30_20 4349 This is a 32 bit reloc for the FR30 that stores 20 bits split up 4350 into two sections. 4351 4352 -- : BFD_RELOC_FR30_6_IN_4 4353 This is a 16 bit reloc for the FR30 that stores a 6 bit word 4354 offset in 4 bits. 4355 4356 -- : BFD_RELOC_FR30_8_IN_8 4357 This is a 16 bit reloc for the FR30 that stores an 8 bit byte 4358 offset into 8 bits. 4359 4360 -- : BFD_RELOC_FR30_9_IN_8 4361 This is a 16 bit reloc for the FR30 that stores a 9 bit short 4362 offset into 8 bits. 4363 4364 -- : BFD_RELOC_FR30_10_IN_8 4365 This is a 16 bit reloc for the FR30 that stores a 10 bit word 4366 offset into 8 bits. 4367 4368 -- : BFD_RELOC_FR30_9_PCREL 4369 This is a 16 bit reloc for the FR30 that stores a 9 bit pc relative 4370 short offset into 8 bits. 4371 4372 -- : BFD_RELOC_FR30_12_PCREL 4373 This is a 16 bit reloc for the FR30 that stores a 12 bit pc 4374 relative short offset into 11 bits. 4375 4376 -- : BFD_RELOC_MCORE_PCREL_IMM8BY4 4377 -- : BFD_RELOC_MCORE_PCREL_IMM11BY2 4378 -- : BFD_RELOC_MCORE_PCREL_IMM4BY2 4379 -- : BFD_RELOC_MCORE_PCREL_32 4380 -- : BFD_RELOC_MCORE_PCREL_JSR_IMM11BY2 4381 -- : BFD_RELOC_MCORE_RVA 4382 Motorola Mcore relocations. 4383 4384 -- : BFD_RELOC_MEP_8 4385 -- : BFD_RELOC_MEP_16 4386 -- : BFD_RELOC_MEP_32 4387 -- : BFD_RELOC_MEP_PCREL8A2 4388 -- : BFD_RELOC_MEP_PCREL12A2 4389 -- : BFD_RELOC_MEP_PCREL17A2 4390 -- : BFD_RELOC_MEP_PCREL24A2 4391 -- : BFD_RELOC_MEP_PCABS24A2 4392 -- : BFD_RELOC_MEP_LOW16 4393 -- : BFD_RELOC_MEP_HI16U 4394 -- : BFD_RELOC_MEP_HI16S 4395 -- : BFD_RELOC_MEP_GPREL 4396 -- : BFD_RELOC_MEP_TPREL 4397 -- : BFD_RELOC_MEP_TPREL7 4398 -- : BFD_RELOC_MEP_TPREL7A2 4399 -- : BFD_RELOC_MEP_TPREL7A4 4400 -- : BFD_RELOC_MEP_UIMM24 4401 -- : BFD_RELOC_MEP_ADDR24A4 4402 -- : BFD_RELOC_MEP_GNU_VTINHERIT 4403 -- : BFD_RELOC_MEP_GNU_VTENTRY 4404 Toshiba Media Processor Relocations. 4405 4406 -- : BFD_RELOC_MMIX_GETA 4407 -- : BFD_RELOC_MMIX_GETA_1 4408 -- : BFD_RELOC_MMIX_GETA_2 4409 -- : BFD_RELOC_MMIX_GETA_3 4410 These are relocations for the GETA instruction. 4411 4412 -- : BFD_RELOC_MMIX_CBRANCH 4413 -- : BFD_RELOC_MMIX_CBRANCH_J 4414 -- : BFD_RELOC_MMIX_CBRANCH_1 4415 -- : BFD_RELOC_MMIX_CBRANCH_2 4416 -- : BFD_RELOC_MMIX_CBRANCH_3 4417 These are relocations for a conditional branch instruction. 4418 4419 -- : BFD_RELOC_MMIX_PUSHJ 4420 -- : BFD_RELOC_MMIX_PUSHJ_1 4421 -- : BFD_RELOC_MMIX_PUSHJ_2 4422 -- : BFD_RELOC_MMIX_PUSHJ_3 4423 -- : BFD_RELOC_MMIX_PUSHJ_STUBBABLE 4424 These are relocations for the PUSHJ instruction. 4425 4426 -- : BFD_RELOC_MMIX_JMP 4427 -- : BFD_RELOC_MMIX_JMP_1 4428 -- : BFD_RELOC_MMIX_JMP_2 4429 -- : BFD_RELOC_MMIX_JMP_3 4430 These are relocations for the JMP instruction. 4431 4432 -- : BFD_RELOC_MMIX_ADDR19 4433 This is a relocation for a relative address as in a GETA 4434 instruction or a branch. 4435 4436 -- : BFD_RELOC_MMIX_ADDR27 4437 This is a relocation for a relative address as in a JMP 4438 instruction. 4439 4440 -- : BFD_RELOC_MMIX_REG_OR_BYTE 4441 This is a relocation for an instruction field that may be a general 4442 register or a value 0..255. 4443 4444 -- : BFD_RELOC_MMIX_REG 4445 This is a relocation for an instruction field that may be a general 4446 register. 4447 4448 -- : BFD_RELOC_MMIX_BASE_PLUS_OFFSET 4449 This is a relocation for two instruction fields holding a register 4450 and an offset, the equivalent of the relocation. 4451 4452 -- : BFD_RELOC_MMIX_LOCAL 4453 This relocation is an assertion that the expression is not 4454 allocated as a global register. It does not modify contents. 4455 4456 -- : BFD_RELOC_AVR_7_PCREL 4457 This is a 16 bit reloc for the AVR that stores 8 bit pc relative 4458 short offset into 7 bits. 4459 4460 -- : BFD_RELOC_AVR_13_PCREL 4461 This is a 16 bit reloc for the AVR that stores 13 bit pc relative 4462 short offset into 12 bits. 4463 4464 -- : BFD_RELOC_AVR_16_PM 4465 This is a 16 bit reloc for the AVR that stores 17 bit value 4466 (usually program memory address) into 16 bits. 4467 4468 -- : BFD_RELOC_AVR_LO8_LDI 4469 This is a 16 bit reloc for the AVR that stores 8 bit value (usually 4470 data memory address) into 8 bit immediate value of LDI insn. 4471 4472 -- : BFD_RELOC_AVR_HI8_LDI 4473 This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 4474 bit of data memory address) into 8 bit immediate value of LDI insn. 4475 4476 -- : BFD_RELOC_AVR_HH8_LDI 4477 This is a 16 bit reloc for the AVR that stores 8 bit value (most 4478 high 8 bit of program memory address) into 8 bit immediate value 4479 of LDI insn. 4480 4481 -- : BFD_RELOC_AVR_MS8_LDI 4482 This is a 16 bit reloc for the AVR that stores 8 bit value (most 4483 high 8 bit of 32 bit value) into 8 bit immediate value of LDI insn. 4484 4485 -- : BFD_RELOC_AVR_LO8_LDI_NEG 4486 This is a 16 bit reloc for the AVR that stores negated 8 bit value 4487 (usually data memory address) into 8 bit immediate value of SUBI 4488 insn. 4489 4490 -- : BFD_RELOC_AVR_HI8_LDI_NEG 4491 This is a 16 bit reloc for the AVR that stores negated 8 bit value 4492 (high 8 bit of data memory address) into 8 bit immediate value of 4493 SUBI insn. 4494 4495 -- : BFD_RELOC_AVR_HH8_LDI_NEG 4496 This is a 16 bit reloc for the AVR that stores negated 8 bit value 4497 (most high 8 bit of program memory address) into 8 bit immediate 4498 value of LDI or SUBI insn. 4499 4500 -- : BFD_RELOC_AVR_MS8_LDI_NEG 4501 This is a 16 bit reloc for the AVR that stores negated 8 bit value 4502 (msb of 32 bit value) into 8 bit immediate value of LDI insn. 4503 4504 -- : BFD_RELOC_AVR_LO8_LDI_PM 4505 This is a 16 bit reloc for the AVR that stores 8 bit value (usually 4506 command address) into 8 bit immediate value of LDI insn. 4507 4508 -- : BFD_RELOC_AVR_LO8_LDI_GS 4509 This is a 16 bit reloc for the AVR that stores 8 bit value 4510 (command address) into 8 bit immediate value of LDI insn. If the 4511 address is beyond the 128k boundary, the linker inserts a jump 4512 stub for this reloc in the lower 128k. 4513 4514 -- : BFD_RELOC_AVR_HI8_LDI_PM 4515 This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 4516 bit of command address) into 8 bit immediate value of LDI insn. 4517 4518 -- : BFD_RELOC_AVR_HI8_LDI_GS 4519 This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 4520 bit of command address) into 8 bit immediate value of LDI insn. 4521 If the address is beyond the 128k boundary, the linker inserts a 4522 jump stub for this reloc below 128k. 4523 4524 -- : BFD_RELOC_AVR_HH8_LDI_PM 4525 This is a 16 bit reloc for the AVR that stores 8 bit value (most 4526 high 8 bit of command address) into 8 bit immediate value of LDI 4527 insn. 4528 4529 -- : BFD_RELOC_AVR_LO8_LDI_PM_NEG 4530 This is a 16 bit reloc for the AVR that stores negated 8 bit value 4531 (usually command address) into 8 bit immediate value of SUBI insn. 4532 4533 -- : BFD_RELOC_AVR_HI8_LDI_PM_NEG 4534 This is a 16 bit reloc for the AVR that stores negated 8 bit value 4535 (high 8 bit of 16 bit command address) into 8 bit immediate value 4536 of SUBI insn. 4537 4538 -- : BFD_RELOC_AVR_HH8_LDI_PM_NEG 4539 This is a 16 bit reloc for the AVR that stores negated 8 bit value 4540 (high 6 bit of 22 bit command address) into 8 bit immediate value 4541 of SUBI insn. 4542 4543 -- : BFD_RELOC_AVR_CALL 4544 This is a 32 bit reloc for the AVR that stores 23 bit value into 4545 22 bits. 4546 4547 -- : BFD_RELOC_AVR_LDI 4548 This is a 16 bit reloc for the AVR that stores all needed bits for 4549 absolute addressing with ldi with overflow check to linktime 4550 4551 -- : BFD_RELOC_AVR_6 4552 This is a 6 bit reloc for the AVR that stores offset for ldd/std 4553 instructions 4554 4555 -- : BFD_RELOC_AVR_6_ADIW 4556 This is a 6 bit reloc for the AVR that stores offset for adiw/sbiw 4557 instructions 4558 4559 -- : BFD_RELOC_390_12 4560 Direct 12 bit. 4561 4562 -- : BFD_RELOC_390_GOT12 4563 12 bit GOT offset. 4564 4565 -- : BFD_RELOC_390_PLT32 4566 32 bit PC relative PLT address. 4567 4568 -- : BFD_RELOC_390_COPY 4569 Copy symbol at runtime. 4570 4571 -- : BFD_RELOC_390_GLOB_DAT 4572 Create GOT entry. 4573 4574 -- : BFD_RELOC_390_JMP_SLOT 4575 Create PLT entry. 4576 4577 -- : BFD_RELOC_390_RELATIVE 4578 Adjust by program base. 4579 4580 -- : BFD_RELOC_390_GOTPC 4581 32 bit PC relative offset to GOT. 4582 4583 -- : BFD_RELOC_390_GOT16 4584 16 bit GOT offset. 4585 4586 -- : BFD_RELOC_390_PC16DBL 4587 PC relative 16 bit shifted by 1. 4588 4589 -- : BFD_RELOC_390_PLT16DBL 4590 16 bit PC rel. PLT shifted by 1. 4591 4592 -- : BFD_RELOC_390_PC32DBL 4593 PC relative 32 bit shifted by 1. 4594 4595 -- : BFD_RELOC_390_PLT32DBL 4596 32 bit PC rel. PLT shifted by 1. 4597 4598 -- : BFD_RELOC_390_GOTPCDBL 4599 32 bit PC rel. GOT shifted by 1. 4600 4601 -- : BFD_RELOC_390_GOT64 4602 64 bit GOT offset. 4603 4604 -- : BFD_RELOC_390_PLT64 4605 64 bit PC relative PLT address. 4606 4607 -- : BFD_RELOC_390_GOTENT 4608 32 bit rel. offset to GOT entry. 4609 4610 -- : BFD_RELOC_390_GOTOFF64 4611 64 bit offset to GOT. 4612 4613 -- : BFD_RELOC_390_GOTPLT12 4614 12-bit offset to symbol-entry within GOT, with PLT handling. 4615 4616 -- : BFD_RELOC_390_GOTPLT16 4617 16-bit offset to symbol-entry within GOT, with PLT handling. 4618 4619 -- : BFD_RELOC_390_GOTPLT32 4620 32-bit offset to symbol-entry within GOT, with PLT handling. 4621 4622 -- : BFD_RELOC_390_GOTPLT64 4623 64-bit offset to symbol-entry within GOT, with PLT handling. 4624 4625 -- : BFD_RELOC_390_GOTPLTENT 4626 32-bit rel. offset to symbol-entry within GOT, with PLT handling. 4627 4628 -- : BFD_RELOC_390_PLTOFF16 4629 16-bit rel. offset from the GOT to a PLT entry. 4630 4631 -- : BFD_RELOC_390_PLTOFF32 4632 32-bit rel. offset from the GOT to a PLT entry. 4633 4634 -- : BFD_RELOC_390_PLTOFF64 4635 64-bit rel. offset from the GOT to a PLT entry. 4636 4637 -- : BFD_RELOC_390_TLS_LOAD 4638 -- : BFD_RELOC_390_TLS_GDCALL 4639 -- : BFD_RELOC_390_TLS_LDCALL 4640 -- : BFD_RELOC_390_TLS_GD32 4641 -- : BFD_RELOC_390_TLS_GD64 4642 -- : BFD_RELOC_390_TLS_GOTIE12 4643 -- : BFD_RELOC_390_TLS_GOTIE32 4644 -- : BFD_RELOC_390_TLS_GOTIE64 4645 -- : BFD_RELOC_390_TLS_LDM32 4646 -- : BFD_RELOC_390_TLS_LDM64 4647 -- : BFD_RELOC_390_TLS_IE32 4648 -- : BFD_RELOC_390_TLS_IE64 4649 -- : BFD_RELOC_390_TLS_IEENT 4650 -- : BFD_RELOC_390_TLS_LE32 4651 -- : BFD_RELOC_390_TLS_LE64 4652 -- : BFD_RELOC_390_TLS_LDO32 4653 -- : BFD_RELOC_390_TLS_LDO64 4654 -- : BFD_RELOC_390_TLS_DTPMOD 4655 -- : BFD_RELOC_390_TLS_DTPOFF 4656 -- : BFD_RELOC_390_TLS_TPOFF 4657 s390 tls relocations. 4658 4659 -- : BFD_RELOC_390_20 4660 -- : BFD_RELOC_390_GOT20 4661 -- : BFD_RELOC_390_GOTPLT20 4662 -- : BFD_RELOC_390_TLS_GOTIE20 4663 Long displacement extension. 4664 4665 -- : BFD_RELOC_SCORE_DUMMY1 4666 Score relocations 4667 4668 -- : BFD_RELOC_SCORE_GPREL15 4669 Low 16 bit for load/store 4670 4671 -- : BFD_RELOC_SCORE_DUMMY2 4672 -- : BFD_RELOC_SCORE_JMP 4673 This is a 24-bit reloc with the right 1 bit assumed to be 0 4674 4675 -- : BFD_RELOC_SCORE_BRANCH 4676 This is a 19-bit reloc with the right 1 bit assumed to be 0 4677 4678 -- : BFD_RELOC_SCORE16_JMP 4679 This is a 11-bit reloc with the right 1 bit assumed to be 0 4680 4681 -- : BFD_RELOC_SCORE16_BRANCH 4682 This is a 8-bit reloc with the right 1 bit assumed to be 0 4683 4684 -- : BFD_RELOC_SCORE_GOT15 4685 -- : BFD_RELOC_SCORE_GOT_LO16 4686 -- : BFD_RELOC_SCORE_CALL15 4687 -- : BFD_RELOC_SCORE_DUMMY_HI16 4688 Undocumented Score relocs 4689 4690 -- : BFD_RELOC_IP2K_FR9 4691 Scenix IP2K - 9-bit register number / data address 4692 4693 -- : BFD_RELOC_IP2K_BANK 4694 Scenix IP2K - 4-bit register/data bank number 4695 4696 -- : BFD_RELOC_IP2K_ADDR16CJP 4697 Scenix IP2K - low 13 bits of instruction word address 4698 4699 -- : BFD_RELOC_IP2K_PAGE3 4700 Scenix IP2K - high 3 bits of instruction word address 4701 4702 -- : BFD_RELOC_IP2K_LO8DATA 4703 -- : BFD_RELOC_IP2K_HI8DATA 4704 -- : BFD_RELOC_IP2K_EX8DATA 4705 Scenix IP2K - ext/low/high 8 bits of data address 4706 4707 -- : BFD_RELOC_IP2K_LO8INSN 4708 -- : BFD_RELOC_IP2K_HI8INSN 4709 Scenix IP2K - low/high 8 bits of instruction word address 4710 4711 -- : BFD_RELOC_IP2K_PC_SKIP 4712 Scenix IP2K - even/odd PC modifier to modify snb pcl.0 4713 4714 -- : BFD_RELOC_IP2K_TEXT 4715 Scenix IP2K - 16 bit word address in text section. 4716 4717 -- : BFD_RELOC_IP2K_FR_OFFSET 4718 Scenix IP2K - 7-bit sp or dp offset 4719 4720 -- : BFD_RELOC_VPE4KMATH_DATA 4721 -- : BFD_RELOC_VPE4KMATH_INSN 4722 Scenix VPE4K coprocessor - data/insn-space addressing 4723 4724 -- : BFD_RELOC_VTABLE_INHERIT 4725 -- : BFD_RELOC_VTABLE_ENTRY 4726 These two relocations are used by the linker to determine which of 4727 the entries in a C++ virtual function table are actually used. 4728 When the -gc-sections option is given, the linker will zero out 4729 the entries that are not used, so that the code for those 4730 functions need not be included in the output. 4731 4732 VTABLE_INHERIT is a zero-space relocation used to describe to the 4733 linker the inheritance tree of a C++ virtual function table. The 4734 relocation's symbol should be the parent class' vtable, and the 4735 relocation should be located at the child vtable. 4736 4737 VTABLE_ENTRY is a zero-space relocation that describes the use of a 4738 virtual function table entry. The reloc's symbol should refer to 4739 the table of the class mentioned in the code. Off of that base, 4740 an offset describes the entry that is being used. For Rela hosts, 4741 this offset is stored in the reloc's addend. For Rel hosts, we 4742 are forced to put this offset in the reloc's section offset. 4743 4744 -- : BFD_RELOC_IA64_IMM14 4745 -- : BFD_RELOC_IA64_IMM22 4746 -- : BFD_RELOC_IA64_IMM64 4747 -- : BFD_RELOC_IA64_DIR32MSB 4748 -- : BFD_RELOC_IA64_DIR32LSB 4749 -- : BFD_RELOC_IA64_DIR64MSB 4750 -- : BFD_RELOC_IA64_DIR64LSB 4751 -- : BFD_RELOC_IA64_GPREL22 4752 -- : BFD_RELOC_IA64_GPREL64I 4753 -- : BFD_RELOC_IA64_GPREL32MSB 4754 -- : BFD_RELOC_IA64_GPREL32LSB 4755 -- : BFD_RELOC_IA64_GPREL64MSB 4756 -- : BFD_RELOC_IA64_GPREL64LSB 4757 -- : BFD_RELOC_IA64_LTOFF22 4758 -- : BFD_RELOC_IA64_LTOFF64I 4759 -- : BFD_RELOC_IA64_PLTOFF22 4760 -- : BFD_RELOC_IA64_PLTOFF64I 4761 -- : BFD_RELOC_IA64_PLTOFF64MSB 4762 -- : BFD_RELOC_IA64_PLTOFF64LSB 4763 -- : BFD_RELOC_IA64_FPTR64I 4764 -- : BFD_RELOC_IA64_FPTR32MSB 4765 -- : BFD_RELOC_IA64_FPTR32LSB 4766 -- : BFD_RELOC_IA64_FPTR64MSB 4767 -- : BFD_RELOC_IA64_FPTR64LSB 4768 -- : BFD_RELOC_IA64_PCREL21B 4769 -- : BFD_RELOC_IA64_PCREL21BI 4770 -- : BFD_RELOC_IA64_PCREL21M 4771 -- : BFD_RELOC_IA64_PCREL21F 4772 -- : BFD_RELOC_IA64_PCREL22 4773 -- : BFD_RELOC_IA64_PCREL60B 4774 -- : BFD_RELOC_IA64_PCREL64I 4775 -- : BFD_RELOC_IA64_PCREL32MSB 4776 -- : BFD_RELOC_IA64_PCREL32LSB 4777 -- : BFD_RELOC_IA64_PCREL64MSB 4778 -- : BFD_RELOC_IA64_PCREL64LSB 4779 -- : BFD_RELOC_IA64_LTOFF_FPTR22 4780 -- : BFD_RELOC_IA64_LTOFF_FPTR64I 4781 -- : BFD_RELOC_IA64_LTOFF_FPTR32MSB 4782 -- : BFD_RELOC_IA64_LTOFF_FPTR32LSB 4783 -- : BFD_RELOC_IA64_LTOFF_FPTR64MSB 4784 -- : BFD_RELOC_IA64_LTOFF_FPTR64LSB 4785 -- : BFD_RELOC_IA64_SEGREL32MSB 4786 -- : BFD_RELOC_IA64_SEGREL32LSB 4787 -- : BFD_RELOC_IA64_SEGREL64MSB 4788 -- : BFD_RELOC_IA64_SEGREL64LSB 4789 -- : BFD_RELOC_IA64_SECREL32MSB 4790 -- : BFD_RELOC_IA64_SECREL32LSB 4791 -- : BFD_RELOC_IA64_SECREL64MSB 4792 -- : BFD_RELOC_IA64_SECREL64LSB 4793 -- : BFD_RELOC_IA64_REL32MSB 4794 -- : BFD_RELOC_IA64_REL32LSB 4795 -- : BFD_RELOC_IA64_REL64MSB 4796 -- : BFD_RELOC_IA64_REL64LSB 4797 -- : BFD_RELOC_IA64_LTV32MSB 4798 -- : BFD_RELOC_IA64_LTV32LSB 4799 -- : BFD_RELOC_IA64_LTV64MSB 4800 -- : BFD_RELOC_IA64_LTV64LSB 4801 -- : BFD_RELOC_IA64_IPLTMSB 4802 -- : BFD_RELOC_IA64_IPLTLSB 4803 -- : BFD_RELOC_IA64_COPY 4804 -- : BFD_RELOC_IA64_LTOFF22X 4805 -- : BFD_RELOC_IA64_LDXMOV 4806 -- : BFD_RELOC_IA64_TPREL14 4807 -- : BFD_RELOC_IA64_TPREL22 4808 -- : BFD_RELOC_IA64_TPREL64I 4809 -- : BFD_RELOC_IA64_TPREL64MSB 4810 -- : BFD_RELOC_IA64_TPREL64LSB 4811 -- : BFD_RELOC_IA64_LTOFF_TPREL22 4812 -- : BFD_RELOC_IA64_DTPMOD64MSB 4813 -- : BFD_RELOC_IA64_DTPMOD64LSB 4814 -- : BFD_RELOC_IA64_LTOFF_DTPMOD22 4815 -- : BFD_RELOC_IA64_DTPREL14 4816 -- : BFD_RELOC_IA64_DTPREL22 4817 -- : BFD_RELOC_IA64_DTPREL64I 4818 -- : BFD_RELOC_IA64_DTPREL32MSB 4819 -- : BFD_RELOC_IA64_DTPREL32LSB 4820 -- : BFD_RELOC_IA64_DTPREL64MSB 4821 -- : BFD_RELOC_IA64_DTPREL64LSB 4822 -- : BFD_RELOC_IA64_LTOFF_DTPREL22 4823 Intel IA64 Relocations. 4824 4825 -- : BFD_RELOC_M68HC11_HI8 4826 Motorola 68HC11 reloc. This is the 8 bit high part of an absolute 4827 address. 4828 4829 -- : BFD_RELOC_M68HC11_LO8 4830 Motorola 68HC11 reloc. This is the 8 bit low part of an absolute 4831 address. 4832 4833 -- : BFD_RELOC_M68HC11_3B 4834 Motorola 68HC11 reloc. This is the 3 bit of a value. 4835 4836 -- : BFD_RELOC_M68HC11_RL_JUMP 4837 Motorola 68HC11 reloc. This reloc marks the beginning of a 4838 jump/call instruction. It is used for linker relaxation to 4839 correctly identify beginning of instruction and change some 4840 branches to use PC-relative addressing mode. 4841 4842 -- : BFD_RELOC_M68HC11_RL_GROUP 4843 Motorola 68HC11 reloc. This reloc marks a group of several 4844 instructions that gcc generates and for which the linker 4845 relaxation pass can modify and/or remove some of them. 4846 4847 -- : BFD_RELOC_M68HC11_LO16 4848 Motorola 68HC11 reloc. This is the 16-bit lower part of an 4849 address. It is used for 'call' instruction to specify the symbol 4850 address without any special transformation (due to memory bank 4851 window). 4852 4853 -- : BFD_RELOC_M68HC11_PAGE 4854 Motorola 68HC11 reloc. This is a 8-bit reloc that specifies the 4855 page number of an address. It is used by 'call' instruction to 4856 specify the page number of the symbol. 4857 4858 -- : BFD_RELOC_M68HC11_24 4859 Motorola 68HC11 reloc. This is a 24-bit reloc that represents the 4860 address with a 16-bit value and a 8-bit page number. The symbol 4861 address is transformed to follow the 16K memory bank of 68HC12 4862 (seen as mapped in the window). 4863 4864 -- : BFD_RELOC_M68HC12_5B 4865 Motorola 68HC12 reloc. This is the 5 bits of a value. 4866 4867 -- : BFD_RELOC_16C_NUM08 4868 -- : BFD_RELOC_16C_NUM08_C 4869 -- : BFD_RELOC_16C_NUM16 4870 -- : BFD_RELOC_16C_NUM16_C 4871 -- : BFD_RELOC_16C_NUM32 4872 -- : BFD_RELOC_16C_NUM32_C 4873 -- : BFD_RELOC_16C_DISP04 4874 -- : BFD_RELOC_16C_DISP04_C 4875 -- : BFD_RELOC_16C_DISP08 4876 -- : BFD_RELOC_16C_DISP08_C 4877 -- : BFD_RELOC_16C_DISP16 4878 -- : BFD_RELOC_16C_DISP16_C 4879 -- : BFD_RELOC_16C_DISP24 4880 -- : BFD_RELOC_16C_DISP24_C 4881 -- : BFD_RELOC_16C_DISP24a 4882 -- : BFD_RELOC_16C_DISP24a_C 4883 -- : BFD_RELOC_16C_REG04 4884 -- : BFD_RELOC_16C_REG04_C 4885 -- : BFD_RELOC_16C_REG04a 4886 -- : BFD_RELOC_16C_REG04a_C 4887 -- : BFD_RELOC_16C_REG14 4888 -- : BFD_RELOC_16C_REG14_C 4889 -- : BFD_RELOC_16C_REG16 4890 -- : BFD_RELOC_16C_REG16_C 4891 -- : BFD_RELOC_16C_REG20 4892 -- : BFD_RELOC_16C_REG20_C 4893 -- : BFD_RELOC_16C_ABS20 4894 -- : BFD_RELOC_16C_ABS20_C 4895 -- : BFD_RELOC_16C_ABS24 4896 -- : BFD_RELOC_16C_ABS24_C 4897 -- : BFD_RELOC_16C_IMM04 4898 -- : BFD_RELOC_16C_IMM04_C 4899 -- : BFD_RELOC_16C_IMM16 4900 -- : BFD_RELOC_16C_IMM16_C 4901 -- : BFD_RELOC_16C_IMM20 4902 -- : BFD_RELOC_16C_IMM20_C 4903 -- : BFD_RELOC_16C_IMM24 4904 -- : BFD_RELOC_16C_IMM24_C 4905 -- : BFD_RELOC_16C_IMM32 4906 -- : BFD_RELOC_16C_IMM32_C 4907 NS CR16C Relocations. 4908 4909 -- : BFD_RELOC_CR16_NUM8 4910 -- : BFD_RELOC_CR16_NUM16 4911 -- : BFD_RELOC_CR16_NUM32 4912 -- : BFD_RELOC_CR16_NUM32a 4913 -- : BFD_RELOC_CR16_REGREL0 4914 -- : BFD_RELOC_CR16_REGREL4 4915 -- : BFD_RELOC_CR16_REGREL4a 4916 -- : BFD_RELOC_CR16_REGREL14 4917 -- : BFD_RELOC_CR16_REGREL14a 4918 -- : BFD_RELOC_CR16_REGREL16 4919 -- : BFD_RELOC_CR16_REGREL20 4920 -- : BFD_RELOC_CR16_REGREL20a 4921 -- : BFD_RELOC_CR16_ABS20 4922 -- : BFD_RELOC_CR16_ABS24 4923 -- : BFD_RELOC_CR16_IMM4 4924 -- : BFD_RELOC_CR16_IMM8 4925 -- : BFD_RELOC_CR16_IMM16 4926 -- : BFD_RELOC_CR16_IMM20 4927 -- : BFD_RELOC_CR16_IMM24 4928 -- : BFD_RELOC_CR16_IMM32 4929 -- : BFD_RELOC_CR16_IMM32a 4930 -- : BFD_RELOC_CR16_DISP4 4931 -- : BFD_RELOC_CR16_DISP8 4932 -- : BFD_RELOC_CR16_DISP16 4933 -- : BFD_RELOC_CR16_DISP20 4934 -- : BFD_RELOC_CR16_DISP24 4935 -- : BFD_RELOC_CR16_DISP24a 4936 NS CR16 Relocations. 4937 4938 -- : BFD_RELOC_CRX_REL4 4939 -- : BFD_RELOC_CRX_REL8 4940 -- : BFD_RELOC_CRX_REL8_CMP 4941 -- : BFD_RELOC_CRX_REL16 4942 -- : BFD_RELOC_CRX_REL24 4943 -- : BFD_RELOC_CRX_REL32 4944 -- : BFD_RELOC_CRX_REGREL12 4945 -- : BFD_RELOC_CRX_REGREL22 4946 -- : BFD_RELOC_CRX_REGREL28 4947 -- : BFD_RELOC_CRX_REGREL32 4948 -- : BFD_RELOC_CRX_ABS16 4949 -- : BFD_RELOC_CRX_ABS32 4950 -- : BFD_RELOC_CRX_NUM8 4951 -- : BFD_RELOC_CRX_NUM16 4952 -- : BFD_RELOC_CRX_NUM32 4953 -- : BFD_RELOC_CRX_IMM16 4954 -- : BFD_RELOC_CRX_IMM32 4955 -- : BFD_RELOC_CRX_SWITCH8 4956 -- : BFD_RELOC_CRX_SWITCH16 4957 -- : BFD_RELOC_CRX_SWITCH32 4958 NS CRX Relocations. 4959 4960 -- : BFD_RELOC_CRIS_BDISP8 4961 -- : BFD_RELOC_CRIS_UNSIGNED_5 4962 -- : BFD_RELOC_CRIS_SIGNED_6 4963 -- : BFD_RELOC_CRIS_UNSIGNED_6 4964 -- : BFD_RELOC_CRIS_SIGNED_8 4965 -- : BFD_RELOC_CRIS_UNSIGNED_8 4966 -- : BFD_RELOC_CRIS_SIGNED_16 4967 -- : BFD_RELOC_CRIS_UNSIGNED_16 4968 -- : BFD_RELOC_CRIS_LAPCQ_OFFSET 4969 -- : BFD_RELOC_CRIS_UNSIGNED_4 4970 These relocs are only used within the CRIS assembler. They are not 4971 (at present) written to any object files. 4972 4973 -- : BFD_RELOC_CRIS_COPY 4974 -- : BFD_RELOC_CRIS_GLOB_DAT 4975 -- : BFD_RELOC_CRIS_JUMP_SLOT 4976 -- : BFD_RELOC_CRIS_RELATIVE 4977 Relocs used in ELF shared libraries for CRIS. 4978 4979 -- : BFD_RELOC_CRIS_32_GOT 4980 32-bit offset to symbol-entry within GOT. 4981 4982 -- : BFD_RELOC_CRIS_16_GOT 4983 16-bit offset to symbol-entry within GOT. 4984 4985 -- : BFD_RELOC_CRIS_32_GOTPLT 4986 32-bit offset to symbol-entry within GOT, with PLT handling. 4987 4988 -- : BFD_RELOC_CRIS_16_GOTPLT 4989 16-bit offset to symbol-entry within GOT, with PLT handling. 4990 4991 -- : BFD_RELOC_CRIS_32_GOTREL 4992 32-bit offset to symbol, relative to GOT. 4993 4994 -- : BFD_RELOC_CRIS_32_PLT_GOTREL 4995 32-bit offset to symbol with PLT entry, relative to GOT. 4996 4997 -- : BFD_RELOC_CRIS_32_PLT_PCREL 4998 32-bit offset to symbol with PLT entry, relative to this 4999 relocation. 5000 5001 -- : BFD_RELOC_860_COPY 5002 -- : BFD_RELOC_860_GLOB_DAT 5003 -- : BFD_RELOC_860_JUMP_SLOT 5004 -- : BFD_RELOC_860_RELATIVE 5005 -- : BFD_RELOC_860_PC26 5006 -- : BFD_RELOC_860_PLT26 5007 -- : BFD_RELOC_860_PC16 5008 -- : BFD_RELOC_860_LOW0 5009 -- : BFD_RELOC_860_SPLIT0 5010 -- : BFD_RELOC_860_LOW1 5011 -- : BFD_RELOC_860_SPLIT1 5012 -- : BFD_RELOC_860_LOW2 5013 -- : BFD_RELOC_860_SPLIT2 5014 -- : BFD_RELOC_860_LOW3 5015 -- : BFD_RELOC_860_LOGOT0 5016 -- : BFD_RELOC_860_SPGOT0 5017 -- : BFD_RELOC_860_LOGOT1 5018 -- : BFD_RELOC_860_SPGOT1 5019 -- : BFD_RELOC_860_LOGOTOFF0 5020 -- : BFD_RELOC_860_SPGOTOFF0 5021 -- : BFD_RELOC_860_LOGOTOFF1 5022 -- : BFD_RELOC_860_SPGOTOFF1 5023 -- : BFD_RELOC_860_LOGOTOFF2 5024 -- : BFD_RELOC_860_LOGOTOFF3 5025 -- : BFD_RELOC_860_LOPC 5026 -- : BFD_RELOC_860_HIGHADJ 5027 -- : BFD_RELOC_860_HAGOT 5028 -- : BFD_RELOC_860_HAGOTOFF 5029 -- : BFD_RELOC_860_HAPC 5030 -- : BFD_RELOC_860_HIGH 5031 -- : BFD_RELOC_860_HIGOT 5032 -- : BFD_RELOC_860_HIGOTOFF 5033 Intel i860 Relocations. 5034 5035 -- : BFD_RELOC_OPENRISC_ABS_26 5036 -- : BFD_RELOC_OPENRISC_REL_26 5037 OpenRISC Relocations. 5038 5039 -- : BFD_RELOC_H8_DIR16A8 5040 -- : BFD_RELOC_H8_DIR16R8 5041 -- : BFD_RELOC_H8_DIR24A8 5042 -- : BFD_RELOC_H8_DIR24R8 5043 -- : BFD_RELOC_H8_DIR32A16 5044 H8 elf Relocations. 5045 5046 -- : BFD_RELOC_XSTORMY16_REL_12 5047 -- : BFD_RELOC_XSTORMY16_12 5048 -- : BFD_RELOC_XSTORMY16_24 5049 -- : BFD_RELOC_XSTORMY16_FPTR16 5050 Sony Xstormy16 Relocations. 5051 5052 -- : BFD_RELOC_RELC 5053 Self-describing complex relocations. 5054 5055 -- : BFD_RELOC_XC16X_PAG 5056 -- : BFD_RELOC_XC16X_POF 5057 -- : BFD_RELOC_XC16X_SEG 5058 -- : BFD_RELOC_XC16X_SOF 5059 Infineon Relocations. 5060 5061 -- : BFD_RELOC_VAX_GLOB_DAT 5062 -- : BFD_RELOC_VAX_JMP_SLOT 5063 -- : BFD_RELOC_VAX_RELATIVE 5064 Relocations used by VAX ELF. 5065 5066 -- : BFD_RELOC_MT_PC16 5067 Morpho MT - 16 bit immediate relocation. 5068 5069 -- : BFD_RELOC_MT_HI16 5070 Morpho MT - Hi 16 bits of an address. 5071 5072 -- : BFD_RELOC_MT_LO16 5073 Morpho MT - Low 16 bits of an address. 5074 5075 -- : BFD_RELOC_MT_GNU_VTINHERIT 5076 Morpho MT - Used to tell the linker which vtable entries are used. 5077 5078 -- : BFD_RELOC_MT_GNU_VTENTRY 5079 Morpho MT - Used to tell the linker which vtable entries are used. 5080 5081 -- : BFD_RELOC_MT_PCINSN8 5082 Morpho MT - 8 bit immediate relocation. 5083 5084 -- : BFD_RELOC_MSP430_10_PCREL 5085 -- : BFD_RELOC_MSP430_16_PCREL 5086 -- : BFD_RELOC_MSP430_16 5087 -- : BFD_RELOC_MSP430_16_PCREL_BYTE 5088 -- : BFD_RELOC_MSP430_16_BYTE 5089 -- : BFD_RELOC_MSP430_2X_PCREL 5090 -- : BFD_RELOC_MSP430_RL_PCREL 5091 msp430 specific relocation codes 5092 5093 -- : BFD_RELOC_IQ2000_OFFSET_16 5094 -- : BFD_RELOC_IQ2000_OFFSET_21 5095 -- : BFD_RELOC_IQ2000_UHI16 5096 IQ2000 Relocations. 5097 5098 -- : BFD_RELOC_XTENSA_RTLD 5099 Special Xtensa relocation used only by PLT entries in ELF shared 5100 objects to indicate that the runtime linker should set the value 5101 to one of its own internal functions or data structures. 5102 5103 -- : BFD_RELOC_XTENSA_GLOB_DAT 5104 -- : BFD_RELOC_XTENSA_JMP_SLOT 5105 -- : BFD_RELOC_XTENSA_RELATIVE 5106 Xtensa relocations for ELF shared objects. 5107 5108 -- : BFD_RELOC_XTENSA_PLT 5109 Xtensa relocation used in ELF object files for symbols that may 5110 require PLT entries. Otherwise, this is just a generic 32-bit 5111 relocation. 5112 5113 -- : BFD_RELOC_XTENSA_DIFF8 5114 -- : BFD_RELOC_XTENSA_DIFF16 5115 -- : BFD_RELOC_XTENSA_DIFF32 5116 Xtensa relocations to mark the difference of two local symbols. 5117 These are only needed to support linker relaxation and can be 5118 ignored when not relaxing. The field is set to the value of the 5119 difference assuming no relaxation. The relocation encodes the 5120 position of the first symbol so the linker can determine whether 5121 to adjust the field value. 5122 5123 -- : BFD_RELOC_XTENSA_SLOT0_OP 5124 -- : BFD_RELOC_XTENSA_SLOT1_OP 5125 -- : BFD_RELOC_XTENSA_SLOT2_OP 5126 -- : BFD_RELOC_XTENSA_SLOT3_OP 5127 -- : BFD_RELOC_XTENSA_SLOT4_OP 5128 -- : BFD_RELOC_XTENSA_SLOT5_OP 5129 -- : BFD_RELOC_XTENSA_SLOT6_OP 5130 -- : BFD_RELOC_XTENSA_SLOT7_OP 5131 -- : BFD_RELOC_XTENSA_SLOT8_OP 5132 -- : BFD_RELOC_XTENSA_SLOT9_OP 5133 -- : BFD_RELOC_XTENSA_SLOT10_OP 5134 -- : BFD_RELOC_XTENSA_SLOT11_OP 5135 -- : BFD_RELOC_XTENSA_SLOT12_OP 5136 -- : BFD_RELOC_XTENSA_SLOT13_OP 5137 -- : BFD_RELOC_XTENSA_SLOT14_OP 5138 Generic Xtensa relocations for instruction operands. Only the slot 5139 number is encoded in the relocation. The relocation applies to the 5140 last PC-relative immediate operand, or if there are no PC-relative 5141 immediates, to the last immediate operand. 5142 5143 -- : BFD_RELOC_XTENSA_SLOT0_ALT 5144 -- : BFD_RELOC_XTENSA_SLOT1_ALT 5145 -- : BFD_RELOC_XTENSA_SLOT2_ALT 5146 -- : BFD_RELOC_XTENSA_SLOT3_ALT 5147 -- : BFD_RELOC_XTENSA_SLOT4_ALT 5148 -- : BFD_RELOC_XTENSA_SLOT5_ALT 5149 -- : BFD_RELOC_XTENSA_SLOT6_ALT 5150 -- : BFD_RELOC_XTENSA_SLOT7_ALT 5151 -- : BFD_RELOC_XTENSA_SLOT8_ALT 5152 -- : BFD_RELOC_XTENSA_SLOT9_ALT 5153 -- : BFD_RELOC_XTENSA_SLOT10_ALT 5154 -- : BFD_RELOC_XTENSA_SLOT11_ALT 5155 -- : BFD_RELOC_XTENSA_SLOT12_ALT 5156 -- : BFD_RELOC_XTENSA_SLOT13_ALT 5157 -- : BFD_RELOC_XTENSA_SLOT14_ALT 5158 Alternate Xtensa relocations. Only the slot is encoded in the 5159 relocation. The meaning of these relocations is opcode-specific. 5160 5161 -- : BFD_RELOC_XTENSA_OP0 5162 -- : BFD_RELOC_XTENSA_OP1 5163 -- : BFD_RELOC_XTENSA_OP2 5164 Xtensa relocations for backward compatibility. These have all been 5165 replaced by BFD_RELOC_XTENSA_SLOT0_OP. 5166 5167 -- : BFD_RELOC_XTENSA_ASM_EXPAND 5168 Xtensa relocation to mark that the assembler expanded the 5169 instructions from an original target. The expansion size is 5170 encoded in the reloc size. 5171 5172 -- : BFD_RELOC_XTENSA_ASM_SIMPLIFY 5173 Xtensa relocation to mark that the linker should simplify 5174 assembler-expanded instructions. This is commonly used internally 5175 by the linker after analysis of a BFD_RELOC_XTENSA_ASM_EXPAND. 5176 5177 -- : BFD_RELOC_Z80_DISP8 5178 8 bit signed offset in (ix+d) or (iy+d). 5179 5180 -- : BFD_RELOC_Z8K_DISP7 5181 DJNZ offset. 5182 5183 -- : BFD_RELOC_Z8K_CALLR 5184 CALR offset. 5185 5186 -- : BFD_RELOC_Z8K_IMM4L 5187 4 bit value. 5188 5189 5190 typedef enum bfd_reloc_code_real bfd_reloc_code_real_type; 5191 51922.10.2.2 `bfd_reloc_type_lookup' 5193................................ 5194 5195*Synopsis* 5196 reloc_howto_type *bfd_reloc_type_lookup 5197 (bfd *abfd, bfd_reloc_code_real_type code); 5198 reloc_howto_type *bfd_reloc_name_lookup 5199 (bfd *abfd, const char *reloc_name); 5200 *Description* 5201Return a pointer to a howto structure which, when invoked, will perform 5202the relocation CODE on data from the architecture noted. 5203 52042.10.2.3 `bfd_default_reloc_type_lookup' 5205........................................ 5206 5207*Synopsis* 5208 reloc_howto_type *bfd_default_reloc_type_lookup 5209 (bfd *abfd, bfd_reloc_code_real_type code); 5210 *Description* 5211Provides a default relocation lookup routine for any architecture. 5212 52132.10.2.4 `bfd_get_reloc_code_name' 5214.................................. 5215 5216*Synopsis* 5217 const char *bfd_get_reloc_code_name (bfd_reloc_code_real_type code); 5218 *Description* 5219Provides a printable name for the supplied relocation code. Useful 5220mainly for printing error messages. 5221 52222.10.2.5 `bfd_generic_relax_section' 5223.................................... 5224 5225*Synopsis* 5226 bfd_boolean bfd_generic_relax_section 5227 (bfd *abfd, 5228 asection *section, 5229 struct bfd_link_info *, 5230 bfd_boolean *); 5231 *Description* 5232Provides default handling for relaxing for back ends which don't do 5233relaxing. 5234 52352.10.2.6 `bfd_generic_gc_sections' 5236.................................. 5237 5238*Synopsis* 5239 bfd_boolean bfd_generic_gc_sections 5240 (bfd *, struct bfd_link_info *); 5241 *Description* 5242Provides default handling for relaxing for back ends which don't do 5243section gc - i.e., does nothing. 5244 52452.10.2.7 `bfd_generic_merge_sections' 5246..................................... 5247 5248*Synopsis* 5249 bfd_boolean bfd_generic_merge_sections 5250 (bfd *, struct bfd_link_info *); 5251 *Description* 5252Provides default handling for SEC_MERGE section merging for back ends 5253which don't have SEC_MERGE support - i.e., does nothing. 5254 52552.10.2.8 `bfd_generic_get_relocated_section_contents' 5256..................................................... 5257 5258*Synopsis* 5259 bfd_byte *bfd_generic_get_relocated_section_contents 5260 (bfd *abfd, 5261 struct bfd_link_info *link_info, 5262 struct bfd_link_order *link_order, 5263 bfd_byte *data, 5264 bfd_boolean relocatable, 5265 asymbol **symbols); 5266 *Description* 5267Provides default handling of relocation effort for back ends which 5268can't be bothered to do it efficiently. 5269 5270 5271File: bfd.info, Node: Core Files, Next: Targets, Prev: Relocations, Up: BFD front end 5272 52732.11 Core files 5274=============== 5275 52762.11.1 Core file functions 5277-------------------------- 5278 5279*Description* 5280These are functions pertaining to core files. 5281 52822.11.1.1 `bfd_core_file_failing_command' 5283........................................ 5284 5285*Synopsis* 5286 const char *bfd_core_file_failing_command (bfd *abfd); 5287 *Description* 5288Return a read-only string explaining which program was running when it 5289failed and produced the core file ABFD. 5290 52912.11.1.2 `bfd_core_file_failing_signal' 5292....................................... 5293 5294*Synopsis* 5295 int bfd_core_file_failing_signal (bfd *abfd); 5296 *Description* 5297Returns the signal number which caused the core dump which generated 5298the file the BFD ABFD is attached to. 5299 53002.11.1.3 `core_file_matches_executable_p' 5301......................................... 5302 5303*Synopsis* 5304 bfd_boolean core_file_matches_executable_p 5305 (bfd *core_bfd, bfd *exec_bfd); 5306 *Description* 5307Return `TRUE' if the core file attached to CORE_BFD was generated by a 5308run of the executable file attached to EXEC_BFD, `FALSE' otherwise. 5309 53102.11.1.4 `generic_core_file_matches_executable_p' 5311................................................. 5312 5313*Synopsis* 5314 bfd_boolean generic_core_file_matches_executable_p 5315 (bfd *core_bfd, bfd *exec_bfd); 5316 *Description* 5317Return TRUE if the core file attached to CORE_BFD was generated by a 5318run of the executable file attached to EXEC_BFD. The match is based on 5319executable basenames only. 5320 5321 Note: When not able to determine the core file failing command or 5322the executable name, we still return TRUE even though we're not sure 5323that core file and executable match. This is to avoid generating a 5324false warning in situations where we really don't know whether they 5325match or not. 5326 5327 5328File: bfd.info, Node: Targets, Next: Architectures, Prev: Core Files, Up: BFD front end 5329 53302.12 Targets 5331============ 5332 5333*Description* 5334Each port of BFD to a different machine requires the creation of a 5335target back end. All the back end provides to the root part of BFD is a 5336structure containing pointers to functions which perform certain low 5337level operations on files. BFD translates the applications's requests 5338through a pointer into calls to the back end routines. 5339 5340 When a file is opened with `bfd_openr', its format and target are 5341unknown. BFD uses various mechanisms to determine how to interpret the 5342file. The operations performed are: 5343 5344 * Create a BFD by calling the internal routine `_bfd_new_bfd', then 5345 call `bfd_find_target' with the target string supplied to 5346 `bfd_openr' and the new BFD pointer. 5347 5348 * If a null target string was provided to `bfd_find_target', look up 5349 the environment variable `GNUTARGET' and use that as the target 5350 string. 5351 5352 * If the target string is still `NULL', or the target string is 5353 `default', then use the first item in the target vector as the 5354 target type, and set `target_defaulted' in the BFD to cause 5355 `bfd_check_format' to loop through all the targets. *Note 5356 bfd_target::. *Note Formats::. 5357 5358 * Otherwise, inspect the elements in the target vector one by one, 5359 until a match on target name is found. When found, use it. 5360 5361 * Otherwise return the error `bfd_error_invalid_target' to 5362 `bfd_openr'. 5363 5364 * `bfd_openr' attempts to open the file using `bfd_open_file', and 5365 returns the BFD. 5366 Once the BFD has been opened and the target selected, the file 5367format may be determined. This is done by calling `bfd_check_format' on 5368the BFD with a suggested format. If `target_defaulted' has been set, 5369each possible target type is tried to see if it recognizes the 5370specified format. `bfd_check_format' returns `TRUE' when the caller 5371guesses right. 5372 5373* Menu: 5374 5375* bfd_target:: 5376 5377 5378File: bfd.info, Node: bfd_target, Prev: Targets, Up: Targets 5379 53802.12.1 bfd_target 5381----------------- 5382 5383*Description* 5384This structure contains everything that BFD knows about a target. It 5385includes things like its byte order, name, and which routines to call 5386to do various operations. 5387 5388 Every BFD points to a target structure with its `xvec' member. 5389 5390 The macros below are used to dispatch to functions through the 5391`bfd_target' vector. They are used in a number of macros further down 5392in `bfd.h', and are also used when calling various routines by hand 5393inside the BFD implementation. The ARGLIST argument must be 5394parenthesized; it contains all the arguments to the called function. 5395 5396 They make the documentation (more) unpleasant to read, so if someone 5397wants to fix this and not break the above, please do. 5398 #define BFD_SEND(bfd, message, arglist) \ 5399 ((*((bfd)->xvec->message)) arglist) 5400 5401 #ifdef DEBUG_BFD_SEND 5402 #undef BFD_SEND 5403 #define BFD_SEND(bfd, message, arglist) \ 5404 (((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \ 5405 ((*((bfd)->xvec->message)) arglist) : \ 5406 (bfd_assert (__FILE__,__LINE__), NULL)) 5407 #endif 5408 For operations which index on the BFD format: 5409 #define BFD_SEND_FMT(bfd, message, arglist) \ 5410 (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist) 5411 5412 #ifdef DEBUG_BFD_SEND 5413 #undef BFD_SEND_FMT 5414 #define BFD_SEND_FMT(bfd, message, arglist) \ 5415 (((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \ 5416 (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist) : \ 5417 (bfd_assert (__FILE__,__LINE__), NULL)) 5418 #endif 5419 This is the structure which defines the type of BFD this is. The 5420`xvec' member of the struct `bfd' itself points here. Each module that 5421implements access to a different target under BFD, defines one of these. 5422 5423 FIXME, these names should be rationalised with the names of the 5424entry points which call them. Too bad we can't have one macro to define 5425them both! 5426 enum bfd_flavour 5427 { 5428 bfd_target_unknown_flavour, 5429 bfd_target_aout_flavour, 5430 bfd_target_coff_flavour, 5431 bfd_target_ecoff_flavour, 5432 bfd_target_xcoff_flavour, 5433 bfd_target_elf_flavour, 5434 bfd_target_ieee_flavour, 5435 bfd_target_nlm_flavour, 5436 bfd_target_oasys_flavour, 5437 bfd_target_tekhex_flavour, 5438 bfd_target_srec_flavour, 5439 bfd_target_ihex_flavour, 5440 bfd_target_som_flavour, 5441 bfd_target_os9k_flavour, 5442 bfd_target_versados_flavour, 5443 bfd_target_msdos_flavour, 5444 bfd_target_ovax_flavour, 5445 bfd_target_evax_flavour, 5446 bfd_target_mmo_flavour, 5447 bfd_target_mach_o_flavour, 5448 bfd_target_pef_flavour, 5449 bfd_target_pef_xlib_flavour, 5450 bfd_target_sym_flavour 5451 }; 5452 5453 enum bfd_endian { BFD_ENDIAN_BIG, BFD_ENDIAN_LITTLE, BFD_ENDIAN_UNKNOWN }; 5454 5455 /* Forward declaration. */ 5456 typedef struct bfd_link_info _bfd_link_info; 5457 5458 typedef struct bfd_target 5459 { 5460 /* Identifies the kind of target, e.g., SunOS4, Ultrix, etc. */ 5461 char *name; 5462 5463 /* The "flavour" of a back end is a general indication about 5464 the contents of a file. */ 5465 enum bfd_flavour flavour; 5466 5467 /* The order of bytes within the data area of a file. */ 5468 enum bfd_endian byteorder; 5469 5470 /* The order of bytes within the header parts of a file. */ 5471 enum bfd_endian header_byteorder; 5472 5473 /* A mask of all the flags which an executable may have set - 5474 from the set `BFD_NO_FLAGS', `HAS_RELOC', ...`D_PAGED'. */ 5475 flagword object_flags; 5476 5477 /* A mask of all the flags which a section may have set - from 5478 the set `SEC_NO_FLAGS', `SEC_ALLOC', ...`SET_NEVER_LOAD'. */ 5479 flagword section_flags; 5480 5481 /* The character normally found at the front of a symbol. 5482 (if any), perhaps `_'. */ 5483 char symbol_leading_char; 5484 5485 /* The pad character for file names within an archive header. */ 5486 char ar_pad_char; 5487 5488 /* The maximum number of characters in an archive header. */ 5489 unsigned short ar_max_namelen; 5490 5491 /* Entries for byte swapping for data. These are different from the 5492 other entry points, since they don't take a BFD as the first argument. 5493 Certain other handlers could do the same. */ 5494 bfd_uint64_t (*bfd_getx64) (const void *); 5495 bfd_int64_t (*bfd_getx_signed_64) (const void *); 5496 void (*bfd_putx64) (bfd_uint64_t, void *); 5497 bfd_vma (*bfd_getx32) (const void *); 5498 bfd_signed_vma (*bfd_getx_signed_32) (const void *); 5499 void (*bfd_putx32) (bfd_vma, void *); 5500 bfd_vma (*bfd_getx16) (const void *); 5501 bfd_signed_vma (*bfd_getx_signed_16) (const void *); 5502 void (*bfd_putx16) (bfd_vma, void *); 5503 5504 /* Byte swapping for the headers. */ 5505 bfd_uint64_t (*bfd_h_getx64) (const void *); 5506 bfd_int64_t (*bfd_h_getx_signed_64) (const void *); 5507 void (*bfd_h_putx64) (bfd_uint64_t, void *); 5508 bfd_vma (*bfd_h_getx32) (const void *); 5509 bfd_signed_vma (*bfd_h_getx_signed_32) (const void *); 5510 void (*bfd_h_putx32) (bfd_vma, void *); 5511 bfd_vma (*bfd_h_getx16) (const void *); 5512 bfd_signed_vma (*bfd_h_getx_signed_16) (const void *); 5513 void (*bfd_h_putx16) (bfd_vma, void *); 5514 5515 /* Format dependent routines: these are vectors of entry points 5516 within the target vector structure, one for each format to check. */ 5517 5518 /* Check the format of a file being read. Return a `bfd_target *' or zero. */ 5519 const struct bfd_target *(*_bfd_check_format[bfd_type_end]) (bfd *); 5520 5521 /* Set the format of a file being written. */ 5522 bfd_boolean (*_bfd_set_format[bfd_type_end]) (bfd *); 5523 5524 /* Write cached information into a file being written, at `bfd_close'. */ 5525 bfd_boolean (*_bfd_write_contents[bfd_type_end]) (bfd *); 5526 The general target vector. These vectors are initialized using the 5527BFD_JUMP_TABLE macros. 5528 5529 /* Generic entry points. */ 5530 #define BFD_JUMP_TABLE_GENERIC(NAME) \ 5531 NAME##_close_and_cleanup, \ 5532 NAME##_bfd_free_cached_info, \ 5533 NAME##_new_section_hook, \ 5534 NAME##_get_section_contents, \ 5535 NAME##_get_section_contents_in_window 5536 5537 /* Called when the BFD is being closed to do any necessary cleanup. */ 5538 bfd_boolean (*_close_and_cleanup) (bfd *); 5539 /* Ask the BFD to free all cached information. */ 5540 bfd_boolean (*_bfd_free_cached_info) (bfd *); 5541 /* Called when a new section is created. */ 5542 bfd_boolean (*_new_section_hook) (bfd *, sec_ptr); 5543 /* Read the contents of a section. */ 5544 bfd_boolean (*_bfd_get_section_contents) 5545 (bfd *, sec_ptr, void *, file_ptr, bfd_size_type); 5546 bfd_boolean (*_bfd_get_section_contents_in_window) 5547 (bfd *, sec_ptr, bfd_window *, file_ptr, bfd_size_type); 5548 5549 /* Entry points to copy private data. */ 5550 #define BFD_JUMP_TABLE_COPY(NAME) \ 5551 NAME##_bfd_copy_private_bfd_data, \ 5552 NAME##_bfd_merge_private_bfd_data, \ 5553 _bfd_generic_init_private_section_data, \ 5554 NAME##_bfd_copy_private_section_data, \ 5555 NAME##_bfd_copy_private_symbol_data, \ 5556 NAME##_bfd_copy_private_header_data, \ 5557 NAME##_bfd_set_private_flags, \ 5558 NAME##_bfd_print_private_bfd_data 5559 5560 /* Called to copy BFD general private data from one object file 5561 to another. */ 5562 bfd_boolean (*_bfd_copy_private_bfd_data) (bfd *, bfd *); 5563 /* Called to merge BFD general private data from one object file 5564 to a common output file when linking. */ 5565 bfd_boolean (*_bfd_merge_private_bfd_data) (bfd *, bfd *); 5566 /* Called to initialize BFD private section data from one object file 5567 to another. */ 5568 #define bfd_init_private_section_data(ibfd, isec, obfd, osec, link_info) \ 5569 BFD_SEND (obfd, _bfd_init_private_section_data, (ibfd, isec, obfd, osec, link_info)) 5570 bfd_boolean (*_bfd_init_private_section_data) 5571 (bfd *, sec_ptr, bfd *, sec_ptr, struct bfd_link_info *); 5572 /* Called to copy BFD private section data from one object file 5573 to another. */ 5574 bfd_boolean (*_bfd_copy_private_section_data) 5575 (bfd *, sec_ptr, bfd *, sec_ptr); 5576 /* Called to copy BFD private symbol data from one symbol 5577 to another. */ 5578 bfd_boolean (*_bfd_copy_private_symbol_data) 5579 (bfd *, asymbol *, bfd *, asymbol *); 5580 /* Called to copy BFD private header data from one object file 5581 to another. */ 5582 bfd_boolean (*_bfd_copy_private_header_data) 5583 (bfd *, bfd *); 5584 /* Called to set private backend flags. */ 5585 bfd_boolean (*_bfd_set_private_flags) (bfd *, flagword); 5586 5587 /* Called to print private BFD data. */ 5588 bfd_boolean (*_bfd_print_private_bfd_data) (bfd *, void *); 5589 5590 /* Core file entry points. */ 5591 #define BFD_JUMP_TABLE_CORE(NAME) \ 5592 NAME##_core_file_failing_command, \ 5593 NAME##_core_file_failing_signal, \ 5594 NAME##_core_file_matches_executable_p 5595 5596 char * (*_core_file_failing_command) (bfd *); 5597 int (*_core_file_failing_signal) (bfd *); 5598 bfd_boolean (*_core_file_matches_executable_p) (bfd *, bfd *); 5599 5600 /* Archive entry points. */ 5601 #define BFD_JUMP_TABLE_ARCHIVE(NAME) \ 5602 NAME##_slurp_armap, \ 5603 NAME##_slurp_extended_name_table, \ 5604 NAME##_construct_extended_name_table, \ 5605 NAME##_truncate_arname, \ 5606 NAME##_write_armap, \ 5607 NAME##_read_ar_hdr, \ 5608 NAME##_openr_next_archived_file, \ 5609 NAME##_get_elt_at_index, \ 5610 NAME##_generic_stat_arch_elt, \ 5611 NAME##_update_armap_timestamp 5612 5613 bfd_boolean (*_bfd_slurp_armap) (bfd *); 5614 bfd_boolean (*_bfd_slurp_extended_name_table) (bfd *); 5615 bfd_boolean (*_bfd_construct_extended_name_table) 5616 (bfd *, char **, bfd_size_type *, const char **); 5617 void (*_bfd_truncate_arname) (bfd *, const char *, char *); 5618 bfd_boolean (*write_armap) 5619 (bfd *, unsigned int, struct orl *, unsigned int, int); 5620 void * (*_bfd_read_ar_hdr_fn) (bfd *); 5621 bfd * (*openr_next_archived_file) (bfd *, bfd *); 5622 #define bfd_get_elt_at_index(b,i) BFD_SEND (b, _bfd_get_elt_at_index, (b,i)) 5623 bfd * (*_bfd_get_elt_at_index) (bfd *, symindex); 5624 int (*_bfd_stat_arch_elt) (bfd *, struct stat *); 5625 bfd_boolean (*_bfd_update_armap_timestamp) (bfd *); 5626 5627 /* Entry points used for symbols. */ 5628 #define BFD_JUMP_TABLE_SYMBOLS(NAME) \ 5629 NAME##_get_symtab_upper_bound, \ 5630 NAME##_canonicalize_symtab, \ 5631 NAME##_make_empty_symbol, \ 5632 NAME##_print_symbol, \ 5633 NAME##_get_symbol_info, \ 5634 NAME##_bfd_is_local_label_name, \ 5635 NAME##_bfd_is_target_special_symbol, \ 5636 NAME##_get_lineno, \ 5637 NAME##_find_nearest_line, \ 5638 _bfd_generic_find_line, \ 5639 NAME##_find_inliner_info, \ 5640 NAME##_bfd_make_debug_symbol, \ 5641 NAME##_read_minisymbols, \ 5642 NAME##_minisymbol_to_symbol 5643 5644 long (*_bfd_get_symtab_upper_bound) (bfd *); 5645 long (*_bfd_canonicalize_symtab) 5646 (bfd *, struct bfd_symbol **); 5647 struct bfd_symbol * 5648 (*_bfd_make_empty_symbol) (bfd *); 5649 void (*_bfd_print_symbol) 5650 (bfd *, void *, struct bfd_symbol *, bfd_print_symbol_type); 5651 #define bfd_print_symbol(b,p,s,e) BFD_SEND (b, _bfd_print_symbol, (b,p,s,e)) 5652 void (*_bfd_get_symbol_info) 5653 (bfd *, struct bfd_symbol *, symbol_info *); 5654 #define bfd_get_symbol_info(b,p,e) BFD_SEND (b, _bfd_get_symbol_info, (b,p,e)) 5655 bfd_boolean (*_bfd_is_local_label_name) (bfd *, const char *); 5656 bfd_boolean (*_bfd_is_target_special_symbol) (bfd *, asymbol *); 5657 alent * (*_get_lineno) (bfd *, struct bfd_symbol *); 5658 bfd_boolean (*_bfd_find_nearest_line) 5659 (bfd *, struct bfd_section *, struct bfd_symbol **, bfd_vma, 5660 const char **, const char **, unsigned int *); 5661 bfd_boolean (*_bfd_find_line) 5662 (bfd *, struct bfd_symbol **, struct bfd_symbol *, 5663 const char **, unsigned int *); 5664 bfd_boolean (*_bfd_find_inliner_info) 5665 (bfd *, const char **, const char **, unsigned int *); 5666 /* Back-door to allow format-aware applications to create debug symbols 5667 while using BFD for everything else. Currently used by the assembler 5668 when creating COFF files. */ 5669 asymbol * (*_bfd_make_debug_symbol) 5670 (bfd *, void *, unsigned long size); 5671 #define bfd_read_minisymbols(b, d, m, s) \ 5672 BFD_SEND (b, _read_minisymbols, (b, d, m, s)) 5673 long (*_read_minisymbols) 5674 (bfd *, bfd_boolean, void **, unsigned int *); 5675 #define bfd_minisymbol_to_symbol(b, d, m, f) \ 5676 BFD_SEND (b, _minisymbol_to_symbol, (b, d, m, f)) 5677 asymbol * (*_minisymbol_to_symbol) 5678 (bfd *, bfd_boolean, const void *, asymbol *); 5679 5680 /* Routines for relocs. */ 5681 #define BFD_JUMP_TABLE_RELOCS(NAME) \ 5682 NAME##_get_reloc_upper_bound, \ 5683 NAME##_canonicalize_reloc, \ 5684 NAME##_bfd_reloc_type_lookup, \ 5685 NAME##_bfd_reloc_name_lookup 5686 5687 long (*_get_reloc_upper_bound) (bfd *, sec_ptr); 5688 long (*_bfd_canonicalize_reloc) 5689 (bfd *, sec_ptr, arelent **, struct bfd_symbol **); 5690 /* See documentation on reloc types. */ 5691 reloc_howto_type * 5692 (*reloc_type_lookup) (bfd *, bfd_reloc_code_real_type); 5693 reloc_howto_type * 5694 (*reloc_name_lookup) (bfd *, const char *); 5695 5696 5697 /* Routines used when writing an object file. */ 5698 #define BFD_JUMP_TABLE_WRITE(NAME) \ 5699 NAME##_set_arch_mach, \ 5700 NAME##_set_section_contents 5701 5702 bfd_boolean (*_bfd_set_arch_mach) 5703 (bfd *, enum bfd_architecture, unsigned long); 5704 bfd_boolean (*_bfd_set_section_contents) 5705 (bfd *, sec_ptr, const void *, file_ptr, bfd_size_type); 5706 5707 /* Routines used by the linker. */ 5708 #define BFD_JUMP_TABLE_LINK(NAME) \ 5709 NAME##_sizeof_headers, \ 5710 NAME##_bfd_get_relocated_section_contents, \ 5711 NAME##_bfd_relax_section, \ 5712 NAME##_bfd_link_hash_table_create, \ 5713 NAME##_bfd_link_hash_table_free, \ 5714 NAME##_bfd_link_add_symbols, \ 5715 NAME##_bfd_link_just_syms, \ 5716 NAME##_bfd_final_link, \ 5717 NAME##_bfd_link_split_section, \ 5718 NAME##_bfd_gc_sections, \ 5719 NAME##_bfd_merge_sections, \ 5720 NAME##_bfd_is_group_section, \ 5721 NAME##_bfd_discard_group, \ 5722 NAME##_section_already_linked \ 5723 5724 int (*_bfd_sizeof_headers) (bfd *, struct bfd_link_info *); 5725 bfd_byte * (*_bfd_get_relocated_section_contents) 5726 (bfd *, struct bfd_link_info *, struct bfd_link_order *, 5727 bfd_byte *, bfd_boolean, struct bfd_symbol **); 5728 5729 bfd_boolean (*_bfd_relax_section) 5730 (bfd *, struct bfd_section *, struct bfd_link_info *, bfd_boolean *); 5731 5732 /* Create a hash table for the linker. Different backends store 5733 different information in this table. */ 5734 struct bfd_link_hash_table * 5735 (*_bfd_link_hash_table_create) (bfd *); 5736 5737 /* Release the memory associated with the linker hash table. */ 5738 void (*_bfd_link_hash_table_free) (struct bfd_link_hash_table *); 5739 5740 /* Add symbols from this object file into the hash table. */ 5741 bfd_boolean (*_bfd_link_add_symbols) (bfd *, struct bfd_link_info *); 5742 5743 /* Indicate that we are only retrieving symbol values from this section. */ 5744 void (*_bfd_link_just_syms) (asection *, struct bfd_link_info *); 5745 5746 /* Do a link based on the link_order structures attached to each 5747 section of the BFD. */ 5748 bfd_boolean (*_bfd_final_link) (bfd *, struct bfd_link_info *); 5749 5750 /* Should this section be split up into smaller pieces during linking. */ 5751 bfd_boolean (*_bfd_link_split_section) (bfd *, struct bfd_section *); 5752 5753 /* Remove sections that are not referenced from the output. */ 5754 bfd_boolean (*_bfd_gc_sections) (bfd *, struct bfd_link_info *); 5755 5756 /* Attempt to merge SEC_MERGE sections. */ 5757 bfd_boolean (*_bfd_merge_sections) (bfd *, struct bfd_link_info *); 5758 5759 /* Is this section a member of a group? */ 5760 bfd_boolean (*_bfd_is_group_section) (bfd *, const struct bfd_section *); 5761 5762 /* Discard members of a group. */ 5763 bfd_boolean (*_bfd_discard_group) (bfd *, struct bfd_section *); 5764 5765 /* Check if SEC has been already linked during a reloceatable or 5766 final link. */ 5767 void (*_section_already_linked) (bfd *, struct bfd_section *, 5768 struct bfd_link_info *); 5769 5770 /* Routines to handle dynamic symbols and relocs. */ 5771 #define BFD_JUMP_TABLE_DYNAMIC(NAME) \ 5772 NAME##_get_dynamic_symtab_upper_bound, \ 5773 NAME##_canonicalize_dynamic_symtab, \ 5774 NAME##_get_synthetic_symtab, \ 5775 NAME##_get_dynamic_reloc_upper_bound, \ 5776 NAME##_canonicalize_dynamic_reloc 5777 5778 /* Get the amount of memory required to hold the dynamic symbols. */ 5779 long (*_bfd_get_dynamic_symtab_upper_bound) (bfd *); 5780 /* Read in the dynamic symbols. */ 5781 long (*_bfd_canonicalize_dynamic_symtab) 5782 (bfd *, struct bfd_symbol **); 5783 /* Create synthetized symbols. */ 5784 long (*_bfd_get_synthetic_symtab) 5785 (bfd *, long, struct bfd_symbol **, long, struct bfd_symbol **, 5786 struct bfd_symbol **); 5787 /* Get the amount of memory required to hold the dynamic relocs. */ 5788 long (*_bfd_get_dynamic_reloc_upper_bound) (bfd *); 5789 /* Read in the dynamic relocs. */ 5790 long (*_bfd_canonicalize_dynamic_reloc) 5791 (bfd *, arelent **, struct bfd_symbol **); 5792 A pointer to an alternative bfd_target in case the current one is not 5793satisfactory. This can happen when the target cpu supports both big 5794and little endian code, and target chosen by the linker has the wrong 5795endianness. The function open_output() in ld/ldlang.c uses this field 5796to find an alternative output format that is suitable. 5797 /* Opposite endian version of this target. */ 5798 const struct bfd_target * alternative_target; 5799 5800 /* Data for use by back-end routines, which isn't 5801 generic enough to belong in this structure. */ 5802 const void *backend_data; 5803 5804 } bfd_target; 5805 58062.12.1.1 `bfd_set_default_target' 5807................................. 5808 5809*Synopsis* 5810 bfd_boolean bfd_set_default_target (const char *name); 5811 *Description* 5812Set the default target vector to use when recognizing a BFD. This 5813takes the name of the target, which may be a BFD target name or a 5814configuration triplet. 5815 58162.12.1.2 `bfd_find_target' 5817.......................... 5818 5819*Synopsis* 5820 const bfd_target *bfd_find_target (const char *target_name, bfd *abfd); 5821 *Description* 5822Return a pointer to the transfer vector for the object target named 5823TARGET_NAME. If TARGET_NAME is `NULL', choose the one in the 5824environment variable `GNUTARGET'; if that is null or not defined, then 5825choose the first entry in the target list. Passing in the string 5826"default" or setting the environment variable to "default" will cause 5827the first entry in the target list to be returned, and 5828"target_defaulted" will be set in the BFD if ABFD isn't `NULL'. This 5829causes `bfd_check_format' to loop over all the targets to find the one 5830that matches the file being read. 5831 58322.12.1.3 `bfd_target_list' 5833.......................... 5834 5835*Synopsis* 5836 const char ** bfd_target_list (void); 5837 *Description* 5838Return a freshly malloced NULL-terminated vector of the names of all 5839the valid BFD targets. Do not modify the names. 5840 58412.12.1.4 `bfd_seach_for_target' 5842............................... 5843 5844*Synopsis* 5845 const bfd_target *bfd_search_for_target 5846 (int (*search_func) (const bfd_target *, void *), 5847 void *); 5848 *Description* 5849Return a pointer to the first transfer vector in the list of transfer 5850vectors maintained by BFD that produces a non-zero result when passed 5851to the function SEARCH_FUNC. The parameter DATA is passed, unexamined, 5852to the search function. 5853 5854 5855File: bfd.info, Node: Architectures, Next: Opening and Closing, Prev: Targets, Up: BFD front end 5856 58572.13 Architectures 5858================== 5859 5860BFD keeps one atom in a BFD describing the architecture of the data 5861attached to the BFD: a pointer to a `bfd_arch_info_type'. 5862 5863 Pointers to structures can be requested independently of a BFD so 5864that an architecture's information can be interrogated without access 5865to an open BFD. 5866 5867 The architecture information is provided by each architecture 5868package. The set of default architectures is selected by the macro 5869`SELECT_ARCHITECTURES'. This is normally set up in the 5870`config/TARGET.mt' file of your choice. If the name is not defined, 5871then all the architectures supported are included. 5872 5873 When BFD starts up, all the architectures are called with an 5874initialize method. It is up to the architecture back end to insert as 5875many items into the list of architectures as it wants to; generally 5876this would be one for each machine and one for the default case (an 5877item with a machine field of 0). 5878 5879 BFD's idea of an architecture is implemented in `archures.c'. 5880 58812.13.1 bfd_architecture 5882----------------------- 5883 5884*Description* 5885This enum gives the object file's CPU architecture, in a global 5886sense--i.e., what processor family does it belong to? Another field 5887indicates which processor within the family is in use. The machine 5888gives a number which distinguishes different versions of the 5889architecture, containing, for example, 2 and 3 for Intel i960 KA and 5890i960 KB, and 68020 and 68030 for Motorola 68020 and 68030. 5891 enum bfd_architecture 5892 { 5893 bfd_arch_unknown, /* File arch not known. */ 5894 bfd_arch_obscure, /* Arch known, not one of these. */ 5895 bfd_arch_m68k, /* Motorola 68xxx */ 5896 #define bfd_mach_m68000 1 5897 #define bfd_mach_m68008 2 5898 #define bfd_mach_m68010 3 5899 #define bfd_mach_m68020 4 5900 #define bfd_mach_m68030 5 5901 #define bfd_mach_m68040 6 5902 #define bfd_mach_m68060 7 5903 #define bfd_mach_cpu32 8 5904 #define bfd_mach_fido 9 5905 #define bfd_mach_mcf_isa_a_nodiv 10 5906 #define bfd_mach_mcf_isa_a 11 5907 #define bfd_mach_mcf_isa_a_mac 12 5908 #define bfd_mach_mcf_isa_a_emac 13 5909 #define bfd_mach_mcf_isa_aplus 14 5910 #define bfd_mach_mcf_isa_aplus_mac 15 5911 #define bfd_mach_mcf_isa_aplus_emac 16 5912 #define bfd_mach_mcf_isa_b_nousp 17 5913 #define bfd_mach_mcf_isa_b_nousp_mac 18 5914 #define bfd_mach_mcf_isa_b_nousp_emac 19 5915 #define bfd_mach_mcf_isa_b 20 5916 #define bfd_mach_mcf_isa_b_mac 21 5917 #define bfd_mach_mcf_isa_b_emac 22 5918 #define bfd_mach_mcf_isa_b_float 23 5919 #define bfd_mach_mcf_isa_b_float_mac 24 5920 #define bfd_mach_mcf_isa_b_float_emac 25 5921 #define bfd_mach_mcf_isa_c 26 5922 #define bfd_mach_mcf_isa_c_mac 27 5923 #define bfd_mach_mcf_isa_c_emac 28 5924 bfd_arch_vax, /* DEC Vax */ 5925 bfd_arch_i960, /* Intel 960 */ 5926 /* The order of the following is important. 5927 lower number indicates a machine type that 5928 only accepts a subset of the instructions 5929 available to machines with higher numbers. 5930 The exception is the "ca", which is 5931 incompatible with all other machines except 5932 "core". */ 5933 5934 #define bfd_mach_i960_core 1 5935 #define bfd_mach_i960_ka_sa 2 5936 #define bfd_mach_i960_kb_sb 3 5937 #define bfd_mach_i960_mc 4 5938 #define bfd_mach_i960_xa 5 5939 #define bfd_mach_i960_ca 6 5940 #define bfd_mach_i960_jx 7 5941 #define bfd_mach_i960_hx 8 5942 5943 bfd_arch_or32, /* OpenRISC 32 */ 5944 5945 bfd_arch_sparc, /* SPARC */ 5946 #define bfd_mach_sparc 1 5947 /* The difference between v8plus and v9 is that v9 is a true 64 bit env. */ 5948 #define bfd_mach_sparc_sparclet 2 5949 #define bfd_mach_sparc_sparclite 3 5950 #define bfd_mach_sparc_v8plus 4 5951 #define bfd_mach_sparc_v8plusa 5 /* with ultrasparc add'ns. */ 5952 #define bfd_mach_sparc_sparclite_le 6 5953 #define bfd_mach_sparc_v9 7 5954 #define bfd_mach_sparc_v9a 8 /* with ultrasparc add'ns. */ 5955 #define bfd_mach_sparc_v8plusb 9 /* with cheetah add'ns. */ 5956 #define bfd_mach_sparc_v9b 10 /* with cheetah add'ns. */ 5957 /* Nonzero if MACH has the v9 instruction set. */ 5958 #define bfd_mach_sparc_v9_p(mach) \ 5959 ((mach) >= bfd_mach_sparc_v8plus && (mach) <= bfd_mach_sparc_v9b \ 5960 && (mach) != bfd_mach_sparc_sparclite_le) 5961 /* Nonzero if MACH is a 64 bit sparc architecture. */ 5962 #define bfd_mach_sparc_64bit_p(mach) \ 5963 ((mach) >= bfd_mach_sparc_v9 && (mach) != bfd_mach_sparc_v8plusb) 5964 bfd_arch_spu, /* PowerPC SPU */ 5965 #define bfd_mach_spu 256 5966 bfd_arch_mips, /* MIPS Rxxxx */ 5967 #define bfd_mach_mips3000 3000 5968 #define bfd_mach_mips3900 3900 5969 #define bfd_mach_mips4000 4000 5970 #define bfd_mach_mips4010 4010 5971 #define bfd_mach_mips4100 4100 5972 #define bfd_mach_mips4111 4111 5973 #define bfd_mach_mips4120 4120 5974 #define bfd_mach_mips4300 4300 5975 #define bfd_mach_mips4400 4400 5976 #define bfd_mach_mips4600 4600 5977 #define bfd_mach_mips4650 4650 5978 #define bfd_mach_mips5000 5000 5979 #define bfd_mach_mips5400 5400 5980 #define bfd_mach_mips5500 5500 5981 #define bfd_mach_mips6000 6000 5982 #define bfd_mach_mips7000 7000 5983 #define bfd_mach_mips8000 8000 5984 #define bfd_mach_mips9000 9000 5985 #define bfd_mach_mips10000 10000 5986 #define bfd_mach_mips12000 12000 5987 #define bfd_mach_mips16 16 5988 #define bfd_mach_mips5 5 5989 #define bfd_mach_mips_sb1 12310201 /* octal 'SB', 01 */ 5990 #define bfd_mach_mipsisa32 32 5991 #define bfd_mach_mipsisa32r2 33 5992 #define bfd_mach_mipsisa64 64 5993 #define bfd_mach_mipsisa64r2 65 5994 bfd_arch_i386, /* Intel 386 */ 5995 #define bfd_mach_i386_i386 1 5996 #define bfd_mach_i386_i8086 2 5997 #define bfd_mach_i386_i386_intel_syntax 3 5998 #define bfd_mach_x86_64 64 5999 #define bfd_mach_x86_64_intel_syntax 65 6000 bfd_arch_we32k, /* AT&T WE32xxx */ 6001 bfd_arch_tahoe, /* CCI/Harris Tahoe */ 6002 bfd_arch_i860, /* Intel 860 */ 6003 bfd_arch_i370, /* IBM 360/370 Mainframes */ 6004 bfd_arch_romp, /* IBM ROMP PC/RT */ 6005 bfd_arch_convex, /* Convex */ 6006 bfd_arch_m88k, /* Motorola 88xxx */ 6007 bfd_arch_m98k, /* Motorola 98xxx */ 6008 bfd_arch_pyramid, /* Pyramid Technology */ 6009 bfd_arch_h8300, /* Renesas H8/300 (formerly Hitachi H8/300) */ 6010 #define bfd_mach_h8300 1 6011 #define bfd_mach_h8300h 2 6012 #define bfd_mach_h8300s 3 6013 #define bfd_mach_h8300hn 4 6014 #define bfd_mach_h8300sn 5 6015 #define bfd_mach_h8300sx 6 6016 #define bfd_mach_h8300sxn 7 6017 bfd_arch_pdp11, /* DEC PDP-11 */ 6018 bfd_arch_powerpc, /* PowerPC */ 6019 #define bfd_mach_ppc 32 6020 #define bfd_mach_ppc64 64 6021 #define bfd_mach_ppc_403 403 6022 #define bfd_mach_ppc_403gc 4030 6023 #define bfd_mach_ppc_505 505 6024 #define bfd_mach_ppc_601 601 6025 #define bfd_mach_ppc_602 602 6026 #define bfd_mach_ppc_603 603 6027 #define bfd_mach_ppc_ec603e 6031 6028 #define bfd_mach_ppc_604 604 6029 #define bfd_mach_ppc_620 620 6030 #define bfd_mach_ppc_630 630 6031 #define bfd_mach_ppc_750 750 6032 #define bfd_mach_ppc_860 860 6033 #define bfd_mach_ppc_a35 35 6034 #define bfd_mach_ppc_rs64ii 642 6035 #define bfd_mach_ppc_rs64iii 643 6036 #define bfd_mach_ppc_7400 7400 6037 #define bfd_mach_ppc_e500 500 6038 bfd_arch_rs6000, /* IBM RS/6000 */ 6039 #define bfd_mach_rs6k 6000 6040 #define bfd_mach_rs6k_rs1 6001 6041 #define bfd_mach_rs6k_rsc 6003 6042 #define bfd_mach_rs6k_rs2 6002 6043 bfd_arch_hppa, /* HP PA RISC */ 6044 #define bfd_mach_hppa10 10 6045 #define bfd_mach_hppa11 11 6046 #define bfd_mach_hppa20 20 6047 #define bfd_mach_hppa20w 25 6048 bfd_arch_d10v, /* Mitsubishi D10V */ 6049 #define bfd_mach_d10v 1 6050 #define bfd_mach_d10v_ts2 2 6051 #define bfd_mach_d10v_ts3 3 6052 bfd_arch_d30v, /* Mitsubishi D30V */ 6053 bfd_arch_dlx, /* DLX */ 6054 bfd_arch_m68hc11, /* Motorola 68HC11 */ 6055 bfd_arch_m68hc12, /* Motorola 68HC12 */ 6056 #define bfd_mach_m6812_default 0 6057 #define bfd_mach_m6812 1 6058 #define bfd_mach_m6812s 2 6059 bfd_arch_z8k, /* Zilog Z8000 */ 6060 #define bfd_mach_z8001 1 6061 #define bfd_mach_z8002 2 6062 bfd_arch_h8500, /* Renesas H8/500 (formerly Hitachi H8/500) */ 6063 bfd_arch_sh, /* Renesas / SuperH SH (formerly Hitachi SH) */ 6064 #define bfd_mach_sh 1 6065 #define bfd_mach_sh2 0x20 6066 #define bfd_mach_sh_dsp 0x2d 6067 #define bfd_mach_sh2a 0x2a 6068 #define bfd_mach_sh2a_nofpu 0x2b 6069 #define bfd_mach_sh2a_nofpu_or_sh4_nommu_nofpu 0x2a1 6070 #define bfd_mach_sh2a_nofpu_or_sh3_nommu 0x2a2 6071 #define bfd_mach_sh2a_or_sh4 0x2a3 6072 #define bfd_mach_sh2a_or_sh3e 0x2a4 6073 #define bfd_mach_sh2e 0x2e 6074 #define bfd_mach_sh3 0x30 6075 #define bfd_mach_sh3_nommu 0x31 6076 #define bfd_mach_sh3_dsp 0x3d 6077 #define bfd_mach_sh3e 0x3e 6078 #define bfd_mach_sh4 0x40 6079 #define bfd_mach_sh4_nofpu 0x41 6080 #define bfd_mach_sh4_nommu_nofpu 0x42 6081 #define bfd_mach_sh4a 0x4a 6082 #define bfd_mach_sh4a_nofpu 0x4b 6083 #define bfd_mach_sh4al_dsp 0x4d 6084 #define bfd_mach_sh5 0x50 6085 bfd_arch_alpha, /* Dec Alpha */ 6086 #define bfd_mach_alpha_ev4 0x10 6087 #define bfd_mach_alpha_ev5 0x20 6088 #define bfd_mach_alpha_ev6 0x30 6089 bfd_arch_arm, /* Advanced Risc Machines ARM. */ 6090 #define bfd_mach_arm_unknown 0 6091 #define bfd_mach_arm_2 1 6092 #define bfd_mach_arm_2a 2 6093 #define bfd_mach_arm_3 3 6094 #define bfd_mach_arm_3M 4 6095 #define bfd_mach_arm_4 5 6096 #define bfd_mach_arm_4T 6 6097 #define bfd_mach_arm_5 7 6098 #define bfd_mach_arm_5T 8 6099 #define bfd_mach_arm_5TE 9 6100 #define bfd_mach_arm_XScale 10 6101 #define bfd_mach_arm_ep9312 11 6102 #define bfd_mach_arm_iWMMXt 12 6103 #define bfd_mach_arm_iWMMXt2 13 6104 bfd_arch_ns32k, /* National Semiconductors ns32000 */ 6105 bfd_arch_w65, /* WDC 65816 */ 6106 bfd_arch_tic30, /* Texas Instruments TMS320C30 */ 6107 bfd_arch_tic4x, /* Texas Instruments TMS320C3X/4X */ 6108 #define bfd_mach_tic3x 30 6109 #define bfd_mach_tic4x 40 6110 bfd_arch_tic54x, /* Texas Instruments TMS320C54X */ 6111 bfd_arch_tic80, /* TI TMS320c80 (MVP) */ 6112 bfd_arch_v850, /* NEC V850 */ 6113 #define bfd_mach_v850 1 6114 #define bfd_mach_v850e 'E' 6115 #define bfd_mach_v850e1 '1' 6116 bfd_arch_arc, /* ARC Cores */ 6117 #define bfd_mach_arc_5 5 6118 #define bfd_mach_arc_6 6 6119 #define bfd_mach_arc_7 7 6120 #define bfd_mach_arc_8 8 6121 bfd_arch_m32c, /* Renesas M16C/M32C. */ 6122 #define bfd_mach_m16c 0x75 6123 #define bfd_mach_m32c 0x78 6124 bfd_arch_m32r, /* Renesas M32R (formerly Mitsubishi M32R/D) */ 6125 #define bfd_mach_m32r 1 /* For backwards compatibility. */ 6126 #define bfd_mach_m32rx 'x' 6127 #define bfd_mach_m32r2 '2' 6128 bfd_arch_mn10200, /* Matsushita MN10200 */ 6129 bfd_arch_mn10300, /* Matsushita MN10300 */ 6130 #define bfd_mach_mn10300 300 6131 #define bfd_mach_am33 330 6132 #define bfd_mach_am33_2 332 6133 bfd_arch_fr30, 6134 #define bfd_mach_fr30 0x46523330 6135 bfd_arch_frv, 6136 #define bfd_mach_frv 1 6137 #define bfd_mach_frvsimple 2 6138 #define bfd_mach_fr300 300 6139 #define bfd_mach_fr400 400 6140 #define bfd_mach_fr450 450 6141 #define bfd_mach_frvtomcat 499 /* fr500 prototype */ 6142 #define bfd_mach_fr500 500 6143 #define bfd_mach_fr550 550 6144 bfd_arch_mcore, 6145 bfd_arch_mep, 6146 #define bfd_mach_mep 1 6147 #define bfd_mach_mep_h1 0x6831 6148 bfd_arch_ia64, /* HP/Intel ia64 */ 6149 #define bfd_mach_ia64_elf64 64 6150 #define bfd_mach_ia64_elf32 32 6151 bfd_arch_ip2k, /* Ubicom IP2K microcontrollers. */ 6152 #define bfd_mach_ip2022 1 6153 #define bfd_mach_ip2022ext 2 6154 bfd_arch_iq2000, /* Vitesse IQ2000. */ 6155 #define bfd_mach_iq2000 1 6156 #define bfd_mach_iq10 2 6157 bfd_arch_mt, 6158 #define bfd_mach_ms1 1 6159 #define bfd_mach_mrisc2 2 6160 #define bfd_mach_ms2 3 6161 bfd_arch_pj, 6162 bfd_arch_avr, /* Atmel AVR microcontrollers. */ 6163 #define bfd_mach_avr1 1 6164 #define bfd_mach_avr2 2 6165 #define bfd_mach_avr3 3 6166 #define bfd_mach_avr4 4 6167 #define bfd_mach_avr5 5 6168 #define bfd_mach_avr6 6 6169 bfd_arch_bfin, /* ADI Blackfin */ 6170 #define bfd_mach_bfin 1 6171 bfd_arch_cr16, /* National Semiconductor CompactRISC (ie CR16). */ 6172 #define bfd_mach_cr16 1 6173 bfd_arch_cr16c, /* National Semiconductor CompactRISC. */ 6174 #define bfd_mach_cr16c 1 6175 bfd_arch_crx, /* National Semiconductor CRX. */ 6176 #define bfd_mach_crx 1 6177 bfd_arch_cris, /* Axis CRIS */ 6178 #define bfd_mach_cris_v0_v10 255 6179 #define bfd_mach_cris_v32 32 6180 #define bfd_mach_cris_v10_v32 1032 6181 bfd_arch_s390, /* IBM s390 */ 6182 #define bfd_mach_s390_31 31 6183 #define bfd_mach_s390_64 64 6184 bfd_arch_score, /* Sunplus score */ 6185 bfd_arch_openrisc, /* OpenRISC */ 6186 bfd_arch_mmix, /* Donald Knuth's educational processor. */ 6187 bfd_arch_xstormy16, 6188 #define bfd_mach_xstormy16 1 6189 bfd_arch_msp430, /* Texas Instruments MSP430 architecture. */ 6190 #define bfd_mach_msp11 11 6191 #define bfd_mach_msp110 110 6192 #define bfd_mach_msp12 12 6193 #define bfd_mach_msp13 13 6194 #define bfd_mach_msp14 14 6195 #define bfd_mach_msp15 15 6196 #define bfd_mach_msp16 16 6197 #define bfd_mach_msp21 21 6198 #define bfd_mach_msp31 31 6199 #define bfd_mach_msp32 32 6200 #define bfd_mach_msp33 33 6201 #define bfd_mach_msp41 41 6202 #define bfd_mach_msp42 42 6203 #define bfd_mach_msp43 43 6204 #define bfd_mach_msp44 44 6205 bfd_arch_xc16x, /* Infineon's XC16X Series. */ 6206 #define bfd_mach_xc16x 1 6207 #define bfd_mach_xc16xl 2 6208 #define bfd_mach_xc16xs 3 6209 bfd_arch_xtensa, /* Tensilica's Xtensa cores. */ 6210 #define bfd_mach_xtensa 1 6211 bfd_arch_maxq, /* Dallas MAXQ 10/20 */ 6212 #define bfd_mach_maxq10 10 6213 #define bfd_mach_maxq20 20 6214 bfd_arch_z80, 6215 #define bfd_mach_z80strict 1 /* No undocumented opcodes. */ 6216 #define bfd_mach_z80 3 /* With ixl, ixh, iyl, and iyh. */ 6217 #define bfd_mach_z80full 7 /* All undocumented instructions. */ 6218 #define bfd_mach_r800 11 /* R800: successor with multiplication. */ 6219 bfd_arch_last 6220 }; 6221 62222.13.2 bfd_arch_info 6223-------------------- 6224 6225*Description* 6226This structure contains information on architectures for use within BFD. 6227 6228 typedef struct bfd_arch_info 6229 { 6230 int bits_per_word; 6231 int bits_per_address; 6232 int bits_per_byte; 6233 enum bfd_architecture arch; 6234 unsigned long mach; 6235 const char *arch_name; 6236 const char *printable_name; 6237 unsigned int section_align_power; 6238 /* TRUE if this is the default machine for the architecture. 6239 The default arch should be the first entry for an arch so that 6240 all the entries for that arch can be accessed via `next'. */ 6241 bfd_boolean the_default; 6242 const struct bfd_arch_info * (*compatible) 6243 (const struct bfd_arch_info *a, const struct bfd_arch_info *b); 6244 6245 bfd_boolean (*scan) (const struct bfd_arch_info *, const char *); 6246 6247 const struct bfd_arch_info *next; 6248 } 6249 bfd_arch_info_type; 6250 62512.13.2.1 `bfd_printable_name' 6252............................. 6253 6254*Synopsis* 6255 const char *bfd_printable_name (bfd *abfd); 6256 *Description* 6257Return a printable string representing the architecture and machine 6258from the pointer to the architecture info structure. 6259 62602.13.2.2 `bfd_scan_arch' 6261........................ 6262 6263*Synopsis* 6264 const bfd_arch_info_type *bfd_scan_arch (const char *string); 6265 *Description* 6266Figure out if BFD supports any cpu which could be described with the 6267name STRING. Return a pointer to an `arch_info' structure if a machine 6268is found, otherwise NULL. 6269 62702.13.2.3 `bfd_arch_list' 6271........................ 6272 6273*Synopsis* 6274 const char **bfd_arch_list (void); 6275 *Description* 6276Return a freshly malloced NULL-terminated vector of the names of all 6277the valid BFD architectures. Do not modify the names. 6278 62792.13.2.4 `bfd_arch_get_compatible' 6280.................................. 6281 6282*Synopsis* 6283 const bfd_arch_info_type *bfd_arch_get_compatible 6284 (const bfd *abfd, const bfd *bbfd, bfd_boolean accept_unknowns); 6285 *Description* 6286Determine whether two BFDs' architectures and machine types are 6287compatible. Calculates the lowest common denominator between the two 6288architectures and machine types implied by the BFDs and returns a 6289pointer to an `arch_info' structure describing the compatible machine. 6290 62912.13.2.5 `bfd_default_arch_struct' 6292.................................. 6293 6294*Description* 6295The `bfd_default_arch_struct' is an item of `bfd_arch_info_type' which 6296has been initialized to a fairly generic state. A BFD starts life by 6297pointing to this structure, until the correct back end has determined 6298the real architecture of the file. 6299 extern const bfd_arch_info_type bfd_default_arch_struct; 6300 63012.13.2.6 `bfd_set_arch_info' 6302............................ 6303 6304*Synopsis* 6305 void bfd_set_arch_info (bfd *abfd, const bfd_arch_info_type *arg); 6306 *Description* 6307Set the architecture info of ABFD to ARG. 6308 63092.13.2.7 `bfd_default_set_arch_mach' 6310.................................... 6311 6312*Synopsis* 6313 bfd_boolean bfd_default_set_arch_mach 6314 (bfd *abfd, enum bfd_architecture arch, unsigned long mach); 6315 *Description* 6316Set the architecture and machine type in BFD ABFD to ARCH and MACH. 6317Find the correct pointer to a structure and insert it into the 6318`arch_info' pointer. 6319 63202.13.2.8 `bfd_get_arch' 6321....................... 6322 6323*Synopsis* 6324 enum bfd_architecture bfd_get_arch (bfd *abfd); 6325 *Description* 6326Return the enumerated type which describes the BFD ABFD's architecture. 6327 63282.13.2.9 `bfd_get_mach' 6329....................... 6330 6331*Synopsis* 6332 unsigned long bfd_get_mach (bfd *abfd); 6333 *Description* 6334Return the long type which describes the BFD ABFD's machine. 6335 63362.13.2.10 `bfd_arch_bits_per_byte' 6337.................................. 6338 6339*Synopsis* 6340 unsigned int bfd_arch_bits_per_byte (bfd *abfd); 6341 *Description* 6342Return the number of bits in one of the BFD ABFD's architecture's bytes. 6343 63442.13.2.11 `bfd_arch_bits_per_address' 6345..................................... 6346 6347*Synopsis* 6348 unsigned int bfd_arch_bits_per_address (bfd *abfd); 6349 *Description* 6350Return the number of bits in one of the BFD ABFD's architecture's 6351addresses. 6352 63532.13.2.12 `bfd_default_compatible' 6354.................................. 6355 6356*Synopsis* 6357 const bfd_arch_info_type *bfd_default_compatible 6358 (const bfd_arch_info_type *a, const bfd_arch_info_type *b); 6359 *Description* 6360The default function for testing for compatibility. 6361 63622.13.2.13 `bfd_default_scan' 6363............................ 6364 6365*Synopsis* 6366 bfd_boolean bfd_default_scan 6367 (const struct bfd_arch_info *info, const char *string); 6368 *Description* 6369The default function for working out whether this is an architecture 6370hit and a machine hit. 6371 63722.13.2.14 `bfd_get_arch_info' 6373............................. 6374 6375*Synopsis* 6376 const bfd_arch_info_type *bfd_get_arch_info (bfd *abfd); 6377 *Description* 6378Return the architecture info struct in ABFD. 6379 63802.13.2.15 `bfd_lookup_arch' 6381........................... 6382 6383*Synopsis* 6384 const bfd_arch_info_type *bfd_lookup_arch 6385 (enum bfd_architecture arch, unsigned long machine); 6386 *Description* 6387Look for the architecture info structure which matches the arguments 6388ARCH and MACHINE. A machine of 0 matches the machine/architecture 6389structure which marks itself as the default. 6390 63912.13.2.16 `bfd_printable_arch_mach' 6392................................... 6393 6394*Synopsis* 6395 const char *bfd_printable_arch_mach 6396 (enum bfd_architecture arch, unsigned long machine); 6397 *Description* 6398Return a printable string representing the architecture and machine 6399type. 6400 6401 This routine is depreciated. 6402 64032.13.2.17 `bfd_octets_per_byte' 6404............................... 6405 6406*Synopsis* 6407 unsigned int bfd_octets_per_byte (bfd *abfd); 6408 *Description* 6409Return the number of octets (8-bit quantities) per target byte (minimum 6410addressable unit). In most cases, this will be one, but some DSP 6411targets have 16, 32, or even 48 bits per byte. 6412 64132.13.2.18 `bfd_arch_mach_octets_per_byte' 6414......................................... 6415 6416*Synopsis* 6417 unsigned int bfd_arch_mach_octets_per_byte 6418 (enum bfd_architecture arch, unsigned long machine); 6419 *Description* 6420See bfd_octets_per_byte. 6421 6422 This routine is provided for those cases where a bfd * is not 6423available 6424 6425 6426File: bfd.info, Node: Opening and Closing, Next: Internal, Prev: Architectures, Up: BFD front end 6427 64282.14 Opening and closing BFDs 6429============================= 6430 64312.14.1 Functions for opening and closing 6432---------------------------------------- 6433 64342.14.1.1 `bfd_fopen' 6435.................... 6436 6437*Synopsis* 6438 bfd *bfd_fopen (const char *filename, const char *target, 6439 const char *mode, int fd); 6440 *Description* 6441Open the file FILENAME with the target TARGET. Return a pointer to the 6442created BFD. If FD is not -1, then `fdopen' is used to open the file; 6443otherwise, `fopen' is used. MODE is passed directly to `fopen' or 6444`fdopen'. 6445 6446 Calls `bfd_find_target', so TARGET is interpreted as by that 6447function. 6448 6449 The new BFD is marked as cacheable iff FD is -1. 6450 6451 If `NULL' is returned then an error has occured. Possible errors 6452are `bfd_error_no_memory', `bfd_error_invalid_target' or `system_call' 6453error. 6454 64552.14.1.2 `bfd_openr' 6456.................... 6457 6458*Synopsis* 6459 bfd *bfd_openr (const char *filename, const char *target); 6460 *Description* 6461Open the file FILENAME (using `fopen') with the target TARGET. Return 6462a pointer to the created BFD. 6463 6464 Calls `bfd_find_target', so TARGET is interpreted as by that 6465function. 6466 6467 If `NULL' is returned then an error has occured. Possible errors 6468are `bfd_error_no_memory', `bfd_error_invalid_target' or `system_call' 6469error. 6470 64712.14.1.3 `bfd_fdopenr' 6472...................... 6473 6474*Synopsis* 6475 bfd *bfd_fdopenr (const char *filename, const char *target, int fd); 6476 *Description* 6477`bfd_fdopenr' is to `bfd_fopenr' much like `fdopen' is to `fopen'. It 6478opens a BFD on a file already described by the FD supplied. 6479 6480 When the file is later `bfd_close'd, the file descriptor will be 6481closed. If the caller desires that this file descriptor be cached by 6482BFD (opened as needed, closed as needed to free descriptors for other 6483opens), with the supplied FD used as an initial file descriptor (but 6484subject to closure at any time), call bfd_set_cacheable(bfd, 1) on the 6485returned BFD. The default is to assume no caching; the file descriptor 6486will remain open until `bfd_close', and will not be affected by BFD 6487operations on other files. 6488 6489 Possible errors are `bfd_error_no_memory', 6490`bfd_error_invalid_target' and `bfd_error_system_call'. 6491 64922.14.1.4 `bfd_openstreamr' 6493.......................... 6494 6495*Synopsis* 6496 bfd *bfd_openstreamr (const char *, const char *, void *); 6497 *Description* 6498Open a BFD for read access on an existing stdio stream. When the BFD 6499is passed to `bfd_close', the stream will be closed. 6500 65012.14.1.5 `bfd_openr_iovec' 6502.......................... 6503 6504*Synopsis* 6505 bfd *bfd_openr_iovec (const char *filename, const char *target, 6506 void *(*open) (struct bfd *nbfd, 6507 void *open_closure), 6508 void *open_closure, 6509 file_ptr (*pread) (struct bfd *nbfd, 6510 void *stream, 6511 void *buf, 6512 file_ptr nbytes, 6513 file_ptr offset), 6514 int (*close) (struct bfd *nbfd, 6515 void *stream), 6516 int (*stat) (struct bfd *abfd, 6517 void *stream, 6518 struct stat *sb)); 6519 *Description* 6520Create and return a BFD backed by a read-only STREAM. The STREAM is 6521created using OPEN, accessed using PREAD and destroyed using CLOSE. 6522 6523 Calls `bfd_find_target', so TARGET is interpreted as by that 6524function. 6525 6526 Calls OPEN (which can call `bfd_zalloc' and `bfd_get_filename') to 6527obtain the read-only stream backing the BFD. OPEN either succeeds 6528returning the non-`NULL' STREAM, or fails returning `NULL' (setting 6529`bfd_error'). 6530 6531 Calls PREAD to request NBYTES of data from STREAM starting at OFFSET 6532(e.g., via a call to `bfd_read'). PREAD either succeeds returning the 6533number of bytes read (which can be less than NBYTES when end-of-file), 6534or fails returning -1 (setting `bfd_error'). 6535 6536 Calls CLOSE when the BFD is later closed using `bfd_close'. CLOSE 6537either succeeds returning 0, or fails returning -1 (setting 6538`bfd_error'). 6539 6540 Calls STAT to fill in a stat structure for bfd_stat, bfd_get_size, 6541and bfd_get_mtime calls. STAT returns 0 on success, or returns -1 on 6542failure (setting `bfd_error'). 6543 6544 If `bfd_openr_iovec' returns `NULL' then an error has occurred. 6545Possible errors are `bfd_error_no_memory', `bfd_error_invalid_target' 6546and `bfd_error_system_call'. 6547 65482.14.1.6 `bfd_openw' 6549.................... 6550 6551*Synopsis* 6552 bfd *bfd_openw (const char *filename, const char *target); 6553 *Description* 6554Create a BFD, associated with file FILENAME, using the file format 6555TARGET, and return a pointer to it. 6556 6557 Possible errors are `bfd_error_system_call', `bfd_error_no_memory', 6558`bfd_error_invalid_target'. 6559 65602.14.1.7 `bfd_close' 6561.................... 6562 6563*Synopsis* 6564 bfd_boolean bfd_close (bfd *abfd); 6565 *Description* 6566Close a BFD. If the BFD was open for writing, then pending operations 6567are completed and the file written out and closed. If the created file 6568is executable, then `chmod' is called to mark it as such. 6569 6570 All memory attached to the BFD is released. 6571 6572 The file descriptor associated with the BFD is closed (even if it 6573was passed in to BFD by `bfd_fdopenr'). 6574 6575 *Returns* 6576`TRUE' is returned if all is ok, otherwise `FALSE'. 6577 65782.14.1.8 `bfd_close_all_done' 6579............................. 6580 6581*Synopsis* 6582 bfd_boolean bfd_close_all_done (bfd *); 6583 *Description* 6584Close a BFD. Differs from `bfd_close' since it does not complete any 6585pending operations. This routine would be used if the application had 6586just used BFD for swapping and didn't want to use any of the writing 6587code. 6588 6589 If the created file is executable, then `chmod' is called to mark it 6590as such. 6591 6592 All memory attached to the BFD is released. 6593 6594 *Returns* 6595`TRUE' is returned if all is ok, otherwise `FALSE'. 6596 65972.14.1.9 `bfd_create' 6598..................... 6599 6600*Synopsis* 6601 bfd *bfd_create (const char *filename, bfd *templ); 6602 *Description* 6603Create a new BFD in the manner of `bfd_openw', but without opening a 6604file. The new BFD takes the target from the target used by TEMPLATE. 6605The format is always set to `bfd_object'. 6606 66072.14.1.10 `bfd_make_writable' 6608............................. 6609 6610*Synopsis* 6611 bfd_boolean bfd_make_writable (bfd *abfd); 6612 *Description* 6613Takes a BFD as created by `bfd_create' and converts it into one like as 6614returned by `bfd_openw'. It does this by converting the BFD to 6615BFD_IN_MEMORY. It's assumed that you will call `bfd_make_readable' on 6616this bfd later. 6617 6618 *Returns* 6619`TRUE' is returned if all is ok, otherwise `FALSE'. 6620 66212.14.1.11 `bfd_make_readable' 6622............................. 6623 6624*Synopsis* 6625 bfd_boolean bfd_make_readable (bfd *abfd); 6626 *Description* 6627Takes a BFD as created by `bfd_create' and `bfd_make_writable' and 6628converts it into one like as returned by `bfd_openr'. It does this by 6629writing the contents out to the memory buffer, then reversing the 6630direction. 6631 6632 *Returns* 6633`TRUE' is returned if all is ok, otherwise `FALSE'. 6634 66352.14.1.12 `bfd_alloc' 6636..................... 6637 6638*Synopsis* 6639 void *bfd_alloc (bfd *abfd, bfd_size_type wanted); 6640 *Description* 6641Allocate a block of WANTED bytes of memory attached to `abfd' and 6642return a pointer to it. 6643 66442.14.1.13 `bfd_alloc2' 6645...................... 6646 6647*Synopsis* 6648 void *bfd_alloc2 (bfd *abfd, bfd_size_type nmemb, bfd_size_type size); 6649 *Description* 6650Allocate a block of NMEMB elements of SIZE bytes each of memory 6651attached to `abfd' and return a pointer to it. 6652 66532.14.1.14 `bfd_zalloc' 6654...................... 6655 6656*Synopsis* 6657 void *bfd_zalloc (bfd *abfd, bfd_size_type wanted); 6658 *Description* 6659Allocate a block of WANTED bytes of zeroed memory attached to `abfd' 6660and return a pointer to it. 6661 66622.14.1.15 `bfd_zalloc2' 6663....................... 6664 6665*Synopsis* 6666 void *bfd_zalloc2 (bfd *abfd, bfd_size_type nmemb, bfd_size_type size); 6667 *Description* 6668Allocate a block of NMEMB elements of SIZE bytes each of zeroed memory 6669attached to `abfd' and return a pointer to it. 6670 66712.14.1.16 `bfd_calc_gnu_debuglink_crc32' 6672........................................ 6673 6674*Synopsis* 6675 unsigned long bfd_calc_gnu_debuglink_crc32 6676 (unsigned long crc, const unsigned char *buf, bfd_size_type len); 6677 *Description* 6678Computes a CRC value as used in the .gnu_debuglink section. Advances 6679the previously computed CRC value by computing and adding in the crc32 6680for LEN bytes of BUF. 6681 6682 *Returns* 6683Return the updated CRC32 value. 6684 66852.14.1.17 `get_debug_link_info' 6686............................... 6687 6688*Synopsis* 6689 char *get_debug_link_info (bfd *abfd, unsigned long *crc32_out); 6690 *Description* 6691fetch the filename and CRC32 value for any separate debuginfo 6692associated with ABFD. Return NULL if no such info found, otherwise 6693return filename and update CRC32_OUT. 6694 66952.14.1.18 `separate_debug_file_exists' 6696...................................... 6697 6698*Synopsis* 6699 bfd_boolean separate_debug_file_exists 6700 (char *name, unsigned long crc32); 6701 *Description* 6702Checks to see if NAME is a file and if its contents match CRC32. 6703 67042.14.1.19 `find_separate_debug_file' 6705.................................... 6706 6707*Synopsis* 6708 char *find_separate_debug_file (bfd *abfd); 6709 *Description* 6710Searches ABFD for a reference to separate debugging information, scans 6711various locations in the filesystem, including the file tree rooted at 6712DEBUG_FILE_DIRECTORY, and returns a filename of such debugging 6713information if the file is found and has matching CRC32. Returns NULL 6714if no reference to debugging file exists, or file cannot be found. 6715 67162.14.1.20 `bfd_follow_gnu_debuglink' 6717.................................... 6718 6719*Synopsis* 6720 char *bfd_follow_gnu_debuglink (bfd *abfd, const char *dir); 6721 *Description* 6722Takes a BFD and searches it for a .gnu_debuglink section. If this 6723section is found, it examines the section for the name and checksum of 6724a '.debug' file containing auxiliary debugging information. It then 6725searches the filesystem for this .debug file in some standard 6726locations, including the directory tree rooted at DIR, and if found 6727returns the full filename. 6728 6729 If DIR is NULL, it will search a default path configured into libbfd 6730at build time. [XXX this feature is not currently implemented]. 6731 6732 *Returns* 6733`NULL' on any errors or failure to locate the .debug file, otherwise a 6734pointer to a heap-allocated string containing the filename. The caller 6735is responsible for freeing this string. 6736 67372.14.1.21 `bfd_create_gnu_debuglink_section' 6738............................................ 6739 6740*Synopsis* 6741 struct bfd_section *bfd_create_gnu_debuglink_section 6742 (bfd *abfd, const char *filename); 6743 *Description* 6744Takes a BFD and adds a .gnu_debuglink section to it. The section is 6745sized to be big enough to contain a link to the specified FILENAME. 6746 6747 *Returns* 6748A pointer to the new section is returned if all is ok. Otherwise 6749`NULL' is returned and bfd_error is set. 6750 67512.14.1.22 `bfd_fill_in_gnu_debuglink_section' 6752............................................. 6753 6754*Synopsis* 6755 bfd_boolean bfd_fill_in_gnu_debuglink_section 6756 (bfd *abfd, struct bfd_section *sect, const char *filename); 6757 *Description* 6758Takes a BFD and containing a .gnu_debuglink section SECT and fills in 6759the contents of the section to contain a link to the specified 6760FILENAME. The filename should be relative to the current directory. 6761 6762 *Returns* 6763`TRUE' is returned if all is ok. Otherwise `FALSE' is returned and 6764bfd_error is set. 6765 6766 6767File: bfd.info, Node: Internal, Next: File Caching, Prev: Opening and Closing, Up: BFD front end 6768 67692.15 Implementation details 6770=========================== 6771 67722.15.1 Internal functions 6773------------------------- 6774 6775*Description* 6776These routines are used within BFD. They are not intended for export, 6777but are documented here for completeness. 6778 67792.15.1.1 `bfd_write_bigendian_4byte_int' 6780........................................ 6781 6782*Synopsis* 6783 bfd_boolean bfd_write_bigendian_4byte_int (bfd *, unsigned int); 6784 *Description* 6785Write a 4 byte integer I to the output BFD ABFD, in big endian order 6786regardless of what else is going on. This is useful in archives. 6787 67882.15.1.2 `bfd_put_size' 6789....................... 6790 67912.15.1.3 `bfd_get_size' 6792....................... 6793 6794*Description* 6795These macros as used for reading and writing raw data in sections; each 6796access (except for bytes) is vectored through the target format of the 6797BFD and mangled accordingly. The mangling performs any necessary endian 6798translations and removes alignment restrictions. Note that types 6799accepted and returned by these macros are identical so they can be 6800swapped around in macros--for example, `libaout.h' defines `GET_WORD' 6801to either `bfd_get_32' or `bfd_get_64'. 6802 6803 In the put routines, VAL must be a `bfd_vma'. If we are on a system 6804without prototypes, the caller is responsible for making sure that is 6805true, with a cast if necessary. We don't cast them in the macro 6806definitions because that would prevent `lint' or `gcc -Wall' from 6807detecting sins such as passing a pointer. To detect calling these with 6808less than a `bfd_vma', use `gcc -Wconversion' on a host with 64 bit 6809`bfd_vma''s. 6810 6811 /* Byte swapping macros for user section data. */ 6812 6813 #define bfd_put_8(abfd, val, ptr) \ 6814 ((void) (*((unsigned char *) (ptr)) = (val) & 0xff)) 6815 #define bfd_put_signed_8 \ 6816 bfd_put_8 6817 #define bfd_get_8(abfd, ptr) \ 6818 (*(unsigned char *) (ptr) & 0xff) 6819 #define bfd_get_signed_8(abfd, ptr) \ 6820 (((*(unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80) 6821 6822 #define bfd_put_16(abfd, val, ptr) \ 6823 BFD_SEND (abfd, bfd_putx16, ((val),(ptr))) 6824 #define bfd_put_signed_16 \ 6825 bfd_put_16 6826 #define bfd_get_16(abfd, ptr) \ 6827 BFD_SEND (abfd, bfd_getx16, (ptr)) 6828 #define bfd_get_signed_16(abfd, ptr) \ 6829 BFD_SEND (abfd, bfd_getx_signed_16, (ptr)) 6830 6831 #define bfd_put_32(abfd, val, ptr) \ 6832 BFD_SEND (abfd, bfd_putx32, ((val),(ptr))) 6833 #define bfd_put_signed_32 \ 6834 bfd_put_32 6835 #define bfd_get_32(abfd, ptr) \ 6836 BFD_SEND (abfd, bfd_getx32, (ptr)) 6837 #define bfd_get_signed_32(abfd, ptr) \ 6838 BFD_SEND (abfd, bfd_getx_signed_32, (ptr)) 6839 6840 #define bfd_put_64(abfd, val, ptr) \ 6841 BFD_SEND (abfd, bfd_putx64, ((val), (ptr))) 6842 #define bfd_put_signed_64 \ 6843 bfd_put_64 6844 #define bfd_get_64(abfd, ptr) \ 6845 BFD_SEND (abfd, bfd_getx64, (ptr)) 6846 #define bfd_get_signed_64(abfd, ptr) \ 6847 BFD_SEND (abfd, bfd_getx_signed_64, (ptr)) 6848 6849 #define bfd_get(bits, abfd, ptr) \ 6850 ((bits) == 8 ? (bfd_vma) bfd_get_8 (abfd, ptr) \ 6851 : (bits) == 16 ? bfd_get_16 (abfd, ptr) \ 6852 : (bits) == 32 ? bfd_get_32 (abfd, ptr) \ 6853 : (bits) == 64 ? bfd_get_64 (abfd, ptr) \ 6854 : (abort (), (bfd_vma) - 1)) 6855 6856 #define bfd_put(bits, abfd, val, ptr) \ 6857 ((bits) == 8 ? bfd_put_8 (abfd, val, ptr) \ 6858 : (bits) == 16 ? bfd_put_16 (abfd, val, ptr) \ 6859 : (bits) == 32 ? bfd_put_32 (abfd, val, ptr) \ 6860 : (bits) == 64 ? bfd_put_64 (abfd, val, ptr) \ 6861 : (abort (), (void) 0)) 6862 68632.15.1.4 `bfd_h_put_size' 6864......................... 6865 6866*Description* 6867These macros have the same function as their `bfd_get_x' brethren, 6868except that they are used for removing information for the header 6869records of object files. Believe it or not, some object files keep 6870their header records in big endian order and their data in little 6871endian order. 6872 6873 /* Byte swapping macros for file header data. */ 6874 6875 #define bfd_h_put_8(abfd, val, ptr) \ 6876 bfd_put_8 (abfd, val, ptr) 6877 #define bfd_h_put_signed_8(abfd, val, ptr) \ 6878 bfd_put_8 (abfd, val, ptr) 6879 #define bfd_h_get_8(abfd, ptr) \ 6880 bfd_get_8 (abfd, ptr) 6881 #define bfd_h_get_signed_8(abfd, ptr) \ 6882 bfd_get_signed_8 (abfd, ptr) 6883 6884 #define bfd_h_put_16(abfd, val, ptr) \ 6885 BFD_SEND (abfd, bfd_h_putx16, (val, ptr)) 6886 #define bfd_h_put_signed_16 \ 6887 bfd_h_put_16 6888 #define bfd_h_get_16(abfd, ptr) \ 6889 BFD_SEND (abfd, bfd_h_getx16, (ptr)) 6890 #define bfd_h_get_signed_16(abfd, ptr) \ 6891 BFD_SEND (abfd, bfd_h_getx_signed_16, (ptr)) 6892 6893 #define bfd_h_put_32(abfd, val, ptr) \ 6894 BFD_SEND (abfd, bfd_h_putx32, (val, ptr)) 6895 #define bfd_h_put_signed_32 \ 6896 bfd_h_put_32 6897 #define bfd_h_get_32(abfd, ptr) \ 6898 BFD_SEND (abfd, bfd_h_getx32, (ptr)) 6899 #define bfd_h_get_signed_32(abfd, ptr) \ 6900 BFD_SEND (abfd, bfd_h_getx_signed_32, (ptr)) 6901 6902 #define bfd_h_put_64(abfd, val, ptr) \ 6903 BFD_SEND (abfd, bfd_h_putx64, (val, ptr)) 6904 #define bfd_h_put_signed_64 \ 6905 bfd_h_put_64 6906 #define bfd_h_get_64(abfd, ptr) \ 6907 BFD_SEND (abfd, bfd_h_getx64, (ptr)) 6908 #define bfd_h_get_signed_64(abfd, ptr) \ 6909 BFD_SEND (abfd, bfd_h_getx_signed_64, (ptr)) 6910 6911 /* Aliases for the above, which should eventually go away. */ 6912 6913 #define H_PUT_64 bfd_h_put_64 6914 #define H_PUT_32 bfd_h_put_32 6915 #define H_PUT_16 bfd_h_put_16 6916 #define H_PUT_8 bfd_h_put_8 6917 #define H_PUT_S64 bfd_h_put_signed_64 6918 #define H_PUT_S32 bfd_h_put_signed_32 6919 #define H_PUT_S16 bfd_h_put_signed_16 6920 #define H_PUT_S8 bfd_h_put_signed_8 6921 #define H_GET_64 bfd_h_get_64 6922 #define H_GET_32 bfd_h_get_32 6923 #define H_GET_16 bfd_h_get_16 6924 #define H_GET_8 bfd_h_get_8 6925 #define H_GET_S64 bfd_h_get_signed_64 6926 #define H_GET_S32 bfd_h_get_signed_32 6927 #define H_GET_S16 bfd_h_get_signed_16 6928 #define H_GET_S8 bfd_h_get_signed_8 6929 69302.15.1.5 `bfd_log2' 6931................... 6932 6933*Synopsis* 6934 unsigned int bfd_log2 (bfd_vma x); 6935 *Description* 6936Return the log base 2 of the value supplied, rounded up. E.g., an X of 69371025 returns 11. A X of 0 returns 0. 6938 6939 6940File: bfd.info, Node: File Caching, Next: Linker Functions, Prev: Internal, Up: BFD front end 6941 69422.16 File caching 6943================= 6944 6945The file caching mechanism is embedded within BFD and allows the 6946application to open as many BFDs as it wants without regard to the 6947underlying operating system's file descriptor limit (often as low as 20 6948open files). The module in `cache.c' maintains a least recently used 6949list of `BFD_CACHE_MAX_OPEN' files, and exports the name 6950`bfd_cache_lookup', which runs around and makes sure that the required 6951BFD is open. If not, then it chooses a file to close, closes it and 6952opens the one wanted, returning its file handle. 6953 69542.16.1 Caching functions 6955------------------------ 6956 69572.16.1.1 `bfd_cache_init' 6958......................... 6959 6960*Synopsis* 6961 bfd_boolean bfd_cache_init (bfd *abfd); 6962 *Description* 6963Add a newly opened BFD to the cache. 6964 69652.16.1.2 `bfd_cache_close' 6966.......................... 6967 6968*Synopsis* 6969 bfd_boolean bfd_cache_close (bfd *abfd); 6970 *Description* 6971Remove the BFD ABFD from the cache. If the attached file is open, then 6972close it too. 6973 6974 *Returns* 6975`FALSE' is returned if closing the file fails, `TRUE' is returned if 6976all is well. 6977 69782.16.1.3 `bfd_cache_close_all' 6979.............................. 6980 6981*Synopsis* 6982 bfd_boolean bfd_cache_close_all (void); 6983 *Description* 6984Remove all BFDs from the cache. If the attached file is open, then 6985close it too. 6986 6987 *Returns* 6988`FALSE' is returned if closing one of the file fails, `TRUE' is 6989returned if all is well. 6990 69912.16.1.4 `bfd_open_file' 6992........................ 6993 6994*Synopsis* 6995 FILE* bfd_open_file (bfd *abfd); 6996 *Description* 6997Call the OS to open a file for ABFD. Return the `FILE *' (possibly 6998`NULL') that results from this operation. Set up the BFD so that 6999future accesses know the file is open. If the `FILE *' returned is 7000`NULL', then it won't have been put in the cache, so it won't have to 7001be removed from it. 7002 7003 7004File: bfd.info, Node: Linker Functions, Next: Hash Tables, Prev: File Caching, Up: BFD front end 7005 70062.17 Linker Functions 7007===================== 7008 7009The linker uses three special entry points in the BFD target vector. 7010It is not necessary to write special routines for these entry points 7011when creating a new BFD back end, since generic versions are provided. 7012However, writing them can speed up linking and make it use 7013significantly less runtime memory. 7014 7015 The first routine creates a hash table used by the other routines. 7016The second routine adds the symbols from an object file to the hash 7017table. The third routine takes all the object files and links them 7018together to create the output file. These routines are designed so 7019that the linker proper does not need to know anything about the symbols 7020in the object files that it is linking. The linker merely arranges the 7021sections as directed by the linker script and lets BFD handle the 7022details of symbols and relocs. 7023 7024 The second routine and third routines are passed a pointer to a 7025`struct bfd_link_info' structure (defined in `bfdlink.h') which holds 7026information relevant to the link, including the linker hash table 7027(which was created by the first routine) and a set of callback 7028functions to the linker proper. 7029 7030 The generic linker routines are in `linker.c', and use the header 7031file `genlink.h'. As of this writing, the only back ends which have 7032implemented versions of these routines are a.out (in `aoutx.h') and 7033ECOFF (in `ecoff.c'). The a.out routines are used as examples 7034throughout this section. 7035 7036* Menu: 7037 7038* Creating a Linker Hash Table:: 7039* Adding Symbols to the Hash Table:: 7040* Performing the Final Link:: 7041 7042 7043File: bfd.info, Node: Creating a Linker Hash Table, Next: Adding Symbols to the Hash Table, Prev: Linker Functions, Up: Linker Functions 7044 70452.17.1 Creating a linker hash table 7046----------------------------------- 7047 7048The linker routines must create a hash table, which must be derived 7049from `struct bfd_link_hash_table' described in `bfdlink.c'. *Note Hash 7050Tables::, for information on how to create a derived hash table. This 7051entry point is called using the target vector of the linker output file. 7052 7053 The `_bfd_link_hash_table_create' entry point must allocate and 7054initialize an instance of the desired hash table. If the back end does 7055not require any additional information to be stored with the entries in 7056the hash table, the entry point may simply create a `struct 7057bfd_link_hash_table'. Most likely, however, some additional 7058information will be needed. 7059 7060 For example, with each entry in the hash table the a.out linker 7061keeps the index the symbol has in the final output file (this index 7062number is used so that when doing a relocatable link the symbol index 7063used in the output file can be quickly filled in when copying over a 7064reloc). The a.out linker code defines the required structures and 7065functions for a hash table derived from `struct bfd_link_hash_table'. 7066The a.out linker hash table is created by the function 7067`NAME(aout,link_hash_table_create)'; it simply allocates space for the 7068hash table, initializes it, and returns a pointer to it. 7069 7070 When writing the linker routines for a new back end, you will 7071generally not know exactly which fields will be required until you have 7072finished. You should simply create a new hash table which defines no 7073additional fields, and then simply add fields as they become necessary. 7074 7075 7076File: bfd.info, Node: Adding Symbols to the Hash Table, Next: Performing the Final Link, Prev: Creating a Linker Hash Table, Up: Linker Functions 7077 70782.17.2 Adding symbols to the hash table 7079--------------------------------------- 7080 7081The linker proper will call the `_bfd_link_add_symbols' entry point for 7082each object file or archive which is to be linked (typically these are 7083the files named on the command line, but some may also come from the 7084linker script). The entry point is responsible for examining the file. 7085For an object file, BFD must add any relevant symbol information to 7086the hash table. For an archive, BFD must determine which elements of 7087the archive should be used and adding them to the link. 7088 7089 The a.out version of this entry point is 7090`NAME(aout,link_add_symbols)'. 7091 7092* Menu: 7093 7094* Differing file formats:: 7095* Adding symbols from an object file:: 7096* Adding symbols from an archive:: 7097 7098 7099File: bfd.info, Node: Differing file formats, Next: Adding symbols from an object file, Prev: Adding Symbols to the Hash Table, Up: Adding Symbols to the Hash Table 7100 71012.17.2.1 Differing file formats 7102............................... 7103 7104Normally all the files involved in a link will be of the same format, 7105but it is also possible to link together different format object files, 7106and the back end must support that. The `_bfd_link_add_symbols' entry 7107point is called via the target vector of the file to be added. This 7108has an important consequence: the function may not assume that the hash 7109table is the type created by the corresponding 7110`_bfd_link_hash_table_create' vector. All the `_bfd_link_add_symbols' 7111function can assume about the hash table is that it is derived from 7112`struct bfd_link_hash_table'. 7113 7114 Sometimes the `_bfd_link_add_symbols' function must store some 7115information in the hash table entry to be used by the `_bfd_final_link' 7116function. In such a case the `creator' field of the hash table must be 7117checked to make sure that the hash table was created by an object file 7118of the same format. 7119 7120 The `_bfd_final_link' routine must be prepared to handle a hash 7121entry without any extra information added by the 7122`_bfd_link_add_symbols' function. A hash entry without extra 7123information will also occur when the linker script directs the linker 7124to create a symbol. Note that, regardless of how a hash table entry is 7125added, all the fields will be initialized to some sort of null value by 7126the hash table entry initialization function. 7127 7128 See `ecoff_link_add_externals' for an example of how to check the 7129`creator' field before saving information (in this case, the ECOFF 7130external symbol debugging information) in a hash table entry. 7131 7132 7133File: bfd.info, Node: Adding symbols from an object file, Next: Adding symbols from an archive, Prev: Differing file formats, Up: Adding Symbols to the Hash Table 7134 71352.17.2.2 Adding symbols from an object file 7136........................................... 7137 7138When the `_bfd_link_add_symbols' routine is passed an object file, it 7139must add all externally visible symbols in that object file to the hash 7140table. The actual work of adding the symbol to the hash table is 7141normally handled by the function `_bfd_generic_link_add_one_symbol'. 7142The `_bfd_link_add_symbols' routine is responsible for reading all the 7143symbols from the object file and passing the correct information to 7144`_bfd_generic_link_add_one_symbol'. 7145 7146 The `_bfd_link_add_symbols' routine should not use 7147`bfd_canonicalize_symtab' to read the symbols. The point of providing 7148this routine is to avoid the overhead of converting the symbols into 7149generic `asymbol' structures. 7150 7151 `_bfd_generic_link_add_one_symbol' handles the details of combining 7152common symbols, warning about multiple definitions, and so forth. It 7153takes arguments which describe the symbol to add, notably symbol flags, 7154a section, and an offset. The symbol flags include such things as 7155`BSF_WEAK' or `BSF_INDIRECT'. The section is a section in the object 7156file, or something like `bfd_und_section_ptr' for an undefined symbol 7157or `bfd_com_section_ptr' for a common symbol. 7158 7159 If the `_bfd_final_link' routine is also going to need to read the 7160symbol information, the `_bfd_link_add_symbols' routine should save it 7161somewhere attached to the object file BFD. However, the information 7162should only be saved if the `keep_memory' field of the `info' argument 7163is TRUE, so that the `-no-keep-memory' linker switch is effective. 7164 7165 The a.out function which adds symbols from an object file is 7166`aout_link_add_object_symbols', and most of the interesting work is in 7167`aout_link_add_symbols'. The latter saves pointers to the hash tables 7168entries created by `_bfd_generic_link_add_one_symbol' indexed by symbol 7169number, so that the `_bfd_final_link' routine does not have to call the 7170hash table lookup routine to locate the entry. 7171 7172 7173File: bfd.info, Node: Adding symbols from an archive, Prev: Adding symbols from an object file, Up: Adding Symbols to the Hash Table 7174 71752.17.2.3 Adding symbols from an archive 7176....................................... 7177 7178When the `_bfd_link_add_symbols' routine is passed an archive, it must 7179look through the symbols defined by the archive and decide which 7180elements of the archive should be included in the link. For each such 7181element it must call the `add_archive_element' linker callback, and it 7182must add the symbols from the object file to the linker hash table. 7183 7184 In most cases the work of looking through the symbols in the archive 7185should be done by the `_bfd_generic_link_add_archive_symbols' function. 7186This function builds a hash table from the archive symbol table and 7187looks through the list of undefined symbols to see which elements 7188should be included. `_bfd_generic_link_add_archive_symbols' is passed 7189a function to call to make the final decision about adding an archive 7190element to the link and to do the actual work of adding the symbols to 7191the linker hash table. 7192 7193 The function passed to `_bfd_generic_link_add_archive_symbols' must 7194read the symbols of the archive element and decide whether the archive 7195element should be included in the link. If the element is to be 7196included, the `add_archive_element' linker callback routine must be 7197called with the element as an argument, and the elements symbols must 7198be added to the linker hash table just as though the element had itself 7199been passed to the `_bfd_link_add_symbols' function. 7200 7201 When the a.out `_bfd_link_add_symbols' function receives an archive, 7202it calls `_bfd_generic_link_add_archive_symbols' passing 7203`aout_link_check_archive_element' as the function argument. 7204`aout_link_check_archive_element' calls `aout_link_check_ar_symbols'. 7205If the latter decides to add the element (an element is only added if 7206it provides a real, non-common, definition for a previously undefined 7207or common symbol) it calls the `add_archive_element' callback and then 7208`aout_link_check_archive_element' calls `aout_link_add_symbols' to 7209actually add the symbols to the linker hash table. 7210 7211 The ECOFF back end is unusual in that it does not normally call 7212`_bfd_generic_link_add_archive_symbols', because ECOFF archives already 7213contain a hash table of symbols. The ECOFF back end searches the 7214archive itself to avoid the overhead of creating a new hash table. 7215 7216 7217File: bfd.info, Node: Performing the Final Link, Prev: Adding Symbols to the Hash Table, Up: Linker Functions 7218 72192.17.3 Performing the final link 7220-------------------------------- 7221 7222When all the input files have been processed, the linker calls the 7223`_bfd_final_link' entry point of the output BFD. This routine is 7224responsible for producing the final output file, which has several 7225aspects. It must relocate the contents of the input sections and copy 7226the data into the output sections. It must build an output symbol 7227table including any local symbols from the input files and the global 7228symbols from the hash table. When producing relocatable output, it must 7229modify the input relocs and write them into the output file. There may 7230also be object format dependent work to be done. 7231 7232 The linker will also call the `write_object_contents' entry point 7233when the BFD is closed. The two entry points must work together in 7234order to produce the correct output file. 7235 7236 The details of how this works are inevitably dependent upon the 7237specific object file format. The a.out `_bfd_final_link' routine is 7238`NAME(aout,final_link)'. 7239 7240* Menu: 7241 7242* Information provided by the linker:: 7243* Relocating the section contents:: 7244* Writing the symbol table:: 7245 7246 7247File: bfd.info, Node: Information provided by the linker, Next: Relocating the section contents, Prev: Performing the Final Link, Up: Performing the Final Link 7248 72492.17.3.1 Information provided by the linker 7250........................................... 7251 7252Before the linker calls the `_bfd_final_link' entry point, it sets up 7253some data structures for the function to use. 7254 7255 The `input_bfds' field of the `bfd_link_info' structure will point 7256to a list of all the input files included in the link. These files are 7257linked through the `link_next' field of the `bfd' structure. 7258 7259 Each section in the output file will have a list of `link_order' 7260structures attached to the `map_head.link_order' field (the 7261`link_order' structure is defined in `bfdlink.h'). These structures 7262describe how to create the contents of the output section in terms of 7263the contents of various input sections, fill constants, and, 7264eventually, other types of information. They also describe relocs that 7265must be created by the BFD backend, but do not correspond to any input 7266file; this is used to support -Ur, which builds constructors while 7267generating a relocatable object file. 7268 7269 7270File: bfd.info, Node: Relocating the section contents, Next: Writing the symbol table, Prev: Information provided by the linker, Up: Performing the Final Link 7271 72722.17.3.2 Relocating the section contents 7273........................................ 7274 7275The `_bfd_final_link' function should look through the `link_order' 7276structures attached to each section of the output file. Each 7277`link_order' structure should either be handled specially, or it should 7278be passed to the function `_bfd_default_link_order' which will do the 7279right thing (`_bfd_default_link_order' is defined in `linker.c'). 7280 7281 For efficiency, a `link_order' of type `bfd_indirect_link_order' 7282whose associated section belongs to a BFD of the same format as the 7283output BFD must be handled specially. This type of `link_order' 7284describes part of an output section in terms of a section belonging to 7285one of the input files. The `_bfd_final_link' function should read the 7286contents of the section and any associated relocs, apply the relocs to 7287the section contents, and write out the modified section contents. If 7288performing a relocatable link, the relocs themselves must also be 7289modified and written out. 7290 7291 The functions `_bfd_relocate_contents' and 7292`_bfd_final_link_relocate' provide some general support for performing 7293the actual relocations, notably overflow checking. Their arguments 7294include information about the symbol the relocation is against and a 7295`reloc_howto_type' argument which describes the relocation to perform. 7296These functions are defined in `reloc.c'. 7297 7298 The a.out function which handles reading, relocating, and writing 7299section contents is `aout_link_input_section'. The actual relocation 7300is done in `aout_link_input_section_std' and 7301`aout_link_input_section_ext'. 7302 7303 7304File: bfd.info, Node: Writing the symbol table, Prev: Relocating the section contents, Up: Performing the Final Link 7305 73062.17.3.3 Writing the symbol table 7307................................. 7308 7309The `_bfd_final_link' function must gather all the symbols in the input 7310files and write them out. It must also write out all the symbols in 7311the global hash table. This must be controlled by the `strip' and 7312`discard' fields of the `bfd_link_info' structure. 7313 7314 The local symbols of the input files will not have been entered into 7315the linker hash table. The `_bfd_final_link' routine must consider 7316each input file and include the symbols in the output file. It may be 7317convenient to do this when looking through the `link_order' structures, 7318or it may be done by stepping through the `input_bfds' list. 7319 7320 The `_bfd_final_link' routine must also traverse the global hash 7321table to gather all the externally visible symbols. It is possible 7322that most of the externally visible symbols may be written out when 7323considering the symbols of each input file, but it is still necessary 7324to traverse the hash table since the linker script may have defined 7325some symbols that are not in any of the input files. 7326 7327 The `strip' field of the `bfd_link_info' structure controls which 7328symbols are written out. The possible values are listed in 7329`bfdlink.h'. If the value is `strip_some', then the `keep_hash' field 7330of the `bfd_link_info' structure is a hash table of symbols to keep; 7331each symbol should be looked up in this hash table, and only symbols 7332which are present should be included in the output file. 7333 7334 If the `strip' field of the `bfd_link_info' structure permits local 7335symbols to be written out, the `discard' field is used to further 7336controls which local symbols are included in the output file. If the 7337value is `discard_l', then all local symbols which begin with a certain 7338prefix are discarded; this is controlled by the 7339`bfd_is_local_label_name' entry point. 7340 7341 The a.out backend handles symbols by calling 7342`aout_link_write_symbols' on each input BFD and then traversing the 7343global hash table with the function `aout_link_write_other_symbol'. It 7344builds a string table while writing out the symbols, which is written 7345to the output file at the end of `NAME(aout,final_link)'. 7346 73472.17.3.4 `bfd_link_split_section' 7348................................. 7349 7350*Synopsis* 7351 bfd_boolean bfd_link_split_section (bfd *abfd, asection *sec); 7352 *Description* 7353Return nonzero if SEC should be split during a reloceatable or final 7354link. 7355 #define bfd_link_split_section(abfd, sec) \ 7356 BFD_SEND (abfd, _bfd_link_split_section, (abfd, sec)) 7357 73582.17.3.5 `bfd_section_already_linked' 7359..................................... 7360 7361*Synopsis* 7362 void bfd_section_already_linked (bfd *abfd, asection *sec, 7363 struct bfd_link_info *info); 7364 *Description* 7365Check if SEC has been already linked during a reloceatable or final 7366link. 7367 #define bfd_section_already_linked(abfd, sec, info) \ 7368 BFD_SEND (abfd, _section_already_linked, (abfd, sec, info)) 7369 7370 7371File: bfd.info, Node: Hash Tables, Prev: Linker Functions, Up: BFD front end 7372 73732.18 Hash Tables 7374================ 7375 7376BFD provides a simple set of hash table functions. Routines are 7377provided to initialize a hash table, to free a hash table, to look up a 7378string in a hash table and optionally create an entry for it, and to 7379traverse a hash table. There is currently no routine to delete an 7380string from a hash table. 7381 7382 The basic hash table does not permit any data to be stored with a 7383string. However, a hash table is designed to present a base class from 7384which other types of hash tables may be derived. These derived types 7385may store additional information with the string. Hash tables were 7386implemented in this way, rather than simply providing a data pointer in 7387a hash table entry, because they were designed for use by the linker 7388back ends. The linker may create thousands of hash table entries, and 7389the overhead of allocating private data and storing and following 7390pointers becomes noticeable. 7391 7392 The basic hash table code is in `hash.c'. 7393 7394* Menu: 7395 7396* Creating and Freeing a Hash Table:: 7397* Looking Up or Entering a String:: 7398* Traversing a Hash Table:: 7399* Deriving a New Hash Table Type:: 7400 7401 7402File: bfd.info, Node: Creating and Freeing a Hash Table, Next: Looking Up or Entering a String, Prev: Hash Tables, Up: Hash Tables 7403 74042.18.1 Creating and freeing a hash table 7405---------------------------------------- 7406 7407To create a hash table, create an instance of a `struct bfd_hash_table' 7408(defined in `bfd.h') and call `bfd_hash_table_init' (if you know 7409approximately how many entries you will need, the function 7410`bfd_hash_table_init_n', which takes a SIZE argument, may be used). 7411`bfd_hash_table_init' returns `FALSE' if some sort of error occurs. 7412 7413 The function `bfd_hash_table_init' take as an argument a function to 7414use to create new entries. For a basic hash table, use the function 7415`bfd_hash_newfunc'. *Note Deriving a New Hash Table Type::, for why 7416you would want to use a different value for this argument. 7417 7418 `bfd_hash_table_init' will create an objalloc which will be used to 7419allocate new entries. You may allocate memory on this objalloc using 7420`bfd_hash_allocate'. 7421 7422 Use `bfd_hash_table_free' to free up all the memory that has been 7423allocated for a hash table. This will not free up the `struct 7424bfd_hash_table' itself, which you must provide. 7425 7426 Use `bfd_hash_set_default_size' to set the default size of hash 7427table to use. 7428 7429 7430File: bfd.info, Node: Looking Up or Entering a String, Next: Traversing a Hash Table, Prev: Creating and Freeing a Hash Table, Up: Hash Tables 7431 74322.18.2 Looking up or entering a string 7433-------------------------------------- 7434 7435The function `bfd_hash_lookup' is used both to look up a string in the 7436hash table and to create a new entry. 7437 7438 If the CREATE argument is `FALSE', `bfd_hash_lookup' will look up a 7439string. If the string is found, it will returns a pointer to a `struct 7440bfd_hash_entry'. If the string is not found in the table 7441`bfd_hash_lookup' will return `NULL'. You should not modify any of the 7442fields in the returns `struct bfd_hash_entry'. 7443 7444 If the CREATE argument is `TRUE', the string will be entered into 7445the hash table if it is not already there. Either way a pointer to a 7446`struct bfd_hash_entry' will be returned, either to the existing 7447structure or to a newly created one. In this case, a `NULL' return 7448means that an error occurred. 7449 7450 If the CREATE argument is `TRUE', and a new entry is created, the 7451COPY argument is used to decide whether to copy the string onto the 7452hash table objalloc or not. If COPY is passed as `FALSE', you must be 7453careful not to deallocate or modify the string as long as the hash table 7454exists. 7455 7456 7457File: bfd.info, Node: Traversing a Hash Table, Next: Deriving a New Hash Table Type, Prev: Looking Up or Entering a String, Up: Hash Tables 7458 74592.18.3 Traversing a hash table 7460------------------------------ 7461 7462The function `bfd_hash_traverse' may be used to traverse a hash table, 7463calling a function on each element. The traversal is done in a random 7464order. 7465 7466 `bfd_hash_traverse' takes as arguments a function and a generic 7467`void *' pointer. The function is called with a hash table entry (a 7468`struct bfd_hash_entry *') and the generic pointer passed to 7469`bfd_hash_traverse'. The function must return a `boolean' value, which 7470indicates whether to continue traversing the hash table. If the 7471function returns `FALSE', `bfd_hash_traverse' will stop the traversal 7472and return immediately. 7473 7474 7475File: bfd.info, Node: Deriving a New Hash Table Type, Prev: Traversing a Hash Table, Up: Hash Tables 7476 74772.18.4 Deriving a new hash table type 7478------------------------------------- 7479 7480Many uses of hash tables want to store additional information which 7481each entry in the hash table. Some also find it convenient to store 7482additional information with the hash table itself. This may be done 7483using a derived hash table. 7484 7485 Since C is not an object oriented language, creating a derived hash 7486table requires sticking together some boilerplate routines with a few 7487differences specific to the type of hash table you want to create. 7488 7489 An example of a derived hash table is the linker hash table. The 7490structures for this are defined in `bfdlink.h'. The functions are in 7491`linker.c'. 7492 7493 You may also derive a hash table from an already derived hash table. 7494For example, the a.out linker backend code uses a hash table derived 7495from the linker hash table. 7496 7497* Menu: 7498 7499* Define the Derived Structures:: 7500* Write the Derived Creation Routine:: 7501* Write Other Derived Routines:: 7502 7503 7504File: bfd.info, Node: Define the Derived Structures, Next: Write the Derived Creation Routine, Prev: Deriving a New Hash Table Type, Up: Deriving a New Hash Table Type 7505 75062.18.4.1 Define the derived structures 7507...................................... 7508 7509You must define a structure for an entry in the hash table, and a 7510structure for the hash table itself. 7511 7512 The first field in the structure for an entry in the hash table must 7513be of the type used for an entry in the hash table you are deriving 7514from. If you are deriving from a basic hash table this is `struct 7515bfd_hash_entry', which is defined in `bfd.h'. The first field in the 7516structure for the hash table itself must be of the type of the hash 7517table you are deriving from itself. If you are deriving from a basic 7518hash table, this is `struct bfd_hash_table'. 7519 7520 For example, the linker hash table defines `struct 7521bfd_link_hash_entry' (in `bfdlink.h'). The first field, `root', is of 7522type `struct bfd_hash_entry'. Similarly, the first field in `struct 7523bfd_link_hash_table', `table', is of type `struct bfd_hash_table'. 7524 7525 7526File: bfd.info, Node: Write the Derived Creation Routine, Next: Write Other Derived Routines, Prev: Define the Derived Structures, Up: Deriving a New Hash Table Type 7527 75282.18.4.2 Write the derived creation routine 7529........................................... 7530 7531You must write a routine which will create and initialize an entry in 7532the hash table. This routine is passed as the function argument to 7533`bfd_hash_table_init'. 7534 7535 In order to permit other hash tables to be derived from the hash 7536table you are creating, this routine must be written in a standard way. 7537 7538 The first argument to the creation routine is a pointer to a hash 7539table entry. This may be `NULL', in which case the routine should 7540allocate the right amount of space. Otherwise the space has already 7541been allocated by a hash table type derived from this one. 7542 7543 After allocating space, the creation routine must call the creation 7544routine of the hash table type it is derived from, passing in a pointer 7545to the space it just allocated. This will initialize any fields used 7546by the base hash table. 7547 7548 Finally the creation routine must initialize any local fields for 7549the new hash table type. 7550 7551 Here is a boilerplate example of a creation routine. FUNCTION_NAME 7552is the name of the routine. ENTRY_TYPE is the type of an entry in the 7553hash table you are creating. BASE_NEWFUNC is the name of the creation 7554routine of the hash table type your hash table is derived from. 7555 7556 struct bfd_hash_entry * 7557 FUNCTION_NAME (struct bfd_hash_entry *entry, 7558 struct bfd_hash_table *table, 7559 const char *string) 7560 { 7561 struct ENTRY_TYPE *ret = (ENTRY_TYPE *) entry; 7562 7563 /* Allocate the structure if it has not already been allocated by a 7564 derived class. */ 7565 if (ret == NULL) 7566 { 7567 ret = bfd_hash_allocate (table, sizeof (* ret)); 7568 if (ret == NULL) 7569 return NULL; 7570 } 7571 7572 /* Call the allocation method of the base class. */ 7573 ret = ((ENTRY_TYPE *) 7574 BASE_NEWFUNC ((struct bfd_hash_entry *) ret, table, string)); 7575 7576 /* Initialize the local fields here. */ 7577 7578 return (struct bfd_hash_entry *) ret; 7579 } 7580 *Description* 7581The creation routine for the linker hash table, which is in `linker.c', 7582looks just like this example. FUNCTION_NAME is 7583`_bfd_link_hash_newfunc'. ENTRY_TYPE is `struct bfd_link_hash_entry'. 7584BASE_NEWFUNC is `bfd_hash_newfunc', the creation routine for a basic 7585hash table. 7586 7587 `_bfd_link_hash_newfunc' also initializes the local fields in a 7588linker hash table entry: `type', `written' and `next'. 7589 7590 7591File: bfd.info, Node: Write Other Derived Routines, Prev: Write the Derived Creation Routine, Up: Deriving a New Hash Table Type 7592 75932.18.4.3 Write other derived routines 7594..................................... 7595 7596You will want to write other routines for your new hash table, as well. 7597 7598 You will want an initialization routine which calls the 7599initialization routine of the hash table you are deriving from and 7600initializes any other local fields. For the linker hash table, this is 7601`_bfd_link_hash_table_init' in `linker.c'. 7602 7603 You will want a lookup routine which calls the lookup routine of the 7604hash table you are deriving from and casts the result. The linker hash 7605table uses `bfd_link_hash_lookup' in `linker.c' (this actually takes an 7606additional argument which it uses to decide how to return the looked up 7607value). 7608 7609 You may want a traversal routine. This should just call the 7610traversal routine of the hash table you are deriving from with 7611appropriate casts. The linker hash table uses `bfd_link_hash_traverse' 7612in `linker.c'. 7613 7614 These routines may simply be defined as macros. For example, the 7615a.out backend linker hash table, which is derived from the linker hash 7616table, uses macros for the lookup and traversal routines. These are 7617`aout_link_hash_lookup' and `aout_link_hash_traverse' in aoutx.h. 7618 7619 7620File: bfd.info, Node: BFD back ends, Next: GNU Free Documentation License, Prev: BFD front end, Up: Top 7621 76223 BFD back ends 7623*************** 7624 7625* Menu: 7626 7627* What to Put Where:: 7628* aout :: a.out backends 7629* coff :: coff backends 7630* elf :: elf backends 7631* mmo :: mmo backend 7632 7633 7634File: bfd.info, Node: What to Put Where, Next: aout, Prev: BFD back ends, Up: BFD back ends 7635 76363.1 What to Put Where 7637===================== 7638 7639All of BFD lives in one directory. 7640 7641 7642File: bfd.info, Node: aout, Next: coff, Prev: What to Put Where, Up: BFD back ends 7643 76443.2 a.out backends 7645================== 7646 7647*Description* 7648BFD supports a number of different flavours of a.out format, though the 7649major differences are only the sizes of the structures on disk, and the 7650shape of the relocation information. 7651 7652 The support is split into a basic support file `aoutx.h' and other 7653files which derive functions from the base. One derivation file is 7654`aoutf1.h' (for a.out flavour 1), and adds to the basic a.out functions 7655support for sun3, sun4, 386 and 29k a.out files, to create a target 7656jump vector for a specific target. 7657 7658 This information is further split out into more specific files for 7659each machine, including `sunos.c' for sun3 and sun4, `newsos3.c' for 7660the Sony NEWS, and `demo64.c' for a demonstration of a 64 bit a.out 7661format. 7662 7663 The base file `aoutx.h' defines general mechanisms for reading and 7664writing records to and from disk and various other methods which BFD 7665requires. It is included by `aout32.c' and `aout64.c' to form the names 7666`aout_32_swap_exec_header_in', `aout_64_swap_exec_header_in', etc. 7667 7668 As an example, this is what goes on to make the back end for a sun4, 7669from `aout32.c': 7670 7671 #define ARCH_SIZE 32 7672 #include "aoutx.h" 7673 7674 Which exports names: 7675 7676 ... 7677 aout_32_canonicalize_reloc 7678 aout_32_find_nearest_line 7679 aout_32_get_lineno 7680 aout_32_get_reloc_upper_bound 7681 ... 7682 7683 from `sunos.c': 7684 7685 #define TARGET_NAME "a.out-sunos-big" 7686 #define VECNAME sunos_big_vec 7687 #include "aoutf1.h" 7688 7689 requires all the names from `aout32.c', and produces the jump vector 7690 7691 sunos_big_vec 7692 7693 The file `host-aout.c' is a special case. It is for a large set of 7694hosts that use "more or less standard" a.out files, and for which 7695cross-debugging is not interesting. It uses the standard 32-bit a.out 7696support routines, but determines the file offsets and addresses of the 7697text, data, and BSS sections, the machine architecture and machine 7698type, and the entry point address, in a host-dependent manner. Once 7699these values have been determined, generic code is used to handle the 7700object file. 7701 7702 When porting it to run on a new system, you must supply: 7703 7704 HOST_PAGE_SIZE 7705 HOST_SEGMENT_SIZE 7706 HOST_MACHINE_ARCH (optional) 7707 HOST_MACHINE_MACHINE (optional) 7708 HOST_TEXT_START_ADDR 7709 HOST_STACK_END_ADDR 7710 7711 in the file `../include/sys/h-XXX.h' (for your host). These values, 7712plus the structures and macros defined in `a.out.h' on your host 7713system, will produce a BFD target that will access ordinary a.out files 7714on your host. To configure a new machine to use `host-aout.c', specify: 7715 7716 TDEFAULTS = -DDEFAULT_VECTOR=host_aout_big_vec 7717 TDEPFILES= host-aout.o trad-core.o 7718 7719 in the `config/XXX.mt' file, and modify `configure.in' to use the 7720`XXX.mt' file (by setting "`bfd_target=XXX'") when your configuration 7721is selected. 7722 77233.2.1 Relocations 7724----------------- 7725 7726*Description* 7727The file `aoutx.h' provides for both the _standard_ and _extended_ 7728forms of a.out relocation records. 7729 7730 The standard records contain only an address, a symbol index, and a 7731type field. The extended records (used on 29ks and sparcs) also have a 7732full integer for an addend. 7733 77343.2.2 Internal entry points 7735--------------------------- 7736 7737*Description* 7738`aoutx.h' exports several routines for accessing the contents of an 7739a.out file, which are gathered and exported in turn by various format 7740specific files (eg sunos.c). 7741 77423.2.2.1 `aout_SIZE_swap_exec_header_in' 7743....................................... 7744 7745*Synopsis* 7746 void aout_SIZE_swap_exec_header_in, 7747 (bfd *abfd, 7748 struct external_exec *bytes, 7749 struct internal_exec *execp); 7750 *Description* 7751Swap the information in an executable header RAW_BYTES taken from a raw 7752byte stream memory image into the internal exec header structure EXECP. 7753 77543.2.2.2 `aout_SIZE_swap_exec_header_out' 7755........................................ 7756 7757*Synopsis* 7758 void aout_SIZE_swap_exec_header_out 7759 (bfd *abfd, 7760 struct internal_exec *execp, 7761 struct external_exec *raw_bytes); 7762 *Description* 7763Swap the information in an internal exec header structure EXECP into 7764the buffer RAW_BYTES ready for writing to disk. 7765 77663.2.2.3 `aout_SIZE_some_aout_object_p' 7767...................................... 7768 7769*Synopsis* 7770 const bfd_target *aout_SIZE_some_aout_object_p 7771 (bfd *abfd, 7772 struct internal_exec *execp, 7773 const bfd_target *(*callback_to_real_object_p) (bfd *)); 7774 *Description* 7775Some a.out variant thinks that the file open in ABFD checking is an 7776a.out file. Do some more checking, and set up for access if it really 7777is. Call back to the calling environment's "finish up" function just 7778before returning, to handle any last-minute setup. 7779 77803.2.2.4 `aout_SIZE_mkobject' 7781............................ 7782 7783*Synopsis* 7784 bfd_boolean aout_SIZE_mkobject, (bfd *abfd); 7785 *Description* 7786Initialize BFD ABFD for use with a.out files. 7787 77883.2.2.5 `aout_SIZE_machine_type' 7789................................ 7790 7791*Synopsis* 7792 enum machine_type aout_SIZE_machine_type 7793 (enum bfd_architecture arch, 7794 unsigned long machine, 7795 bfd_boolean *unknown); 7796 *Description* 7797Keep track of machine architecture and machine type for a.out's. Return 7798the `machine_type' for a particular architecture and machine, or 7799`M_UNKNOWN' if that exact architecture and machine can't be represented 7800in a.out format. 7801 7802 If the architecture is understood, machine type 0 (default) is 7803always understood. 7804 78053.2.2.6 `aout_SIZE_set_arch_mach' 7806................................. 7807 7808*Synopsis* 7809 bfd_boolean aout_SIZE_set_arch_mach, 7810 (bfd *, 7811 enum bfd_architecture arch, 7812 unsigned long machine); 7813 *Description* 7814Set the architecture and the machine of the BFD ABFD to the values ARCH 7815and MACHINE. Verify that ABFD's format can support the architecture 7816required. 7817 78183.2.2.7 `aout_SIZE_new_section_hook' 7819.................................... 7820 7821*Synopsis* 7822 bfd_boolean aout_SIZE_new_section_hook, 7823 (bfd *abfd, 7824 asection *newsect); 7825 *Description* 7826Called by the BFD in response to a `bfd_make_section' request. 7827 7828 7829File: bfd.info, Node: coff, Next: elf, Prev: aout, Up: BFD back ends 7830 78313.3 coff backends 7832================= 7833 7834BFD supports a number of different flavours of coff format. The major 7835differences between formats are the sizes and alignments of fields in 7836structures on disk, and the occasional extra field. 7837 7838 Coff in all its varieties is implemented with a few common files and 7839a number of implementation specific files. For example, The 88k bcs 7840coff format is implemented in the file `coff-m88k.c'. This file 7841`#include's `coff/m88k.h' which defines the external structure of the 7842coff format for the 88k, and `coff/internal.h' which defines the 7843internal structure. `coff-m88k.c' also defines the relocations used by 7844the 88k format *Note Relocations::. 7845 7846 The Intel i960 processor version of coff is implemented in 7847`coff-i960.c'. This file has the same structure as `coff-m88k.c', 7848except that it includes `coff/i960.h' rather than `coff-m88k.h'. 7849 78503.3.1 Porting to a new version of coff 7851-------------------------------------- 7852 7853The recommended method is to select from the existing implementations 7854the version of coff which is most like the one you want to use. For 7855example, we'll say that i386 coff is the one you select, and that your 7856coff flavour is called foo. Copy `i386coff.c' to `foocoff.c', copy 7857`../include/coff/i386.h' to `../include/coff/foo.h', and add the lines 7858to `targets.c' and `Makefile.in' so that your new back end is used. 7859Alter the shapes of the structures in `../include/coff/foo.h' so that 7860they match what you need. You will probably also have to add `#ifdef's 7861to the code in `coff/internal.h' and `coffcode.h' if your version of 7862coff is too wild. 7863 7864 You can verify that your new BFD backend works quite simply by 7865building `objdump' from the `binutils' directory, and making sure that 7866its version of what's going on and your host system's idea (assuming it 7867has the pretty standard coff dump utility, usually called `att-dump' or 7868just `dump') are the same. Then clean up your code, and send what 7869you've done to Cygnus. Then your stuff will be in the next release, and 7870you won't have to keep integrating it. 7871 78723.3.2 How the coff backend works 7873-------------------------------- 7874 78753.3.2.1 File layout 7876................... 7877 7878The Coff backend is split into generic routines that are applicable to 7879any Coff target and routines that are specific to a particular target. 7880The target-specific routines are further split into ones which are 7881basically the same for all Coff targets except that they use the 7882external symbol format or use different values for certain constants. 7883 7884 The generic routines are in `coffgen.c'. These routines work for 7885any Coff target. They use some hooks into the target specific code; 7886the hooks are in a `bfd_coff_backend_data' structure, one of which 7887exists for each target. 7888 7889 The essentially similar target-specific routines are in 7890`coffcode.h'. This header file includes executable C code. The 7891various Coff targets first include the appropriate Coff header file, 7892make any special defines that are needed, and then include `coffcode.h'. 7893 7894 Some of the Coff targets then also have additional routines in the 7895target source file itself. 7896 7897 For example, `coff-i960.c' includes `coff/internal.h' and 7898`coff/i960.h'. It then defines a few constants, such as `I960', and 7899includes `coffcode.h'. Since the i960 has complex relocation types, 7900`coff-i960.c' also includes some code to manipulate the i960 relocs. 7901This code is not in `coffcode.h' because it would not be used by any 7902other target. 7903 79043.3.2.2 Bit twiddling 7905..................... 7906 7907Each flavour of coff supported in BFD has its own header file 7908describing the external layout of the structures. There is also an 7909internal description of the coff layout, in `coff/internal.h'. A major 7910function of the coff backend is swapping the bytes and twiddling the 7911bits to translate the external form of the structures into the normal 7912internal form. This is all performed in the `bfd_swap'_thing_direction 7913routines. Some elements are different sizes between different versions 7914of coff; it is the duty of the coff version specific include file to 7915override the definitions of various packing routines in `coffcode.h'. 7916E.g., the size of line number entry in coff is sometimes 16 bits, and 7917sometimes 32 bits. `#define'ing `PUT_LNSZ_LNNO' and `GET_LNSZ_LNNO' 7918will select the correct one. No doubt, some day someone will find a 7919version of coff which has a varying field size not catered to at the 7920moment. To port BFD, that person will have to add more `#defines'. 7921Three of the bit twiddling routines are exported to `gdb'; 7922`coff_swap_aux_in', `coff_swap_sym_in' and `coff_swap_lineno_in'. `GDB' 7923reads the symbol table on its own, but uses BFD to fix things up. More 7924of the bit twiddlers are exported for `gas'; `coff_swap_aux_out', 7925`coff_swap_sym_out', `coff_swap_lineno_out', `coff_swap_reloc_out', 7926`coff_swap_filehdr_out', `coff_swap_aouthdr_out', 7927`coff_swap_scnhdr_out'. `Gas' currently keeps track of all the symbol 7928table and reloc drudgery itself, thereby saving the internal BFD 7929overhead, but uses BFD to swap things on the way out, making cross 7930ports much safer. Doing so also allows BFD (and thus the linker) to 7931use the same header files as `gas', which makes one avenue to disaster 7932disappear. 7933 79343.3.2.3 Symbol reading 7935...................... 7936 7937The simple canonical form for symbols used by BFD is not rich enough to 7938keep all the information available in a coff symbol table. The back end 7939gets around this problem by keeping the original symbol table around, 7940"behind the scenes". 7941 7942 When a symbol table is requested (through a call to 7943`bfd_canonicalize_symtab'), a request gets through to 7944`coff_get_normalized_symtab'. This reads the symbol table from the coff 7945file and swaps all the structures inside into the internal form. It 7946also fixes up all the pointers in the table (represented in the file by 7947offsets from the first symbol in the table) into physical pointers to 7948elements in the new internal table. This involves some work since the 7949meanings of fields change depending upon context: a field that is a 7950pointer to another structure in the symbol table at one moment may be 7951the size in bytes of a structure at the next. Another pass is made 7952over the table. All symbols which mark file names (`C_FILE' symbols) 7953are modified so that the internal string points to the value in the 7954auxent (the real filename) rather than the normal text associated with 7955the symbol (`".file"'). 7956 7957 At this time the symbol names are moved around. Coff stores all 7958symbols less than nine characters long physically within the symbol 7959table; longer strings are kept at the end of the file in the string 7960table. This pass moves all strings into memory and replaces them with 7961pointers to the strings. 7962 7963 The symbol table is massaged once again, this time to create the 7964canonical table used by the BFD application. Each symbol is inspected 7965in turn, and a decision made (using the `sclass' field) about the 7966various flags to set in the `asymbol'. *Note Symbols::. The generated 7967canonical table shares strings with the hidden internal symbol table. 7968 7969 Any linenumbers are read from the coff file too, and attached to the 7970symbols which own the functions the linenumbers belong to. 7971 79723.3.2.4 Symbol writing 7973...................... 7974 7975Writing a symbol to a coff file which didn't come from a coff file will 7976lose any debugging information. The `asymbol' structure remembers the 7977BFD from which the symbol was taken, and on output the back end makes 7978sure that the same destination target as source target is present. 7979 7980 When the symbols have come from a coff file then all the debugging 7981information is preserved. 7982 7983 Symbol tables are provided for writing to the back end in a vector 7984of pointers to pointers. This allows applications like the linker to 7985accumulate and output large symbol tables without having to do too much 7986byte copying. 7987 7988 This function runs through the provided symbol table and patches 7989each symbol marked as a file place holder (`C_FILE') to point to the 7990next file place holder in the list. It also marks each `offset' field 7991in the list with the offset from the first symbol of the current symbol. 7992 7993 Another function of this procedure is to turn the canonical value 7994form of BFD into the form used by coff. Internally, BFD expects symbol 7995values to be offsets from a section base; so a symbol physically at 79960x120, but in a section starting at 0x100, would have the value 0x20. 7997Coff expects symbols to contain their final value, so symbols have 7998their values changed at this point to reflect their sum with their 7999owning section. This transformation uses the `output_section' field of 8000the `asymbol''s `asection' *Note Sections::. 8001 8002 * `coff_mangle_symbols' 8003 This routine runs though the provided symbol table and uses the 8004offsets generated by the previous pass and the pointers generated when 8005the symbol table was read in to create the structured hierarchy 8006required by coff. It changes each pointer to a symbol into the index 8007into the symbol table of the asymbol. 8008 8009 * `coff_write_symbols' 8010 This routine runs through the symbol table and patches up the 8011symbols from their internal form into the coff way, calls the bit 8012twiddlers, and writes out the table to the file. 8013 80143.3.2.5 `coff_symbol_type' 8015.......................... 8016 8017*Description* 8018The hidden information for an `asymbol' is described in a 8019`combined_entry_type': 8020 8021 8022 typedef struct coff_ptr_struct 8023 { 8024 /* Remembers the offset from the first symbol in the file for 8025 this symbol. Generated by coff_renumber_symbols. */ 8026 unsigned int offset; 8027 8028 /* Should the value of this symbol be renumbered. Used for 8029 XCOFF C_BSTAT symbols. Set by coff_slurp_symbol_table. */ 8030 unsigned int fix_value : 1; 8031 8032 /* Should the tag field of this symbol be renumbered. 8033 Created by coff_pointerize_aux. */ 8034 unsigned int fix_tag : 1; 8035 8036 /* Should the endidx field of this symbol be renumbered. 8037 Created by coff_pointerize_aux. */ 8038 unsigned int fix_end : 1; 8039 8040 /* Should the x_csect.x_scnlen field be renumbered. 8041 Created by coff_pointerize_aux. */ 8042 unsigned int fix_scnlen : 1; 8043 8044 /* Fix up an XCOFF C_BINCL/C_EINCL symbol. The value is the 8045 index into the line number entries. Set by coff_slurp_symbol_table. */ 8046 unsigned int fix_line : 1; 8047 8048 /* The container for the symbol structure as read and translated 8049 from the file. */ 8050 union 8051 { 8052 union internal_auxent auxent; 8053 struct internal_syment syment; 8054 } u; 8055 } combined_entry_type; 8056 8057 8058 /* Each canonical asymbol really looks like this: */ 8059 8060 typedef struct coff_symbol_struct 8061 { 8062 /* The actual symbol which the rest of BFD works with */ 8063 asymbol symbol; 8064 8065 /* A pointer to the hidden information for this symbol */ 8066 combined_entry_type *native; 8067 8068 /* A pointer to the linenumber information for this symbol */ 8069 struct lineno_cache_entry *lineno; 8070 8071 /* Have the line numbers been relocated yet ? */ 8072 bfd_boolean done_lineno; 8073 } coff_symbol_type; 8074 80753.3.2.6 `bfd_coff_backend_data' 8076............................... 8077 8078 /* COFF symbol classifications. */ 8079 8080 enum coff_symbol_classification 8081 { 8082 /* Global symbol. */ 8083 COFF_SYMBOL_GLOBAL, 8084 /* Common symbol. */ 8085 COFF_SYMBOL_COMMON, 8086 /* Undefined symbol. */ 8087 COFF_SYMBOL_UNDEFINED, 8088 /* Local symbol. */ 8089 COFF_SYMBOL_LOCAL, 8090 /* PE section symbol. */ 8091 COFF_SYMBOL_PE_SECTION 8092 }; 8093Special entry points for gdb to swap in coff symbol table parts: 8094 typedef struct 8095 { 8096 void (*_bfd_coff_swap_aux_in) 8097 (bfd *, void *, int, int, int, int, void *); 8098 8099 void (*_bfd_coff_swap_sym_in) 8100 (bfd *, void *, void *); 8101 8102 void (*_bfd_coff_swap_lineno_in) 8103 (bfd *, void *, void *); 8104 8105 unsigned int (*_bfd_coff_swap_aux_out) 8106 (bfd *, void *, int, int, int, int, void *); 8107 8108 unsigned int (*_bfd_coff_swap_sym_out) 8109 (bfd *, void *, void *); 8110 8111 unsigned int (*_bfd_coff_swap_lineno_out) 8112 (bfd *, void *, void *); 8113 8114 unsigned int (*_bfd_coff_swap_reloc_out) 8115 (bfd *, void *, void *); 8116 8117 unsigned int (*_bfd_coff_swap_filehdr_out) 8118 (bfd *, void *, void *); 8119 8120 unsigned int (*_bfd_coff_swap_aouthdr_out) 8121 (bfd *, void *, void *); 8122 8123 unsigned int (*_bfd_coff_swap_scnhdr_out) 8124 (bfd *, void *, void *); 8125 8126 unsigned int _bfd_filhsz; 8127 unsigned int _bfd_aoutsz; 8128 unsigned int _bfd_scnhsz; 8129 unsigned int _bfd_symesz; 8130 unsigned int _bfd_auxesz; 8131 unsigned int _bfd_relsz; 8132 unsigned int _bfd_linesz; 8133 unsigned int _bfd_filnmlen; 8134 bfd_boolean _bfd_coff_long_filenames; 8135 bfd_boolean _bfd_coff_long_section_names; 8136 unsigned int _bfd_coff_default_section_alignment_power; 8137 bfd_boolean _bfd_coff_force_symnames_in_strings; 8138 unsigned int _bfd_coff_debug_string_prefix_length; 8139 8140 void (*_bfd_coff_swap_filehdr_in) 8141 (bfd *, void *, void *); 8142 8143 void (*_bfd_coff_swap_aouthdr_in) 8144 (bfd *, void *, void *); 8145 8146 void (*_bfd_coff_swap_scnhdr_in) 8147 (bfd *, void *, void *); 8148 8149 void (*_bfd_coff_swap_reloc_in) 8150 (bfd *abfd, void *, void *); 8151 8152 bfd_boolean (*_bfd_coff_bad_format_hook) 8153 (bfd *, void *); 8154 8155 bfd_boolean (*_bfd_coff_set_arch_mach_hook) 8156 (bfd *, void *); 8157 8158 void * (*_bfd_coff_mkobject_hook) 8159 (bfd *, void *, void *); 8160 8161 bfd_boolean (*_bfd_styp_to_sec_flags_hook) 8162 (bfd *, void *, const char *, asection *, flagword *); 8163 8164 void (*_bfd_set_alignment_hook) 8165 (bfd *, asection *, void *); 8166 8167 bfd_boolean (*_bfd_coff_slurp_symbol_table) 8168 (bfd *); 8169 8170 bfd_boolean (*_bfd_coff_symname_in_debug) 8171 (bfd *, struct internal_syment *); 8172 8173 bfd_boolean (*_bfd_coff_pointerize_aux_hook) 8174 (bfd *, combined_entry_type *, combined_entry_type *, 8175 unsigned int, combined_entry_type *); 8176 8177 bfd_boolean (*_bfd_coff_print_aux) 8178 (bfd *, FILE *, combined_entry_type *, combined_entry_type *, 8179 combined_entry_type *, unsigned int); 8180 8181 void (*_bfd_coff_reloc16_extra_cases) 8182 (bfd *, struct bfd_link_info *, struct bfd_link_order *, arelent *, 8183 bfd_byte *, unsigned int *, unsigned int *); 8184 8185 int (*_bfd_coff_reloc16_estimate) 8186 (bfd *, asection *, arelent *, unsigned int, 8187 struct bfd_link_info *); 8188 8189 enum coff_symbol_classification (*_bfd_coff_classify_symbol) 8190 (bfd *, struct internal_syment *); 8191 8192 bfd_boolean (*_bfd_coff_compute_section_file_positions) 8193 (bfd *); 8194 8195 bfd_boolean (*_bfd_coff_start_final_link) 8196 (bfd *, struct bfd_link_info *); 8197 8198 bfd_boolean (*_bfd_coff_relocate_section) 8199 (bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *, 8200 struct internal_reloc *, struct internal_syment *, asection **); 8201 8202 reloc_howto_type *(*_bfd_coff_rtype_to_howto) 8203 (bfd *, asection *, struct internal_reloc *, 8204 struct coff_link_hash_entry *, struct internal_syment *, 8205 bfd_vma *); 8206 8207 bfd_boolean (*_bfd_coff_adjust_symndx) 8208 (bfd *, struct bfd_link_info *, bfd *, asection *, 8209 struct internal_reloc *, bfd_boolean *); 8210 8211 bfd_boolean (*_bfd_coff_link_add_one_symbol) 8212 (struct bfd_link_info *, bfd *, const char *, flagword, 8213 asection *, bfd_vma, const char *, bfd_boolean, bfd_boolean, 8214 struct bfd_link_hash_entry **); 8215 8216 bfd_boolean (*_bfd_coff_link_output_has_begun) 8217 (bfd *, struct coff_final_link_info *); 8218 8219 bfd_boolean (*_bfd_coff_final_link_postscript) 8220 (bfd *, struct coff_final_link_info *); 8221 8222 } bfd_coff_backend_data; 8223 8224 #define coff_backend_info(abfd) \ 8225 ((bfd_coff_backend_data *) (abfd)->xvec->backend_data) 8226 8227 #define bfd_coff_swap_aux_in(a,e,t,c,ind,num,i) \ 8228 ((coff_backend_info (a)->_bfd_coff_swap_aux_in) (a,e,t,c,ind,num,i)) 8229 8230 #define bfd_coff_swap_sym_in(a,e,i) \ 8231 ((coff_backend_info (a)->_bfd_coff_swap_sym_in) (a,e,i)) 8232 8233 #define bfd_coff_swap_lineno_in(a,e,i) \ 8234 ((coff_backend_info ( a)->_bfd_coff_swap_lineno_in) (a,e,i)) 8235 8236 #define bfd_coff_swap_reloc_out(abfd, i, o) \ 8237 ((coff_backend_info (abfd)->_bfd_coff_swap_reloc_out) (abfd, i, o)) 8238 8239 #define bfd_coff_swap_lineno_out(abfd, i, o) \ 8240 ((coff_backend_info (abfd)->_bfd_coff_swap_lineno_out) (abfd, i, o)) 8241 8242 #define bfd_coff_swap_aux_out(a,i,t,c,ind,num,o) \ 8243 ((coff_backend_info (a)->_bfd_coff_swap_aux_out) (a,i,t,c,ind,num,o)) 8244 8245 #define bfd_coff_swap_sym_out(abfd, i,o) \ 8246 ((coff_backend_info (abfd)->_bfd_coff_swap_sym_out) (abfd, i, o)) 8247 8248 #define bfd_coff_swap_scnhdr_out(abfd, i,o) \ 8249 ((coff_backend_info (abfd)->_bfd_coff_swap_scnhdr_out) (abfd, i, o)) 8250 8251 #define bfd_coff_swap_filehdr_out(abfd, i,o) \ 8252 ((coff_backend_info (abfd)->_bfd_coff_swap_filehdr_out) (abfd, i, o)) 8253 8254 #define bfd_coff_swap_aouthdr_out(abfd, i,o) \ 8255 ((coff_backend_info (abfd)->_bfd_coff_swap_aouthdr_out) (abfd, i, o)) 8256 8257 #define bfd_coff_filhsz(abfd) (coff_backend_info (abfd)->_bfd_filhsz) 8258 #define bfd_coff_aoutsz(abfd) (coff_backend_info (abfd)->_bfd_aoutsz) 8259 #define bfd_coff_scnhsz(abfd) (coff_backend_info (abfd)->_bfd_scnhsz) 8260 #define bfd_coff_symesz(abfd) (coff_backend_info (abfd)->_bfd_symesz) 8261 #define bfd_coff_auxesz(abfd) (coff_backend_info (abfd)->_bfd_auxesz) 8262 #define bfd_coff_relsz(abfd) (coff_backend_info (abfd)->_bfd_relsz) 8263 #define bfd_coff_linesz(abfd) (coff_backend_info (abfd)->_bfd_linesz) 8264 #define bfd_coff_filnmlen(abfd) (coff_backend_info (abfd)->_bfd_filnmlen) 8265 #define bfd_coff_long_filenames(abfd) \ 8266 (coff_backend_info (abfd)->_bfd_coff_long_filenames) 8267 #define bfd_coff_long_section_names(abfd) \ 8268 (coff_backend_info (abfd)->_bfd_coff_long_section_names) 8269 #define bfd_coff_default_section_alignment_power(abfd) \ 8270 (coff_backend_info (abfd)->_bfd_coff_default_section_alignment_power) 8271 #define bfd_coff_swap_filehdr_in(abfd, i,o) \ 8272 ((coff_backend_info (abfd)->_bfd_coff_swap_filehdr_in) (abfd, i, o)) 8273 8274 #define bfd_coff_swap_aouthdr_in(abfd, i,o) \ 8275 ((coff_backend_info (abfd)->_bfd_coff_swap_aouthdr_in) (abfd, i, o)) 8276 8277 #define bfd_coff_swap_scnhdr_in(abfd, i,o) \ 8278 ((coff_backend_info (abfd)->_bfd_coff_swap_scnhdr_in) (abfd, i, o)) 8279 8280 #define bfd_coff_swap_reloc_in(abfd, i, o) \ 8281 ((coff_backend_info (abfd)->_bfd_coff_swap_reloc_in) (abfd, i, o)) 8282 8283 #define bfd_coff_bad_format_hook(abfd, filehdr) \ 8284 ((coff_backend_info (abfd)->_bfd_coff_bad_format_hook) (abfd, filehdr)) 8285 8286 #define bfd_coff_set_arch_mach_hook(abfd, filehdr)\ 8287 ((coff_backend_info (abfd)->_bfd_coff_set_arch_mach_hook) (abfd, filehdr)) 8288 #define bfd_coff_mkobject_hook(abfd, filehdr, aouthdr)\ 8289 ((coff_backend_info (abfd)->_bfd_coff_mkobject_hook)\ 8290 (abfd, filehdr, aouthdr)) 8291 8292 #define bfd_coff_styp_to_sec_flags_hook(abfd, scnhdr, name, section, flags_ptr)\ 8293 ((coff_backend_info (abfd)->_bfd_styp_to_sec_flags_hook)\ 8294 (abfd, scnhdr, name, section, flags_ptr)) 8295 8296 #define bfd_coff_set_alignment_hook(abfd, sec, scnhdr)\ 8297 ((coff_backend_info (abfd)->_bfd_set_alignment_hook) (abfd, sec, scnhdr)) 8298 8299 #define bfd_coff_slurp_symbol_table(abfd)\ 8300 ((coff_backend_info (abfd)->_bfd_coff_slurp_symbol_table) (abfd)) 8301 8302 #define bfd_coff_symname_in_debug(abfd, sym)\ 8303 ((coff_backend_info (abfd)->_bfd_coff_symname_in_debug) (abfd, sym)) 8304 8305 #define bfd_coff_force_symnames_in_strings(abfd)\ 8306 (coff_backend_info (abfd)->_bfd_coff_force_symnames_in_strings) 8307 8308 #define bfd_coff_debug_string_prefix_length(abfd)\ 8309 (coff_backend_info (abfd)->_bfd_coff_debug_string_prefix_length) 8310 8311 #define bfd_coff_print_aux(abfd, file, base, symbol, aux, indaux)\ 8312 ((coff_backend_info (abfd)->_bfd_coff_print_aux)\ 8313 (abfd, file, base, symbol, aux, indaux)) 8314 8315 #define bfd_coff_reloc16_extra_cases(abfd, link_info, link_order,\ 8316 reloc, data, src_ptr, dst_ptr)\ 8317 ((coff_backend_info (abfd)->_bfd_coff_reloc16_extra_cases)\ 8318 (abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr)) 8319 8320 #define bfd_coff_reloc16_estimate(abfd, section, reloc, shrink, link_info)\ 8321 ((coff_backend_info (abfd)->_bfd_coff_reloc16_estimate)\ 8322 (abfd, section, reloc, shrink, link_info)) 8323 8324 #define bfd_coff_classify_symbol(abfd, sym)\ 8325 ((coff_backend_info (abfd)->_bfd_coff_classify_symbol)\ 8326 (abfd, sym)) 8327 8328 #define bfd_coff_compute_section_file_positions(abfd)\ 8329 ((coff_backend_info (abfd)->_bfd_coff_compute_section_file_positions)\ 8330 (abfd)) 8331 8332 #define bfd_coff_start_final_link(obfd, info)\ 8333 ((coff_backend_info (obfd)->_bfd_coff_start_final_link)\ 8334 (obfd, info)) 8335 #define bfd_coff_relocate_section(obfd,info,ibfd,o,con,rel,isyms,secs)\ 8336 ((coff_backend_info (ibfd)->_bfd_coff_relocate_section)\ 8337 (obfd, info, ibfd, o, con, rel, isyms, secs)) 8338 #define bfd_coff_rtype_to_howto(abfd, sec, rel, h, sym, addendp)\ 8339 ((coff_backend_info (abfd)->_bfd_coff_rtype_to_howto)\ 8340 (abfd, sec, rel, h, sym, addendp)) 8341 #define bfd_coff_adjust_symndx(obfd, info, ibfd, sec, rel, adjustedp)\ 8342 ((coff_backend_info (abfd)->_bfd_coff_adjust_symndx)\ 8343 (obfd, info, ibfd, sec, rel, adjustedp)) 8344 #define bfd_coff_link_add_one_symbol(info, abfd, name, flags, section,\ 8345 value, string, cp, coll, hashp)\ 8346 ((coff_backend_info (abfd)->_bfd_coff_link_add_one_symbol)\ 8347 (info, abfd, name, flags, section, value, string, cp, coll, hashp)) 8348 8349 #define bfd_coff_link_output_has_begun(a,p) \ 8350 ((coff_backend_info (a)->_bfd_coff_link_output_has_begun) (a, p)) 8351 #define bfd_coff_final_link_postscript(a,p) \ 8352 ((coff_backend_info (a)->_bfd_coff_final_link_postscript) (a, p)) 8353 83543.3.2.7 Writing relocations 8355........................... 8356 8357To write relocations, the back end steps though the canonical 8358relocation table and create an `internal_reloc'. The symbol index to 8359use is removed from the `offset' field in the symbol table supplied. 8360The address comes directly from the sum of the section base address and 8361the relocation offset; the type is dug directly from the howto field. 8362Then the `internal_reloc' is swapped into the shape of an 8363`external_reloc' and written out to disk. 8364 83653.3.2.8 Reading linenumbers 8366........................... 8367 8368Creating the linenumber table is done by reading in the entire coff 8369linenumber table, and creating another table for internal use. 8370 8371 A coff linenumber table is structured so that each function is 8372marked as having a line number of 0. Each line within the function is 8373an offset from the first line in the function. The base of the line 8374number information for the table is stored in the symbol associated 8375with the function. 8376 8377 Note: The PE format uses line number 0 for a flag indicating a new 8378source file. 8379 8380 The information is copied from the external to the internal table, 8381and each symbol which marks a function is marked by pointing its... 8382 8383 How does this work ? 8384 83853.3.2.9 Reading relocations 8386........................... 8387 8388Coff relocations are easily transformed into the internal BFD form 8389(`arelent'). 8390 8391 Reading a coff relocation table is done in the following stages: 8392 8393 * Read the entire coff relocation table into memory. 8394 8395 * Process each relocation in turn; first swap it from the external 8396 to the internal form. 8397 8398 * Turn the symbol referenced in the relocation's symbol index into a 8399 pointer into the canonical symbol table. This table is the same 8400 as the one returned by a call to `bfd_canonicalize_symtab'. The 8401 back end will call that routine and save the result if a 8402 canonicalization hasn't been done. 8403 8404 * The reloc index is turned into a pointer to a howto structure, in 8405 a back end specific way. For instance, the 386 and 960 use the 8406 `r_type' to directly produce an index into a howto table vector; 8407 the 88k subtracts a number from the `r_type' field and creates an 8408 addend field. 8409 8410 8411File: bfd.info, Node: elf, Next: mmo, Prev: coff, Up: BFD back ends 8412 84133.4 ELF backends 8414================ 8415 8416BFD support for ELF formats is being worked on. Currently, the best 8417supported back ends are for sparc and i386 (running svr4 or Solaris 2). 8418 8419 Documentation of the internals of the support code still needs to be 8420written. The code is changing quickly enough that we haven't bothered 8421yet. 8422 84233.4.0.1 `bfd_elf_find_section' 8424.............................. 8425 8426*Synopsis* 8427 struct elf_internal_shdr *bfd_elf_find_section (bfd *abfd, char *name); 8428 *Description* 8429Helper functions for GDB to locate the string tables. Since BFD hides 8430string tables from callers, GDB needs to use an internal hook to find 8431them. Sun's .stabstr, in particular, isn't even pointed to by the 8432.stab section, so ordinary mechanisms wouldn't work to find it, even if 8433we had some. 8434 8435 8436File: bfd.info, Node: mmo, Prev: elf, Up: BFD back ends 8437 84383.5 mmo backend 8439=============== 8440 8441The mmo object format is used exclusively together with Professor 8442Donald E. Knuth's educational 64-bit processor MMIX. The simulator 8443`mmix' which is available at 8444`http://www-cs-faculty.stanford.edu/~knuth/programs/mmix.tar.gz' 8445understands this format. That package also includes a combined 8446assembler and linker called `mmixal'. The mmo format has no advantages 8447feature-wise compared to e.g. ELF. It is a simple non-relocatable 8448object format with no support for archives or debugging information, 8449except for symbol value information and line numbers (which is not yet 8450implemented in BFD). See 8451`http://www-cs-faculty.stanford.edu/~knuth/mmix.html' for more 8452information about MMIX. The ELF format is used for intermediate object 8453files in the BFD implementation. 8454 8455* Menu: 8456 8457* File layout:: 8458* Symbol-table:: 8459* mmo section mapping:: 8460 8461 8462File: bfd.info, Node: File layout, Next: Symbol-table, Prev: mmo, Up: mmo 8463 84643.5.1 File layout 8465----------------- 8466 8467The mmo file contents is not partitioned into named sections as with 8468e.g. ELF. Memory areas is formed by specifying the location of the 8469data that follows. Only the memory area `0x0000...00' to `0x01ff...ff' 8470is executable, so it is used for code (and constants) and the area 8471`0x2000...00' to `0x20ff...ff' is used for writable data. *Note mmo 8472section mapping::. 8473 8474 There is provision for specifying "special data" of 65536 different 8475types. We use type 80 (decimal), arbitrarily chosen the same as the 8476ELF `e_machine' number for MMIX, filling it with section information 8477normally found in ELF objects. *Note mmo section mapping::. 8478 8479 Contents is entered as 32-bit words, xor:ed over previous contents, 8480always zero-initialized. A word that starts with the byte `0x98' forms 8481a command called a `lopcode', where the next byte distinguished between 8482the thirteen lopcodes. The two remaining bytes, called the `Y' and `Z' 8483fields, or the `YZ' field (a 16-bit big-endian number), are used for 8484various purposes different for each lopcode. As documented in 8485`http://www-cs-faculty.stanford.edu/~knuth/mmixal-intro.ps.gz', the 8486lopcodes are: 8487 8488`lop_quote' 8489 0x98000001. The next word is contents, regardless of whether it 8490 starts with 0x98 or not. 8491 8492`lop_loc' 8493 0x9801YYZZ, where `Z' is 1 or 2. This is a location directive, 8494 setting the location for the next data to the next 32-bit word 8495 (for Z = 1) or 64-bit word (for Z = 2), plus Y * 2^56. Normally 8496 `Y' is 0 for the text segment and 2 for the data segment. 8497 8498`lop_skip' 8499 0x9802YYZZ. Increase the current location by `YZ' bytes. 8500 8501`lop_fixo' 8502 0x9803YYZZ, where `Z' is 1 or 2. Store the current location as 64 8503 bits into the location pointed to by the next 32-bit (Z = 1) or 8504 64-bit (Z = 2) word, plus Y * 2^56. 8505 8506`lop_fixr' 8507 0x9804YYZZ. `YZ' is stored into the current location plus 2 - 4 * 8508 YZ. 8509 8510`lop_fixrx' 8511 0x980500ZZ. `Z' is 16 or 24. A value `L' derived from the 8512 following 32-bit word are used in a manner similar to `YZ' in 8513 lop_fixr: it is xor:ed into the current location minus 4 * L. The 8514 first byte of the word is 0 or 1. If it is 1, then L = (LOWEST 24 8515 BITS OF WORD) - 2^Z, if 0, then L = (LOWEST 24 BITS OF WORD). 8516 8517`lop_file' 8518 0x9806YYZZ. `Y' is the file number, `Z' is count of 32-bit words. 8519 Set the file number to `Y' and the line counter to 0. The next Z 8520 * 4 bytes contain the file name, padded with zeros if the count is 8521 not a multiple of four. The same `Y' may occur multiple times, 8522 but `Z' must be 0 for all but the first occurrence. 8523 8524`lop_line' 8525 0x9807YYZZ. `YZ' is the line number. Together with lop_file, it 8526 forms the source location for the next 32-bit word. Note that for 8527 each non-lopcode 32-bit word, line numbers are assumed incremented 8528 by one. 8529 8530`lop_spec' 8531 0x9808YYZZ. `YZ' is the type number. Data until the next lopcode 8532 other than lop_quote forms special data of type `YZ'. *Note mmo 8533 section mapping::. 8534 8535 Other types than 80, (or type 80 with a content that does not 8536 parse) is stored in sections named `.MMIX.spec_data.N' where N is 8537 the `YZ'-type. The flags for such a sections say not to allocate 8538 or load the data. The vma is 0. Contents of multiple occurrences 8539 of special data N is concatenated to the data of the previous 8540 lop_spec Ns. The location in data or code at which the lop_spec 8541 occurred is lost. 8542 8543`lop_pre' 8544 0x980901ZZ. The first lopcode in a file. The `Z' field forms the 8545 length of header information in 32-bit words, where the first word 8546 tells the time in seconds since `00:00:00 GMT Jan 1 1970'. 8547 8548`lop_post' 8549 0x980a00ZZ. Z > 32. This lopcode follows after all 8550 content-generating lopcodes in a program. The `Z' field denotes 8551 the value of `rG' at the beginning of the program. The following 8552 256 - Z big-endian 64-bit words are loaded into global registers 8553 `$G' ... `$255'. 8554 8555`lop_stab' 8556 0x980b0000. The next-to-last lopcode in a program. Must follow 8557 immediately after the lop_post lopcode and its data. After this 8558 lopcode follows all symbols in a compressed format (*note 8559 Symbol-table::). 8560 8561`lop_end' 8562 0x980cYYZZ. The last lopcode in a program. It must follow the 8563 lop_stab lopcode and its data. The `YZ' field contains the number 8564 of 32-bit words of symbol table information after the preceding 8565 lop_stab lopcode. 8566 8567 Note that the lopcode "fixups"; `lop_fixr', `lop_fixrx' and 8568`lop_fixo' are not generated by BFD, but are handled. They are 8569generated by `mmixal'. 8570 8571 This trivial one-label, one-instruction file: 8572 8573 :Main TRAP 1,2,3 8574 8575 can be represented this way in mmo: 8576 8577 0x98090101 - lop_pre, one 32-bit word with timestamp. 8578 <timestamp> 8579 0x98010002 - lop_loc, text segment, using a 64-bit address. 8580 Note that mmixal does not emit this for the file above. 8581 0x00000000 - Address, high 32 bits. 8582 0x00000000 - Address, low 32 bits. 8583 0x98060002 - lop_file, 2 32-bit words for file-name. 8584 0x74657374 - "test" 8585 0x2e730000 - ".s\0\0" 8586 0x98070001 - lop_line, line 1. 8587 0x00010203 - TRAP 1,2,3 8588 0x980a00ff - lop_post, setting $255 to 0. 8589 0x00000000 8590 0x00000000 8591 0x980b0000 - lop_stab for ":Main" = 0, serial 1. 8592 0x203a4040 *Note Symbol-table::. 8593 0x10404020 8594 0x4d206120 8595 0x69016e00 8596 0x81000000 8597 0x980c0005 - lop_end; symbol table contained five 32-bit words. 8598 8599 8600File: bfd.info, Node: Symbol-table, Next: mmo section mapping, Prev: File layout, Up: mmo 8601 86023.5.2 Symbol table format 8603------------------------- 8604 8605From mmixal.w (or really, the generated mmixal.tex) in 8606`http://www-cs-faculty.stanford.edu/~knuth/programs/mmix.tar.gz'): 8607"Symbols are stored and retrieved by means of a `ternary search trie', 8608following ideas of Bentley and Sedgewick. (See ACM-SIAM Symp. on 8609Discrete Algorithms `8' (1997), 360-369; R.Sedgewick, `Algorithms in C' 8610(Reading, Mass. Addison-Wesley, 1998), `15.4'.) Each trie node stores 8611a character, and there are branches to subtries for the cases where a 8612given character is less than, equal to, or greater than the character 8613in the trie. There also is a pointer to a symbol table entry if a 8614symbol ends at the current node." 8615 8616 So it's a tree encoded as a stream of bytes. The stream of bytes 8617acts on a single virtual global symbol, adding and removing characters 8618and signalling complete symbol points. Here, we read the stream and 8619create symbols at the completion points. 8620 8621 First, there's a control byte `m'. If any of the listed bits in `m' 8622is nonzero, we execute what stands at the right, in the listed order: 8623 8624 (MMO3_LEFT) 8625 0x40 - Traverse left trie. 8626 (Read a new command byte and recurse.) 8627 8628 (MMO3_SYMBITS) 8629 0x2f - Read the next byte as a character and store it in the 8630 current character position; increment character position. 8631 Test the bits of `m': 8632 8633 (MMO3_WCHAR) 8634 0x80 - The character is 16-bit (so read another byte, 8635 merge into current character. 8636 8637 (MMO3_TYPEBITS) 8638 0xf - We have a complete symbol; parse the type, value 8639 and serial number and do what should be done 8640 with a symbol. The type and length information 8641 is in j = (m & 0xf). 8642 8643 (MMO3_REGQUAL_BITS) 8644 j == 0xf: A register variable. The following 8645 byte tells which register. 8646 j <= 8: An absolute symbol. Read j bytes as the 8647 big-endian number the symbol equals. 8648 A j = 2 with two zero bytes denotes an 8649 unknown symbol. 8650 j > 8: As with j <= 8, but add (0x20 << 56) 8651 to the value in the following j - 8 8652 bytes. 8653 8654 Then comes the serial number, as a variant of 8655 uleb128, but better named ubeb128: 8656 Read bytes and shift the previous value left 7 8657 (multiply by 128). Add in the new byte, repeat 8658 until a byte has bit 7 set. The serial number 8659 is the computed value minus 128. 8660 8661 (MMO3_MIDDLE) 8662 0x20 - Traverse middle trie. (Read a new command byte 8663 and recurse.) Decrement character position. 8664 8665 (MMO3_RIGHT) 8666 0x10 - Traverse right trie. (Read a new command byte and 8667 recurse.) 8668 8669 Let's look again at the `lop_stab' for the trivial file (*note File 8670layout::). 8671 8672 0x980b0000 - lop_stab for ":Main" = 0, serial 1. 8673 0x203a4040 8674 0x10404020 8675 0x4d206120 8676 0x69016e00 8677 0x81000000 8678 8679 This forms the trivial trie (note that the path between ":" and "M" 8680is redundant): 8681 8682 203a ":" 8683 40 / 8684 40 / 8685 10 \ 8686 40 / 8687 40 / 8688 204d "M" 8689 2061 "a" 8690 2069 "i" 8691 016e "n" is the last character in a full symbol, and 8692 with a value represented in one byte. 8693 00 The value is 0. 8694 81 The serial number is 1. 8695 8696 8697File: bfd.info, Node: mmo section mapping, Prev: Symbol-table, Up: mmo 8698 86993.5.3 mmo section mapping 8700------------------------- 8701 8702The implementation in BFD uses special data type 80 (decimal) to 8703encapsulate and describe named sections, containing e.g. debug 8704information. If needed, any datum in the encapsulation will be quoted 8705using lop_quote. First comes a 32-bit word holding the number of 870632-bit words containing the zero-terminated zero-padded segment name. 8707After the name there's a 32-bit word holding flags describing the 8708section type. Then comes a 64-bit big-endian word with the section 8709length (in bytes), then another with the section start address. 8710Depending on the type of section, the contents might follow, 8711zero-padded to 32-bit boundary. For a loadable section (such as data 8712or code), the contents might follow at some later point, not 8713necessarily immediately, as a lop_loc with the same start address as in 8714the section description, followed by the contents. This in effect 8715forms a descriptor that must be emitted before the actual contents. 8716Sections described this way must not overlap. 8717 8718 For areas that don't have such descriptors, synthetic sections are 8719formed by BFD. Consecutive contents in the two memory areas 8720`0x0000...00' to `0x01ff...ff' and `0x2000...00' to `0x20ff...ff' are 8721entered in sections named `.text' and `.data' respectively. If an area 8722is not otherwise described, but would together with a neighboring lower 8723area be less than `0x40000000' bytes long, it is joined with the lower 8724area and the gap is zero-filled. For other cases, a new section is 8725formed, named `.MMIX.sec.N'. Here, N is a number, a running count 8726through the mmo file, starting at 0. 8727 8728 A loadable section specified as: 8729 8730 .section secname,"ax" 8731 TETRA 1,2,3,4,-1,-2009 8732 BYTE 80 8733 8734 and linked to address `0x4', is represented by the sequence: 8735 8736 0x98080050 - lop_spec 80 8737 0x00000002 - two 32-bit words for the section name 8738 0x7365636e - "secn" 8739 0x616d6500 - "ame\0" 8740 0x00000033 - flags CODE, READONLY, LOAD, ALLOC 8741 0x00000000 - high 32 bits of section length 8742 0x0000001c - section length is 28 bytes; 6 * 4 + 1 + alignment to 32 bits 8743 0x00000000 - high 32 bits of section address 8744 0x00000004 - section address is 4 8745 0x98010002 - 64 bits with address of following data 8746 0x00000000 - high 32 bits of address 8747 0x00000004 - low 32 bits: data starts at address 4 8748 0x00000001 - 1 8749 0x00000002 - 2 8750 0x00000003 - 3 8751 0x00000004 - 4 8752 0xffffffff - -1 8753 0xfffff827 - -2009 8754 0x50000000 - 80 as a byte, padded with zeros. 8755 8756 Note that the lop_spec wrapping does not include the section 8757contents. Compare this to a non-loaded section specified as: 8758 8759 .section thirdsec 8760 TETRA 200001,100002 8761 BYTE 38,40 8762 8763 This, when linked to address `0x200000000000001c', is represented by: 8764 8765 0x98080050 - lop_spec 80 8766 0x00000002 - two 32-bit words for the section name 8767 0x7365636e - "thir" 8768 0x616d6500 - "dsec" 8769 0x00000010 - flag READONLY 8770 0x00000000 - high 32 bits of section length 8771 0x0000000c - section length is 12 bytes; 2 * 4 + 2 + alignment to 32 bits 8772 0x20000000 - high 32 bits of address 8773 0x0000001c - low 32 bits of address 0x200000000000001c 8774 0x00030d41 - 200001 8775 0x000186a2 - 100002 8776 0x26280000 - 38, 40 as bytes, padded with zeros 8777 8778 For the latter example, the section contents must not be loaded in 8779memory, and is therefore specified as part of the special data. The 8780address is usually unimportant but might provide information for e.g. 8781the DWARF 2 debugging format. 8782 8783 8784File: bfd.info, Node: GNU Free Documentation License, Next: BFD Index, Prev: BFD back ends, Up: Top 8785 8786Appendix A GNU Free Documentation License 8787***************************************** 8788 8789 Version 1.1, March 2000 8790 8791 Copyright (C) 2000, 2003 Free Software Foundation, Inc. 8792 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 8793 8794 Everyone is permitted to copy and distribute verbatim copies 8795 of this license document, but changing it is not allowed. 8796 8797 8798 0. PREAMBLE 8799 8800 The purpose of this License is to make a manual, textbook, or other 8801 written document "free" in the sense of freedom: to assure everyone 8802 the effective freedom to copy and redistribute it, with or without 8803 modifying it, either commercially or noncommercially. Secondarily, 8804 this License preserves for the author and publisher a way to get 8805 credit for their work, while not being considered responsible for 8806 modifications made by others. 8807 8808 This License is a kind of "copyleft", which means that derivative 8809 works of the document must themselves be free in the same sense. 8810 It complements the GNU General Public License, which is a copyleft 8811 license designed for free software. 8812 8813 We have designed this License in order to use it for manuals for 8814 free software, because free software needs free documentation: a 8815 free program should come with manuals providing the same freedoms 8816 that the software does. But this License is not limited to 8817 software manuals; it can be used for any textual work, regardless 8818 of subject matter or whether it is published as a printed book. 8819 We recommend this License principally for works whose purpose is 8820 instruction or reference. 8821 8822 8823 1. APPLICABILITY AND DEFINITIONS 8824 8825 This License applies to any manual or other work that contains a 8826 notice placed by the copyright holder saying it can be distributed 8827 under the terms of this License. The "Document", below, refers to 8828 any such manual or work. Any member of the public is a licensee, 8829 and is addressed as "you." 8830 8831 A "Modified Version" of the Document means any work containing the 8832 Document or a portion of it, either copied verbatim, or with 8833 modifications and/or translated into another language. 8834 8835 A "Secondary Section" is a named appendix or a front-matter 8836 section of the Document that deals exclusively with the 8837 relationship of the publishers or authors of the Document to the 8838 Document's overall subject (or to related matters) and contains 8839 nothing that could fall directly within that overall subject. 8840 (For example, if the Document is in part a textbook of 8841 mathematics, a Secondary Section may not explain any mathematics.) 8842 The relationship could be a matter of historical connection with 8843 the subject or with related matters, or of legal, commercial, 8844 philosophical, ethical or political position regarding them. 8845 8846 The "Invariant Sections" are certain Secondary Sections whose 8847 titles are designated, as being those of Invariant Sections, in 8848 the notice that says that the Document is released under this 8849 License. 8850 8851 The "Cover Texts" are certain short passages of text that are 8852 listed, as Front-Cover Texts or Back-Cover Texts, in the notice 8853 that says that the Document is released under this License. 8854 8855 A "Transparent" copy of the Document means a machine-readable copy, 8856 represented in a format whose specification is available to the 8857 general public, whose contents can be viewed and edited directly 8858 and straightforwardly with generic text editors or (for images 8859 composed of pixels) generic paint programs or (for drawings) some 8860 widely available drawing editor, and that is suitable for input to 8861 text formatters or for automatic translation to a variety of 8862 formats suitable for input to text formatters. A copy made in an 8863 otherwise Transparent file format whose markup has been designed 8864 to thwart or discourage subsequent modification by readers is not 8865 Transparent. A copy that is not "Transparent" is called "Opaque." 8866 8867 Examples of suitable formats for Transparent copies include plain 8868 ASCII without markup, Texinfo input format, LaTeX input format, 8869 SGML or XML using a publicly available DTD, and 8870 standard-conforming simple HTML designed for human modification. 8871 Opaque formats include PostScript, PDF, proprietary formats that 8872 can be read and edited only by proprietary word processors, SGML 8873 or XML for which the DTD and/or processing tools are not generally 8874 available, and the machine-generated HTML produced by some word 8875 processors for output purposes only. 8876 8877 The "Title Page" means, for a printed book, the title page itself, 8878 plus such following pages as are needed to hold, legibly, the 8879 material this License requires to appear in the title page. For 8880 works in formats which do not have any title page as such, "Title 8881 Page" means the text near the most prominent appearance of the 8882 work's title, preceding the beginning of the body of the text. 8883 8884 2. VERBATIM COPYING 8885 8886 You may copy and distribute the Document in any medium, either 8887 commercially or noncommercially, provided that this License, the 8888 copyright notices, and the license notice saying this License 8889 applies to the Document are reproduced in all copies, and that you 8890 add no other conditions whatsoever to those of this License. You 8891 may not use technical measures to obstruct or control the reading 8892 or further copying of the copies you make or distribute. However, 8893 you may accept compensation in exchange for copies. If you 8894 distribute a large enough number of copies you must also follow 8895 the conditions in section 3. 8896 8897 You may also lend copies, under the same conditions stated above, 8898 and you may publicly display copies. 8899 8900 3. COPYING IN QUANTITY 8901 8902 If you publish printed copies of the Document numbering more than 8903 100, and the Document's license notice requires Cover Texts, you 8904 must enclose the copies in covers that carry, clearly and legibly, 8905 all these Cover Texts: Front-Cover Texts on the front cover, and 8906 Back-Cover Texts on the back cover. Both covers must also clearly 8907 and legibly identify you as the publisher of these copies. The 8908 front cover must present the full title with all words of the 8909 title equally prominent and visible. You may add other material 8910 on the covers in addition. Copying with changes limited to the 8911 covers, as long as they preserve the title of the Document and 8912 satisfy these conditions, can be treated as verbatim copying in 8913 other respects. 8914 8915 If the required texts for either cover are too voluminous to fit 8916 legibly, you should put the first ones listed (as many as fit 8917 reasonably) on the actual cover, and continue the rest onto 8918 adjacent pages. 8919 8920 If you publish or distribute Opaque copies of the Document 8921 numbering more than 100, you must either include a 8922 machine-readable Transparent copy along with each Opaque copy, or 8923 state in or with each Opaque copy a publicly-accessible 8924 computer-network location containing a complete Transparent copy 8925 of the Document, free of added material, which the general 8926 network-using public has access to download anonymously at no 8927 charge using public-standard network protocols. If you use the 8928 latter option, you must take reasonably prudent steps, when you 8929 begin distribution of Opaque copies in quantity, to ensure that 8930 this Transparent copy will remain thus accessible at the stated 8931 location until at least one year after the last time you 8932 distribute an Opaque copy (directly or through your agents or 8933 retailers) of that edition to the public. 8934 8935 It is requested, but not required, that you contact the authors of 8936 the Document well before redistributing any large number of 8937 copies, to give them a chance to provide you with an updated 8938 version of the Document. 8939 8940 4. MODIFICATIONS 8941 8942 You may copy and distribute a Modified Version of the Document 8943 under the conditions of sections 2 and 3 above, provided that you 8944 release the Modified Version under precisely this License, with 8945 the Modified Version filling the role of the Document, thus 8946 licensing distribution and modification of the Modified Version to 8947 whoever possesses a copy of it. In addition, you must do these 8948 things in the Modified Version: 8949 8950 A. Use in the Title Page (and on the covers, if any) a title 8951 distinct from that of the Document, and from those of previous 8952 versions (which should, if there were any, be listed in the 8953 History section of the Document). You may use the same title 8954 as a previous version if the original publisher of that version 8955 gives permission. 8956 B. List on the Title Page, as authors, one or more persons or 8957 entities responsible for authorship of the modifications in the 8958 Modified Version, together with at least five of the principal 8959 authors of the Document (all of its principal authors, if it 8960 has less than five). 8961 C. State on the Title page the name of the publisher of the 8962 Modified Version, as the publisher. 8963 D. Preserve all the copyright notices of the Document. 8964 E. Add an appropriate copyright notice for your modifications 8965 adjacent to the other copyright notices. 8966 F. Include, immediately after the copyright notices, a license 8967 notice giving the public permission to use the Modified Version 8968 under the terms of this License, in the form shown in the 8969 Addendum below. 8970 G. Preserve in that license notice the full lists of Invariant 8971 Sections and required Cover Texts given in the Document's 8972 license notice. 8973 H. Include an unaltered copy of this License. 8974 I. Preserve the section entitled "History", and its title, and add 8975 to it an item stating at least the title, year, new authors, and 8976 publisher of the Modified Version as given on the Title Page. 8977 If there is no section entitled "History" in the Document, 8978 create one stating the title, year, authors, and publisher of 8979 the Document as given on its Title Page, then add an item 8980 describing the Modified Version as stated in the previous 8981 sentence. 8982 J. Preserve the network location, if any, given in the Document for 8983 public access to a Transparent copy of the Document, and 8984 likewise the network locations given in the Document for 8985 previous versions it was based on. These may be placed in the 8986 "History" section. You may omit a network location for a work 8987 that was published at least four years before the Document 8988 itself, or if the original publisher of the version it refers 8989 to gives permission. 8990 K. In any section entitled "Acknowledgements" or "Dedications", 8991 preserve the section's title, and preserve in the section all the 8992 substance and tone of each of the contributor acknowledgements 8993 and/or dedications given therein. 8994 L. Preserve all the Invariant Sections of the Document, 8995 unaltered in their text and in their titles. Section numbers 8996 or the equivalent are not considered part of the section titles. 8997 M. Delete any section entitled "Endorsements." Such a section 8998 may not be included in the Modified Version. 8999 N. Do not retitle any existing section as "Endorsements" or to 9000 conflict in title with any Invariant Section. 9001 9002 If the Modified Version includes new front-matter sections or 9003 appendices that qualify as Secondary Sections and contain no 9004 material copied from the Document, you may at your option 9005 designate some or all of these sections as invariant. To do this, 9006 add their titles to the list of Invariant Sections in the Modified 9007 Version's license notice. These titles must be distinct from any 9008 other section titles. 9009 9010 You may add a section entitled "Endorsements", provided it contains 9011 nothing but endorsements of your Modified Version by various 9012 parties-for example, statements of peer review or that the text has 9013 been approved by an organization as the authoritative definition 9014 of a standard. 9015 9016 You may add a passage of up to five words as a Front-Cover Text, 9017 and a passage of up to 25 words as a Back-Cover Text, to the end 9018 of the list of Cover Texts in the Modified Version. Only one 9019 passage of Front-Cover Text and one of Back-Cover Text may be 9020 added by (or through arrangements made by) any one entity. If the 9021 Document already includes a cover text for the same cover, 9022 previously added by you or by arrangement made by the same entity 9023 you are acting on behalf of, you may not add another; but you may 9024 replace the old one, on explicit permission from the previous 9025 publisher that added the old one. 9026 9027 The author(s) and publisher(s) of the Document do not by this 9028 License give permission to use their names for publicity for or to 9029 assert or imply endorsement of any Modified Version. 9030 9031 5. COMBINING DOCUMENTS 9032 9033 You may combine the Document with other documents released under 9034 this License, under the terms defined in section 4 above for 9035 modified versions, provided that you include in the combination 9036 all of the Invariant Sections of all of the original documents, 9037 unmodified, and list them all as Invariant Sections of your 9038 combined work in its license notice. 9039 9040 The combined work need only contain one copy of this License, and 9041 multiple identical Invariant Sections may be replaced with a single 9042 copy. If there are multiple Invariant Sections with the same name 9043 but different contents, make the title of each such section unique 9044 by adding at the end of it, in parentheses, the name of the 9045 original author or publisher of that section if known, or else a 9046 unique number. Make the same adjustment to the section titles in 9047 the list of Invariant Sections in the license notice of the 9048 combined work. 9049 9050 In the combination, you must combine any sections entitled 9051 "History" in the various original documents, forming one section 9052 entitled "History"; likewise combine any sections entitled 9053 "Acknowledgements", and any sections entitled "Dedications." You 9054 must delete all sections entitled "Endorsements." 9055 9056 6. COLLECTIONS OF DOCUMENTS 9057 9058 You may make a collection consisting of the Document and other 9059 documents released under this License, and replace the individual 9060 copies of this License in the various documents with a single copy 9061 that is included in the collection, provided that you follow the 9062 rules of this License for verbatim copying of each of the 9063 documents in all other respects. 9064 9065 You may extract a single document from such a collection, and 9066 distribute it individually under this License, provided you insert 9067 a copy of this License into the extracted document, and follow 9068 this License in all other respects regarding verbatim copying of 9069 that document. 9070 9071 7. AGGREGATION WITH INDEPENDENT WORKS 9072 9073 A compilation of the Document or its derivatives with other 9074 separate and independent documents or works, in or on a volume of 9075 a storage or distribution medium, does not as a whole count as a 9076 Modified Version of the Document, provided no compilation 9077 copyright is claimed for the compilation. Such a compilation is 9078 called an "aggregate", and this License does not apply to the 9079 other self-contained works thus compiled with the Document, on 9080 account of their being thus compiled, if they are not themselves 9081 derivative works of the Document. 9082 9083 If the Cover Text requirement of section 3 is applicable to these 9084 copies of the Document, then if the Document is less than one 9085 quarter of the entire aggregate, the Document's Cover Texts may be 9086 placed on covers that surround only the Document within the 9087 aggregate. Otherwise they must appear on covers around the whole 9088 aggregate. 9089 9090 8. TRANSLATION 9091 9092 Translation is considered a kind of modification, so you may 9093 distribute translations of the Document under the terms of section 9094 4. Replacing Invariant Sections with translations requires special 9095 permission from their copyright holders, but you may include 9096 translations of some or all Invariant Sections in addition to the 9097 original versions of these Invariant Sections. You may include a 9098 translation of this License provided that you also include the 9099 original English version of this License. In case of a 9100 disagreement between the translation and the original English 9101 version of this License, the original English version will prevail. 9102 9103 9. TERMINATION 9104 9105 You may not copy, modify, sublicense, or distribute the Document 9106 except as expressly provided for under this License. Any other 9107 attempt to copy, modify, sublicense or distribute the Document is 9108 void, and will automatically terminate your rights under this 9109 License. However, parties who have received copies, or rights, 9110 from you under this License will not have their licenses 9111 terminated so long as such parties remain in full compliance. 9112 9113 10. FUTURE REVISIONS OF THIS LICENSE 9114 9115 The Free Software Foundation may publish new, revised versions of 9116 the GNU Free Documentation License from time to time. Such new 9117 versions will be similar in spirit to the present version, but may 9118 differ in detail to address new problems or concerns. See 9119 http://www.gnu.org/copyleft/. 9120 9121 Each version of the License is given a distinguishing version 9122 number. If the Document specifies that a particular numbered 9123 version of this License "or any later version" applies to it, you 9124 have the option of following the terms and conditions either of 9125 that specified version or of any later version that has been 9126 published (not as a draft) by the Free Software Foundation. If 9127 the Document does not specify a version number of this License, 9128 you may choose any version ever published (not as a draft) by the 9129 Free Software Foundation. 9130 9131 9132ADDENDUM: How to use this License for your documents 9133==================================================== 9134 9135To use this License in a document you have written, include a copy of 9136the License in the document and put the following copyright and license 9137notices just after the title page: 9138 9139 Copyright (C) YEAR YOUR NAME. 9140 Permission is granted to copy, distribute and/or modify this document 9141 under the terms of the GNU Free Documentation License, Version 1.1 9142 or any later version published by the Free Software Foundation; 9143 with the Invariant Sections being LIST THEIR TITLES, with the 9144 Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST. 9145 A copy of the license is included in the section entitled "GNU 9146 Free Documentation License." 9147 9148 If you have no Invariant Sections, write "with no Invariant Sections" 9149instead of saying which ones are invariant. If you have no Front-Cover 9150Texts, write "no Front-Cover Texts" instead of "Front-Cover Texts being 9151LIST"; likewise for Back-Cover Texts. 9152 9153 If your document contains nontrivial examples of program code, we 9154recommend releasing these examples in parallel under your choice of 9155free software license, such as the GNU General Public License, to 9156permit their use in free software. 9157 9158 9159File: bfd.info, Node: BFD Index, Prev: GNU Free Documentation License, Up: Top 9160 9161BFD Index 9162********* 9163 9164[index] 9165* Menu: 9166 9167* _bfd_final_link_relocate: Relocating the section contents. 9168 (line 22) 9169* _bfd_generic_link_add_archive_symbols: Adding symbols from an archive. 9170 (line 12) 9171* _bfd_generic_link_add_one_symbol: Adding symbols from an object file. 9172 (line 19) 9173* _bfd_generic_make_empty_symbol: symbol handling functions. 9174 (line 92) 9175* _bfd_link_add_symbols in target vector: Adding Symbols to the Hash Table. 9176 (line 6) 9177* _bfd_link_final_link in target vector: Performing the Final Link. 9178 (line 6) 9179* _bfd_link_hash_table_create in target vector: Creating a Linker Hash Table. 9180 (line 6) 9181* _bfd_relocate_contents: Relocating the section contents. 9182 (line 22) 9183* aout_SIZE_machine_type: aout. (line 147) 9184* aout_SIZE_mkobject: aout. (line 139) 9185* aout_SIZE_new_section_hook: aout. (line 177) 9186* aout_SIZE_set_arch_mach: aout. (line 164) 9187* aout_SIZE_some_aout_object_p: aout. (line 125) 9188* aout_SIZE_swap_exec_header_in: aout. (line 101) 9189* aout_SIZE_swap_exec_header_out: aout. (line 113) 9190* arelent_chain: typedef arelent. (line 339) 9191* BFD: Overview. (line 6) 9192* BFD canonical format: Canonical format. (line 11) 9193* bfd_alloc: Opening and Closing. 9194 (line 210) 9195* bfd_alloc2: Opening and Closing. 9196 (line 219) 9197* bfd_alt_mach_code: BFD front end. (line 602) 9198* bfd_arch_bits_per_address: Architectures. (line 490) 9199* bfd_arch_bits_per_byte: Architectures. (line 482) 9200* bfd_arch_get_compatible: Architectures. (line 425) 9201* bfd_arch_list: Architectures. (line 416) 9202* bfd_arch_mach_octets_per_byte: Architectures. (line 559) 9203* BFD_ARELOC_BFIN_ADD: howto manager. (line 944) 9204* BFD_ARELOC_BFIN_ADDR: howto manager. (line 995) 9205* BFD_ARELOC_BFIN_AND: howto manager. (line 965) 9206* BFD_ARELOC_BFIN_COMP: howto manager. (line 986) 9207* BFD_ARELOC_BFIN_CONST: howto manager. (line 941) 9208* BFD_ARELOC_BFIN_DIV: howto manager. (line 953) 9209* BFD_ARELOC_BFIN_HWPAGE: howto manager. (line 992) 9210* BFD_ARELOC_BFIN_LAND: howto manager. (line 974) 9211* BFD_ARELOC_BFIN_LEN: howto manager. (line 980) 9212* BFD_ARELOC_BFIN_LOR: howto manager. (line 977) 9213* BFD_ARELOC_BFIN_LSHIFT: howto manager. (line 959) 9214* BFD_ARELOC_BFIN_MOD: howto manager. (line 956) 9215* BFD_ARELOC_BFIN_MULT: howto manager. (line 950) 9216* BFD_ARELOC_BFIN_NEG: howto manager. (line 983) 9217* BFD_ARELOC_BFIN_OR: howto manager. (line 968) 9218* BFD_ARELOC_BFIN_PAGE: howto manager. (line 989) 9219* BFD_ARELOC_BFIN_PUSH: howto manager. (line 938) 9220* BFD_ARELOC_BFIN_RSHIFT: howto manager. (line 962) 9221* BFD_ARELOC_BFIN_SUB: howto manager. (line 947) 9222* BFD_ARELOC_BFIN_XOR: howto manager. (line 971) 9223* bfd_cache_close: File Caching. (line 26) 9224* bfd_cache_close_all: File Caching. (line 39) 9225* bfd_cache_init: File Caching. (line 18) 9226* bfd_calc_gnu_debuglink_crc32: Opening and Closing. 9227 (line 246) 9228* bfd_canonicalize_reloc: BFD front end. (line 321) 9229* bfd_canonicalize_symtab: symbol handling functions. 9230 (line 50) 9231* bfd_check_format: Formats. (line 21) 9232* bfd_check_format_matches: Formats. (line 52) 9233* bfd_check_overflow: typedef arelent. (line 351) 9234* bfd_close: Opening and Closing. 9235 (line 135) 9236* bfd_close_all_done: Opening and Closing. 9237 (line 153) 9238* bfd_coff_backend_data: coff. (line 246) 9239* bfd_copy_private_bfd_data: BFD front end. (line 460) 9240* bfd_copy_private_header_data: BFD front end. (line 442) 9241* bfd_copy_private_section_data: section prototypes. (line 255) 9242* bfd_copy_private_symbol_data: symbol handling functions. 9243 (line 140) 9244* bfd_core_file_failing_command: Core Files. (line 12) 9245* bfd_core_file_failing_signal: Core Files. (line 21) 9246* bfd_create: Opening and Closing. 9247 (line 172) 9248* bfd_create_gnu_debuglink_section: Opening and Closing. 9249 (line 312) 9250* bfd_decode_symclass: symbol handling functions. 9251 (line 111) 9252* bfd_default_arch_struct: Architectures. (line 437) 9253* bfd_default_compatible: Architectures. (line 499) 9254* bfd_default_reloc_type_lookup: howto manager. (line 2081) 9255* bfd_default_scan: Architectures. (line 508) 9256* bfd_default_set_arch_mach: Architectures. (line 455) 9257* bfd_demangle: BFD front end. (line 700) 9258* bfd_elf_find_section: elf. (line 13) 9259* bfd_emul_get_commonpagesize: BFD front end. (line 680) 9260* bfd_emul_get_maxpagesize: BFD front end. (line 660) 9261* bfd_emul_set_commonpagesize: BFD front end. (line 691) 9262* bfd_emul_set_maxpagesize: BFD front end. (line 671) 9263* bfd_errmsg: BFD front end. (line 246) 9264* bfd_fdopenr: Opening and Closing. 9265 (line 46) 9266* bfd_fill_in_gnu_debuglink_section: Opening and Closing. 9267 (line 326) 9268* bfd_find_target: bfd_target. (line 439) 9269* bfd_follow_gnu_debuglink: Opening and Closing. 9270 (line 291) 9271* bfd_fopen: Opening and Closing. 9272 (line 9) 9273* bfd_format_string: Formats. (line 79) 9274* bfd_generic_discard_group: section prototypes. (line 281) 9275* bfd_generic_gc_sections: howto manager. (line 2112) 9276* bfd_generic_get_relocated_section_contents: howto manager. (line 2132) 9277* bfd_generic_is_group_section: section prototypes. (line 273) 9278* bfd_generic_merge_sections: howto manager. (line 2122) 9279* bfd_generic_relax_section: howto manager. (line 2099) 9280* bfd_get_arch: Architectures. (line 466) 9281* bfd_get_arch_info: Architectures. (line 518) 9282* bfd_get_arch_size: BFD front end. (line 365) 9283* bfd_get_error: BFD front end. (line 227) 9284* bfd_get_error_handler: BFD front end. (line 297) 9285* bfd_get_gp_size: BFD front end. (line 406) 9286* bfd_get_mach: Architectures. (line 474) 9287* bfd_get_mtime: BFD front end. (line 741) 9288* bfd_get_next_mapent: Archives. (line 52) 9289* bfd_get_reloc_code_name: howto manager. (line 2090) 9290* bfd_get_reloc_size: typedef arelent. (line 330) 9291* bfd_get_reloc_upper_bound: BFD front end. (line 311) 9292* bfd_get_section_by_name: section prototypes. (line 17) 9293* bfd_get_section_by_name_if: section prototypes. (line 31) 9294* bfd_get_section_contents: section prototypes. (line 228) 9295* bfd_get_sign_extend_vma: BFD front end. (line 378) 9296* bfd_get_size <1>: Internal. (line 25) 9297* bfd_get_size: BFD front end. (line 750) 9298* bfd_get_symtab_upper_bound: symbol handling functions. 9299 (line 6) 9300* bfd_get_unique_section_name: section prototypes. (line 50) 9301* bfd_h_put_size: Internal. (line 97) 9302* bfd_hash_allocate: Creating and Freeing a Hash Table. 9303 (line 17) 9304* bfd_hash_lookup: Looking Up or Entering a String. 9305 (line 6) 9306* bfd_hash_newfunc: Creating and Freeing a Hash Table. 9307 (line 12) 9308* bfd_hash_set_default_size: Creating and Freeing a Hash Table. 9309 (line 25) 9310* bfd_hash_table_free: Creating and Freeing a Hash Table. 9311 (line 21) 9312* bfd_hash_table_init: Creating and Freeing a Hash Table. 9313 (line 6) 9314* bfd_hash_table_init_n: Creating and Freeing a Hash Table. 9315 (line 6) 9316* bfd_hash_traverse: Traversing a Hash Table. 9317 (line 6) 9318* bfd_init: Initialization. (line 11) 9319* bfd_install_relocation: typedef arelent. (line 392) 9320* bfd_is_local_label: symbol handling functions. 9321 (line 17) 9322* bfd_is_local_label_name: symbol handling functions. 9323 (line 26) 9324* bfd_is_target_special_symbol: symbol handling functions. 9325 (line 38) 9326* bfd_is_undefined_symclass: symbol handling functions. 9327 (line 120) 9328* bfd_link_split_section: Writing the symbol table. 9329 (line 44) 9330* bfd_log2: Internal. (line 164) 9331* bfd_lookup_arch: Architectures. (line 526) 9332* bfd_make_debug_symbol: symbol handling functions. 9333 (line 102) 9334* bfd_make_empty_symbol: symbol handling functions. 9335 (line 78) 9336* bfd_make_readable: Opening and Closing. 9337 (line 196) 9338* bfd_make_section: section prototypes. (line 129) 9339* bfd_make_section_anyway: section prototypes. (line 100) 9340* bfd_make_section_anyway_with_flags: section prototypes. (line 82) 9341* bfd_make_section_old_way: section prototypes. (line 62) 9342* bfd_make_section_with_flags: section prototypes. (line 116) 9343* bfd_make_writable: Opening and Closing. 9344 (line 182) 9345* bfd_malloc_and_get_section: section prototypes. (line 245) 9346* bfd_map_over_sections: section prototypes. (line 155) 9347* bfd_merge_private_bfd_data: BFD front end. (line 476) 9348* bfd_octets_per_byte: Architectures. (line 549) 9349* bfd_open_file: File Caching. (line 52) 9350* bfd_openr: Opening and Closing. 9351 (line 30) 9352* bfd_openr_iovec: Opening and Closing. 9353 (line 76) 9354* bfd_openr_next_archived_file: Archives. (line 78) 9355* bfd_openstreamr: Opening and Closing. 9356 (line 67) 9357* bfd_openw: Opening and Closing. 9358 (line 123) 9359* bfd_perform_relocation: typedef arelent. (line 367) 9360* bfd_perror: BFD front end. (line 255) 9361* bfd_preserve_finish: BFD front end. (line 650) 9362* bfd_preserve_restore: BFD front end. (line 640) 9363* bfd_preserve_save: BFD front end. (line 624) 9364* bfd_print_symbol_vandf: symbol handling functions. 9365 (line 70) 9366* bfd_printable_arch_mach: Architectures. (line 537) 9367* bfd_printable_name: Architectures. (line 397) 9368* bfd_put_size: Internal. (line 22) 9369* BFD_RELOC_12_PCREL: howto manager. (line 39) 9370* BFD_RELOC_14: howto manager. (line 31) 9371* BFD_RELOC_16: howto manager. (line 30) 9372* BFD_RELOC_16_BASEREL: howto manager. (line 80) 9373* BFD_RELOC_16_GOT_PCREL: howto manager. (line 52) 9374* BFD_RELOC_16_GOTOFF: howto manager. (line 55) 9375* BFD_RELOC_16_PCREL: howto manager. (line 38) 9376* BFD_RELOC_16_PCREL_S2: howto manager. (line 92) 9377* BFD_RELOC_16_PLT_PCREL: howto manager. (line 63) 9378* BFD_RELOC_16_PLTOFF: howto manager. (line 67) 9379* BFD_RELOC_16C_ABS20: howto manager. (line 1771) 9380* BFD_RELOC_16C_ABS20_C: howto manager. (line 1772) 9381* BFD_RELOC_16C_ABS24: howto manager. (line 1773) 9382* BFD_RELOC_16C_ABS24_C: howto manager. (line 1774) 9383* BFD_RELOC_16C_DISP04: howto manager. (line 1751) 9384* BFD_RELOC_16C_DISP04_C: howto manager. (line 1752) 9385* BFD_RELOC_16C_DISP08: howto manager. (line 1753) 9386* BFD_RELOC_16C_DISP08_C: howto manager. (line 1754) 9387* BFD_RELOC_16C_DISP16: howto manager. (line 1755) 9388* BFD_RELOC_16C_DISP16_C: howto manager. (line 1756) 9389* BFD_RELOC_16C_DISP24: howto manager. (line 1757) 9390* BFD_RELOC_16C_DISP24_C: howto manager. (line 1758) 9391* BFD_RELOC_16C_DISP24a: howto manager. (line 1759) 9392* BFD_RELOC_16C_DISP24a_C: howto manager. (line 1760) 9393* BFD_RELOC_16C_IMM04: howto manager. (line 1775) 9394* BFD_RELOC_16C_IMM04_C: howto manager. (line 1776) 9395* BFD_RELOC_16C_IMM16: howto manager. (line 1777) 9396* BFD_RELOC_16C_IMM16_C: howto manager. (line 1778) 9397* BFD_RELOC_16C_IMM20: howto manager. (line 1779) 9398* BFD_RELOC_16C_IMM20_C: howto manager. (line 1780) 9399* BFD_RELOC_16C_IMM24: howto manager. (line 1781) 9400* BFD_RELOC_16C_IMM24_C: howto manager. (line 1782) 9401* BFD_RELOC_16C_IMM32: howto manager. (line 1783) 9402* BFD_RELOC_16C_IMM32_C: howto manager. (line 1784) 9403* BFD_RELOC_16C_NUM08: howto manager. (line 1745) 9404* BFD_RELOC_16C_NUM08_C: howto manager. (line 1746) 9405* BFD_RELOC_16C_NUM16: howto manager. (line 1747) 9406* BFD_RELOC_16C_NUM16_C: howto manager. (line 1748) 9407* BFD_RELOC_16C_NUM32: howto manager. (line 1749) 9408* BFD_RELOC_16C_NUM32_C: howto manager. (line 1750) 9409* BFD_RELOC_16C_REG04: howto manager. (line 1761) 9410* BFD_RELOC_16C_REG04_C: howto manager. (line 1762) 9411* BFD_RELOC_16C_REG04a: howto manager. (line 1763) 9412* BFD_RELOC_16C_REG04a_C: howto manager. (line 1764) 9413* BFD_RELOC_16C_REG14: howto manager. (line 1765) 9414* BFD_RELOC_16C_REG14_C: howto manager. (line 1766) 9415* BFD_RELOC_16C_REG16: howto manager. (line 1767) 9416* BFD_RELOC_16C_REG16_C: howto manager. (line 1768) 9417* BFD_RELOC_16C_REG20: howto manager. (line 1769) 9418* BFD_RELOC_16C_REG20_C: howto manager. (line 1770) 9419* BFD_RELOC_23_PCREL_S2: howto manager. (line 93) 9420* BFD_RELOC_24: howto manager. (line 29) 9421* BFD_RELOC_24_PCREL: howto manager. (line 37) 9422* BFD_RELOC_24_PLT_PCREL: howto manager. (line 62) 9423* BFD_RELOC_26: howto manager. (line 28) 9424* BFD_RELOC_32: howto manager. (line 27) 9425* BFD_RELOC_32_BASEREL: howto manager. (line 79) 9426* BFD_RELOC_32_GOT_PCREL: howto manager. (line 51) 9427* BFD_RELOC_32_GOTOFF: howto manager. (line 54) 9428* BFD_RELOC_32_PCREL: howto manager. (line 36) 9429* BFD_RELOC_32_PCREL_S2: howto manager. (line 91) 9430* BFD_RELOC_32_PLT_PCREL: howto manager. (line 61) 9431* BFD_RELOC_32_PLTOFF: howto manager. (line 66) 9432* BFD_RELOC_32_SECREL: howto manager. (line 48) 9433* BFD_RELOC_386_COPY: howto manager. (line 451) 9434* BFD_RELOC_386_GLOB_DAT: howto manager. (line 452) 9435* BFD_RELOC_386_GOT32: howto manager. (line 449) 9436* BFD_RELOC_386_GOTOFF: howto manager. (line 455) 9437* BFD_RELOC_386_GOTPC: howto manager. (line 456) 9438* BFD_RELOC_386_JUMP_SLOT: howto manager. (line 453) 9439* BFD_RELOC_386_PLT32: howto manager. (line 450) 9440* BFD_RELOC_386_RELATIVE: howto manager. (line 454) 9441* BFD_RELOC_386_TLS_DESC: howto manager. (line 471) 9442* BFD_RELOC_386_TLS_DESC_CALL: howto manager. (line 470) 9443* BFD_RELOC_386_TLS_DTPMOD32: howto manager. (line 466) 9444* BFD_RELOC_386_TLS_DTPOFF32: howto manager. (line 467) 9445* BFD_RELOC_386_TLS_GD: howto manager. (line 461) 9446* BFD_RELOC_386_TLS_GOTDESC: howto manager. (line 469) 9447* BFD_RELOC_386_TLS_GOTIE: howto manager. (line 459) 9448* BFD_RELOC_386_TLS_IE: howto manager. (line 458) 9449* BFD_RELOC_386_TLS_IE_32: howto manager. (line 464) 9450* BFD_RELOC_386_TLS_LDM: howto manager. (line 462) 9451* BFD_RELOC_386_TLS_LDO_32: howto manager. (line 463) 9452* BFD_RELOC_386_TLS_LE: howto manager. (line 460) 9453* BFD_RELOC_386_TLS_LE_32: howto manager. (line 465) 9454* BFD_RELOC_386_TLS_TPOFF: howto manager. (line 457) 9455* BFD_RELOC_386_TLS_TPOFF32: howto manager. (line 468) 9456* BFD_RELOC_390_12: howto manager. (line 1437) 9457* BFD_RELOC_390_20: howto manager. (line 1537) 9458* BFD_RELOC_390_COPY: howto manager. (line 1446) 9459* BFD_RELOC_390_GLOB_DAT: howto manager. (line 1449) 9460* BFD_RELOC_390_GOT12: howto manager. (line 1440) 9461* BFD_RELOC_390_GOT16: howto manager. (line 1461) 9462* BFD_RELOC_390_GOT20: howto manager. (line 1538) 9463* BFD_RELOC_390_GOT64: howto manager. (line 1479) 9464* BFD_RELOC_390_GOTENT: howto manager. (line 1485) 9465* BFD_RELOC_390_GOTOFF64: howto manager. (line 1488) 9466* BFD_RELOC_390_GOTPC: howto manager. (line 1458) 9467* BFD_RELOC_390_GOTPCDBL: howto manager. (line 1476) 9468* BFD_RELOC_390_GOTPLT12: howto manager. (line 1491) 9469* BFD_RELOC_390_GOTPLT16: howto manager. (line 1494) 9470* BFD_RELOC_390_GOTPLT20: howto manager. (line 1539) 9471* BFD_RELOC_390_GOTPLT32: howto manager. (line 1497) 9472* BFD_RELOC_390_GOTPLT64: howto manager. (line 1500) 9473* BFD_RELOC_390_GOTPLTENT: howto manager. (line 1503) 9474* BFD_RELOC_390_JMP_SLOT: howto manager. (line 1452) 9475* BFD_RELOC_390_PC16DBL: howto manager. (line 1464) 9476* BFD_RELOC_390_PC32DBL: howto manager. (line 1470) 9477* BFD_RELOC_390_PLT16DBL: howto manager. (line 1467) 9478* BFD_RELOC_390_PLT32: howto manager. (line 1443) 9479* BFD_RELOC_390_PLT32DBL: howto manager. (line 1473) 9480* BFD_RELOC_390_PLT64: howto manager. (line 1482) 9481* BFD_RELOC_390_PLTOFF16: howto manager. (line 1506) 9482* BFD_RELOC_390_PLTOFF32: howto manager. (line 1509) 9483* BFD_RELOC_390_PLTOFF64: howto manager. (line 1512) 9484* BFD_RELOC_390_RELATIVE: howto manager. (line 1455) 9485* BFD_RELOC_390_TLS_DTPMOD: howto manager. (line 1532) 9486* BFD_RELOC_390_TLS_DTPOFF: howto manager. (line 1533) 9487* BFD_RELOC_390_TLS_GD32: howto manager. (line 1518) 9488* BFD_RELOC_390_TLS_GD64: howto manager. (line 1519) 9489* BFD_RELOC_390_TLS_GDCALL: howto manager. (line 1516) 9490* BFD_RELOC_390_TLS_GOTIE12: howto manager. (line 1520) 9491* BFD_RELOC_390_TLS_GOTIE20: howto manager. (line 1540) 9492* BFD_RELOC_390_TLS_GOTIE32: howto manager. (line 1521) 9493* BFD_RELOC_390_TLS_GOTIE64: howto manager. (line 1522) 9494* BFD_RELOC_390_TLS_IE32: howto manager. (line 1525) 9495* BFD_RELOC_390_TLS_IE64: howto manager. (line 1526) 9496* BFD_RELOC_390_TLS_IEENT: howto manager. (line 1527) 9497* BFD_RELOC_390_TLS_LDCALL: howto manager. (line 1517) 9498* BFD_RELOC_390_TLS_LDM32: howto manager. (line 1523) 9499* BFD_RELOC_390_TLS_LDM64: howto manager. (line 1524) 9500* BFD_RELOC_390_TLS_LDO32: howto manager. (line 1530) 9501* BFD_RELOC_390_TLS_LDO64: howto manager. (line 1531) 9502* BFD_RELOC_390_TLS_LE32: howto manager. (line 1528) 9503* BFD_RELOC_390_TLS_LE64: howto manager. (line 1529) 9504* BFD_RELOC_390_TLS_LOAD: howto manager. (line 1515) 9505* BFD_RELOC_390_TLS_TPOFF: howto manager. (line 1534) 9506* BFD_RELOC_64: howto manager. (line 26) 9507* BFD_RELOC_64_PCREL: howto manager. (line 35) 9508* BFD_RELOC_64_PLT_PCREL: howto manager. (line 60) 9509* BFD_RELOC_64_PLTOFF: howto manager. (line 65) 9510* BFD_RELOC_68K_GLOB_DAT: howto manager. (line 74) 9511* BFD_RELOC_68K_JMP_SLOT: howto manager. (line 75) 9512* BFD_RELOC_68K_RELATIVE: howto manager. (line 76) 9513* BFD_RELOC_8: howto manager. (line 32) 9514* BFD_RELOC_860_COPY: howto manager. (line 1879) 9515* BFD_RELOC_860_GLOB_DAT: howto manager. (line 1880) 9516* BFD_RELOC_860_HAGOT: howto manager. (line 1905) 9517* BFD_RELOC_860_HAGOTOFF: howto manager. (line 1906) 9518* BFD_RELOC_860_HAPC: howto manager. (line 1907) 9519* BFD_RELOC_860_HIGH: howto manager. (line 1908) 9520* BFD_RELOC_860_HIGHADJ: howto manager. (line 1904) 9521* BFD_RELOC_860_HIGOT: howto manager. (line 1909) 9522* BFD_RELOC_860_HIGOTOFF: howto manager. (line 1910) 9523* BFD_RELOC_860_JUMP_SLOT: howto manager. (line 1881) 9524* BFD_RELOC_860_LOGOT0: howto manager. (line 1893) 9525* BFD_RELOC_860_LOGOT1: howto manager. (line 1895) 9526* BFD_RELOC_860_LOGOTOFF0: howto manager. (line 1897) 9527* BFD_RELOC_860_LOGOTOFF1: howto manager. (line 1899) 9528* BFD_RELOC_860_LOGOTOFF2: howto manager. (line 1901) 9529* BFD_RELOC_860_LOGOTOFF3: howto manager. (line 1902) 9530* BFD_RELOC_860_LOPC: howto manager. (line 1903) 9531* BFD_RELOC_860_LOW0: howto manager. (line 1886) 9532* BFD_RELOC_860_LOW1: howto manager. (line 1888) 9533* BFD_RELOC_860_LOW2: howto manager. (line 1890) 9534* BFD_RELOC_860_LOW3: howto manager. (line 1892) 9535* BFD_RELOC_860_PC16: howto manager. (line 1885) 9536* BFD_RELOC_860_PC26: howto manager. (line 1883) 9537* BFD_RELOC_860_PLT26: howto manager. (line 1884) 9538* BFD_RELOC_860_RELATIVE: howto manager. (line 1882) 9539* BFD_RELOC_860_SPGOT0: howto manager. (line 1894) 9540* BFD_RELOC_860_SPGOT1: howto manager. (line 1896) 9541* BFD_RELOC_860_SPGOTOFF0: howto manager. (line 1898) 9542* BFD_RELOC_860_SPGOTOFF1: howto manager. (line 1900) 9543* BFD_RELOC_860_SPLIT0: howto manager. (line 1887) 9544* BFD_RELOC_860_SPLIT1: howto manager. (line 1889) 9545* BFD_RELOC_860_SPLIT2: howto manager. (line 1891) 9546* BFD_RELOC_8_BASEREL: howto manager. (line 84) 9547* BFD_RELOC_8_FFnn: howto manager. (line 88) 9548* BFD_RELOC_8_GOT_PCREL: howto manager. (line 53) 9549* BFD_RELOC_8_GOTOFF: howto manager. (line 59) 9550* BFD_RELOC_8_PCREL: howto manager. (line 40) 9551* BFD_RELOC_8_PLT_PCREL: howto manager. (line 64) 9552* BFD_RELOC_8_PLTOFF: howto manager. (line 71) 9553* BFD_RELOC_ALPHA_BRSGP: howto manager. (line 275) 9554* BFD_RELOC_ALPHA_CODEADDR: howto manager. (line 266) 9555* BFD_RELOC_ALPHA_DTPMOD64: howto manager. (line 282) 9556* BFD_RELOC_ALPHA_DTPREL16: howto manager. (line 287) 9557* BFD_RELOC_ALPHA_DTPREL64: howto manager. (line 284) 9558* BFD_RELOC_ALPHA_DTPREL_HI16: howto manager. (line 285) 9559* BFD_RELOC_ALPHA_DTPREL_LO16: howto manager. (line 286) 9560* BFD_RELOC_ALPHA_ELF_LITERAL: howto manager. (line 231) 9561* BFD_RELOC_ALPHA_GOTDTPREL16: howto manager. (line 283) 9562* BFD_RELOC_ALPHA_GOTTPREL16: howto manager. (line 288) 9563* BFD_RELOC_ALPHA_GPDISP: howto manager. (line 225) 9564* BFD_RELOC_ALPHA_GPDISP_HI16: howto manager. (line 211) 9565* BFD_RELOC_ALPHA_GPDISP_LO16: howto manager. (line 219) 9566* BFD_RELOC_ALPHA_GPREL_HI16: howto manager. (line 270) 9567* BFD_RELOC_ALPHA_GPREL_LO16: howto manager. (line 271) 9568* BFD_RELOC_ALPHA_HINT: howto manager. (line 257) 9569* BFD_RELOC_ALPHA_LINKAGE: howto manager. (line 262) 9570* BFD_RELOC_ALPHA_LITERAL: howto manager. (line 230) 9571* BFD_RELOC_ALPHA_LITUSE: howto manager. (line 232) 9572* BFD_RELOC_ALPHA_TLSGD: howto manager. (line 280) 9573* BFD_RELOC_ALPHA_TLSLDM: howto manager. (line 281) 9574* BFD_RELOC_ALPHA_TPREL16: howto manager. (line 292) 9575* BFD_RELOC_ALPHA_TPREL64: howto manager. (line 289) 9576* BFD_RELOC_ALPHA_TPREL_HI16: howto manager. (line 290) 9577* BFD_RELOC_ALPHA_TPREL_LO16: howto manager. (line 291) 9578* BFD_RELOC_ARC_B22_PCREL: howto manager. (line 873) 9579* BFD_RELOC_ARC_B26: howto manager. (line 878) 9580* BFD_RELOC_ARM_ADR_IMM: howto manager. (line 766) 9581* BFD_RELOC_ARM_ADRL_IMMEDIATE: howto manager. (line 753) 9582* BFD_RELOC_ARM_ALU_PC_G0: howto manager. (line 723) 9583* BFD_RELOC_ARM_ALU_PC_G0_NC: howto manager. (line 722) 9584* BFD_RELOC_ARM_ALU_PC_G1: howto manager. (line 725) 9585* BFD_RELOC_ARM_ALU_PC_G1_NC: howto manager. (line 724) 9586* BFD_RELOC_ARM_ALU_PC_G2: howto manager. (line 726) 9587* BFD_RELOC_ARM_ALU_SB_G0: howto manager. (line 737) 9588* BFD_RELOC_ARM_ALU_SB_G0_NC: howto manager. (line 736) 9589* BFD_RELOC_ARM_ALU_SB_G1: howto manager. (line 739) 9590* BFD_RELOC_ARM_ALU_SB_G1_NC: howto manager. (line 738) 9591* BFD_RELOC_ARM_ALU_SB_G2: howto manager. (line 740) 9592* BFD_RELOC_ARM_CP_OFF_IMM: howto manager. (line 762) 9593* BFD_RELOC_ARM_CP_OFF_IMM_S2: howto manager. (line 763) 9594* BFD_RELOC_ARM_GLOB_DAT: howto manager. (line 704) 9595* BFD_RELOC_ARM_GOT32: howto manager. (line 705) 9596* BFD_RELOC_ARM_GOTOFF: howto manager. (line 708) 9597* BFD_RELOC_ARM_GOTPC: howto manager. (line 709) 9598* BFD_RELOC_ARM_HWLITERAL: howto manager. (line 773) 9599* BFD_RELOC_ARM_IMMEDIATE: howto manager. (line 752) 9600* BFD_RELOC_ARM_IN_POOL: howto manager. (line 769) 9601* BFD_RELOC_ARM_JUMP_SLOT: howto manager. (line 703) 9602* BFD_RELOC_ARM_LDC_PC_G0: howto manager. (line 733) 9603* BFD_RELOC_ARM_LDC_PC_G1: howto manager. (line 734) 9604* BFD_RELOC_ARM_LDC_PC_G2: howto manager. (line 735) 9605* BFD_RELOC_ARM_LDC_SB_G0: howto manager. (line 747) 9606* BFD_RELOC_ARM_LDC_SB_G1: howto manager. (line 748) 9607* BFD_RELOC_ARM_LDC_SB_G2: howto manager. (line 749) 9608* BFD_RELOC_ARM_LDR_IMM: howto manager. (line 767) 9609* BFD_RELOC_ARM_LDR_PC_G0: howto manager. (line 727) 9610* BFD_RELOC_ARM_LDR_PC_G1: howto manager. (line 728) 9611* BFD_RELOC_ARM_LDR_PC_G2: howto manager. (line 729) 9612* BFD_RELOC_ARM_LDR_SB_G0: howto manager. (line 741) 9613* BFD_RELOC_ARM_LDR_SB_G1: howto manager. (line 742) 9614* BFD_RELOC_ARM_LDR_SB_G2: howto manager. (line 743) 9615* BFD_RELOC_ARM_LDRS_PC_G0: howto manager. (line 730) 9616* BFD_RELOC_ARM_LDRS_PC_G1: howto manager. (line 731) 9617* BFD_RELOC_ARM_LDRS_PC_G2: howto manager. (line 732) 9618* BFD_RELOC_ARM_LDRS_SB_G0: howto manager. (line 744) 9619* BFD_RELOC_ARM_LDRS_SB_G1: howto manager. (line 745) 9620* BFD_RELOC_ARM_LDRS_SB_G2: howto manager. (line 746) 9621* BFD_RELOC_ARM_LITERAL: howto manager. (line 768) 9622* BFD_RELOC_ARM_MOVT: howto manager. (line 694) 9623* BFD_RELOC_ARM_MOVT_PCREL: howto manager. (line 696) 9624* BFD_RELOC_ARM_MOVW: howto manager. (line 693) 9625* BFD_RELOC_ARM_MOVW_PCREL: howto manager. (line 695) 9626* BFD_RELOC_ARM_MULTI: howto manager. (line 761) 9627* BFD_RELOC_ARM_OFFSET_IMM: howto manager. (line 667) 9628* BFD_RELOC_ARM_OFFSET_IMM8: howto manager. (line 770) 9629* BFD_RELOC_ARM_PCREL_BLX: howto manager. (line 638) 9630* BFD_RELOC_ARM_PCREL_BRANCH: howto manager. (line 634) 9631* BFD_RELOC_ARM_PCREL_CALL: howto manager. (line 648) 9632* BFD_RELOC_ARM_PCREL_JUMP: howto manager. (line 652) 9633* BFD_RELOC_ARM_PLT32: howto manager. (line 706) 9634* BFD_RELOC_ARM_PREL31: howto manager. (line 690) 9635* BFD_RELOC_ARM_RELATIVE: howto manager. (line 707) 9636* BFD_RELOC_ARM_ROSEGREL32: howto manager. (line 679) 9637* BFD_RELOC_ARM_SBREL32: howto manager. (line 682) 9638* BFD_RELOC_ARM_SHIFT_IMM: howto manager. (line 758) 9639* BFD_RELOC_ARM_SMC: howto manager. (line 759) 9640* BFD_RELOC_ARM_SWI: howto manager. (line 760) 9641* BFD_RELOC_ARM_T32_ADD_IMM: howto manager. (line 755) 9642* BFD_RELOC_ARM_T32_ADD_PC12: howto manager. (line 757) 9643* BFD_RELOC_ARM_T32_CP_OFF_IMM: howto manager. (line 764) 9644* BFD_RELOC_ARM_T32_CP_OFF_IMM_S2: howto manager. (line 765) 9645* BFD_RELOC_ARM_T32_IMM12: howto manager. (line 756) 9646* BFD_RELOC_ARM_T32_IMMEDIATE: howto manager. (line 754) 9647* BFD_RELOC_ARM_T32_OFFSET_IMM: howto manager. (line 772) 9648* BFD_RELOC_ARM_T32_OFFSET_U8: howto manager. (line 771) 9649* BFD_RELOC_ARM_TARGET1: howto manager. (line 675) 9650* BFD_RELOC_ARM_TARGET2: howto manager. (line 685) 9651* BFD_RELOC_ARM_THUMB_ADD: howto manager. (line 774) 9652* BFD_RELOC_ARM_THUMB_IMM: howto manager. (line 775) 9653* BFD_RELOC_ARM_THUMB_MOVT: howto manager. (line 698) 9654* BFD_RELOC_ARM_THUMB_MOVT_PCREL: howto manager. (line 700) 9655* BFD_RELOC_ARM_THUMB_MOVW: howto manager. (line 697) 9656* BFD_RELOC_ARM_THUMB_MOVW_PCREL: howto manager. (line 699) 9657* BFD_RELOC_ARM_THUMB_OFFSET: howto manager. (line 671) 9658* BFD_RELOC_ARM_THUMB_SHIFT: howto manager. (line 776) 9659* BFD_RELOC_ARM_TLS_DTPMOD32: howto manager. (line 716) 9660* BFD_RELOC_ARM_TLS_DTPOFF32: howto manager. (line 715) 9661* BFD_RELOC_ARM_TLS_GD32: howto manager. (line 712) 9662* BFD_RELOC_ARM_TLS_IE32: howto manager. (line 718) 9663* BFD_RELOC_ARM_TLS_LDM32: howto manager. (line 714) 9664* BFD_RELOC_ARM_TLS_LDO32: howto manager. (line 713) 9665* BFD_RELOC_ARM_TLS_LE32: howto manager. (line 719) 9666* BFD_RELOC_ARM_TLS_TPOFF32: howto manager. (line 717) 9667* BFD_RELOC_AVR_13_PCREL: howto manager. (line 1338) 9668* BFD_RELOC_AVR_16_PM: howto manager. (line 1342) 9669* BFD_RELOC_AVR_6: howto manager. (line 1429) 9670* BFD_RELOC_AVR_6_ADIW: howto manager. (line 1433) 9671* BFD_RELOC_AVR_7_PCREL: howto manager. (line 1334) 9672* BFD_RELOC_AVR_CALL: howto manager. (line 1421) 9673* BFD_RELOC_AVR_HH8_LDI: howto manager. (line 1354) 9674* BFD_RELOC_AVR_HH8_LDI_NEG: howto manager. (line 1373) 9675* BFD_RELOC_AVR_HH8_LDI_PM: howto manager. (line 1402) 9676* BFD_RELOC_AVR_HH8_LDI_PM_NEG: howto manager. (line 1416) 9677* BFD_RELOC_AVR_HI8_LDI: howto manager. (line 1350) 9678* BFD_RELOC_AVR_HI8_LDI_GS: howto manager. (line 1396) 9679* BFD_RELOC_AVR_HI8_LDI_NEG: howto manager. (line 1368) 9680* BFD_RELOC_AVR_HI8_LDI_PM: howto manager. (line 1392) 9681* BFD_RELOC_AVR_HI8_LDI_PM_NEG: howto manager. (line 1411) 9682* BFD_RELOC_AVR_LDI: howto manager. (line 1425) 9683* BFD_RELOC_AVR_LO8_LDI: howto manager. (line 1346) 9684* BFD_RELOC_AVR_LO8_LDI_GS: howto manager. (line 1386) 9685* BFD_RELOC_AVR_LO8_LDI_NEG: howto manager. (line 1363) 9686* BFD_RELOC_AVR_LO8_LDI_PM: howto manager. (line 1382) 9687* BFD_RELOC_AVR_LO8_LDI_PM_NEG: howto manager. (line 1407) 9688* BFD_RELOC_AVR_MS8_LDI: howto manager. (line 1359) 9689* BFD_RELOC_AVR_MS8_LDI_NEG: howto manager. (line 1378) 9690* BFD_RELOC_BFIN_10_PCREL: howto manager. (line 898) 9691* BFD_RELOC_BFIN_11_PCREL: howto manager. (line 901) 9692* BFD_RELOC_BFIN_12_PCREL_JUMP: howto manager. (line 904) 9693* BFD_RELOC_BFIN_12_PCREL_JUMP_S: howto manager. (line 907) 9694* BFD_RELOC_BFIN_16_HIGH: howto manager. (line 886) 9695* BFD_RELOC_BFIN_16_IMM: howto manager. (line 883) 9696* BFD_RELOC_BFIN_16_LOW: howto manager. (line 895) 9697* BFD_RELOC_BFIN_24_PCREL_CALL_X: howto manager. (line 910) 9698* BFD_RELOC_BFIN_24_PCREL_JUMP_L: howto manager. (line 913) 9699* BFD_RELOC_BFIN_4_PCREL: howto manager. (line 889) 9700* BFD_RELOC_BFIN_5_PCREL: howto manager. (line 892) 9701* BFD_RELOC_BFIN_FUNCDESC: howto manager. (line 919) 9702* BFD_RELOC_BFIN_FUNCDESC_GOT17M4: howto manager. (line 920) 9703* BFD_RELOC_BFIN_FUNCDESC_GOTHI: howto manager. (line 921) 9704* BFD_RELOC_BFIN_FUNCDESC_GOTLO: howto manager. (line 922) 9705* BFD_RELOC_BFIN_FUNCDESC_GOTOFF17M4: howto manager. (line 924) 9706* BFD_RELOC_BFIN_FUNCDESC_GOTOFFHI: howto manager. (line 925) 9707* BFD_RELOC_BFIN_FUNCDESC_GOTOFFLO: howto manager. (line 926) 9708* BFD_RELOC_BFIN_FUNCDESC_VALUE: howto manager. (line 923) 9709* BFD_RELOC_BFIN_GOT: howto manager. (line 932) 9710* BFD_RELOC_BFIN_GOT17M4: howto manager. (line 916) 9711* BFD_RELOC_BFIN_GOTHI: howto manager. (line 917) 9712* BFD_RELOC_BFIN_GOTLO: howto manager. (line 918) 9713* BFD_RELOC_BFIN_GOTOFF17M4: howto manager. (line 927) 9714* BFD_RELOC_BFIN_GOTOFFHI: howto manager. (line 928) 9715* BFD_RELOC_BFIN_GOTOFFLO: howto manager. (line 929) 9716* BFD_RELOC_BFIN_PLTPC: howto manager. (line 935) 9717* bfd_reloc_code_type: howto manager. (line 10) 9718* BFD_RELOC_CR16_ABS20: howto manager. (line 1799) 9719* BFD_RELOC_CR16_ABS24: howto manager. (line 1800) 9720* BFD_RELOC_CR16_DISP16: howto manager. (line 1810) 9721* BFD_RELOC_CR16_DISP20: howto manager. (line 1811) 9722* BFD_RELOC_CR16_DISP24: howto manager. (line 1812) 9723* BFD_RELOC_CR16_DISP24a: howto manager. (line 1813) 9724* BFD_RELOC_CR16_DISP4: howto manager. (line 1808) 9725* BFD_RELOC_CR16_DISP8: howto manager. (line 1809) 9726* BFD_RELOC_CR16_IMM16: howto manager. (line 1803) 9727* BFD_RELOC_CR16_IMM20: howto manager. (line 1804) 9728* BFD_RELOC_CR16_IMM24: howto manager. (line 1805) 9729* BFD_RELOC_CR16_IMM32: howto manager. (line 1806) 9730* BFD_RELOC_CR16_IMM32a: howto manager. (line 1807) 9731* BFD_RELOC_CR16_IMM4: howto manager. (line 1801) 9732* BFD_RELOC_CR16_IMM8: howto manager. (line 1802) 9733* BFD_RELOC_CR16_NUM16: howto manager. (line 1788) 9734* BFD_RELOC_CR16_NUM32: howto manager. (line 1789) 9735* BFD_RELOC_CR16_NUM32a: howto manager. (line 1790) 9736* BFD_RELOC_CR16_NUM8: howto manager. (line 1787) 9737* BFD_RELOC_CR16_REGREL0: howto manager. (line 1791) 9738* BFD_RELOC_CR16_REGREL14: howto manager. (line 1794) 9739* BFD_RELOC_CR16_REGREL14a: howto manager. (line 1795) 9740* BFD_RELOC_CR16_REGREL16: howto manager. (line 1796) 9741* BFD_RELOC_CR16_REGREL20: howto manager. (line 1797) 9742* BFD_RELOC_CR16_REGREL20a: howto manager. (line 1798) 9743* BFD_RELOC_CR16_REGREL4: howto manager. (line 1792) 9744* BFD_RELOC_CR16_REGREL4a: howto manager. (line 1793) 9745* BFD_RELOC_CRIS_16_GOT: howto manager. (line 1860) 9746* BFD_RELOC_CRIS_16_GOTPLT: howto manager. (line 1866) 9747* BFD_RELOC_CRIS_32_GOT: howto manager. (line 1857) 9748* BFD_RELOC_CRIS_32_GOTPLT: howto manager. (line 1863) 9749* BFD_RELOC_CRIS_32_GOTREL: howto manager. (line 1869) 9750* BFD_RELOC_CRIS_32_PLT_GOTREL: howto manager. (line 1872) 9751* BFD_RELOC_CRIS_32_PLT_PCREL: howto manager. (line 1875) 9752* BFD_RELOC_CRIS_BDISP8: howto manager. (line 1838) 9753* BFD_RELOC_CRIS_COPY: howto manager. (line 1851) 9754* BFD_RELOC_CRIS_GLOB_DAT: howto manager. (line 1852) 9755* BFD_RELOC_CRIS_JUMP_SLOT: howto manager. (line 1853) 9756* BFD_RELOC_CRIS_LAPCQ_OFFSET: howto manager. (line 1846) 9757* BFD_RELOC_CRIS_RELATIVE: howto manager. (line 1854) 9758* BFD_RELOC_CRIS_SIGNED_16: howto manager. (line 1844) 9759* BFD_RELOC_CRIS_SIGNED_6: howto manager. (line 1840) 9760* BFD_RELOC_CRIS_SIGNED_8: howto manager. (line 1842) 9761* BFD_RELOC_CRIS_UNSIGNED_16: howto manager. (line 1845) 9762* BFD_RELOC_CRIS_UNSIGNED_4: howto manager. (line 1847) 9763* BFD_RELOC_CRIS_UNSIGNED_5: howto manager. (line 1839) 9764* BFD_RELOC_CRIS_UNSIGNED_6: howto manager. (line 1841) 9765* BFD_RELOC_CRIS_UNSIGNED_8: howto manager. (line 1843) 9766* BFD_RELOC_CRX_ABS16: howto manager. (line 1826) 9767* BFD_RELOC_CRX_ABS32: howto manager. (line 1827) 9768* BFD_RELOC_CRX_IMM16: howto manager. (line 1831) 9769* BFD_RELOC_CRX_IMM32: howto manager. (line 1832) 9770* BFD_RELOC_CRX_NUM16: howto manager. (line 1829) 9771* BFD_RELOC_CRX_NUM32: howto manager. (line 1830) 9772* BFD_RELOC_CRX_NUM8: howto manager. (line 1828) 9773* BFD_RELOC_CRX_REGREL12: howto manager. (line 1822) 9774* BFD_RELOC_CRX_REGREL22: howto manager. (line 1823) 9775* BFD_RELOC_CRX_REGREL28: howto manager. (line 1824) 9776* BFD_RELOC_CRX_REGREL32: howto manager. (line 1825) 9777* BFD_RELOC_CRX_REL16: howto manager. (line 1819) 9778* BFD_RELOC_CRX_REL24: howto manager. (line 1820) 9779* BFD_RELOC_CRX_REL32: howto manager. (line 1821) 9780* BFD_RELOC_CRX_REL4: howto manager. (line 1816) 9781* BFD_RELOC_CRX_REL8: howto manager. (line 1817) 9782* BFD_RELOC_CRX_REL8_CMP: howto manager. (line 1818) 9783* BFD_RELOC_CRX_SWITCH16: howto manager. (line 1834) 9784* BFD_RELOC_CRX_SWITCH32: howto manager. (line 1835) 9785* BFD_RELOC_CRX_SWITCH8: howto manager. (line 1833) 9786* BFD_RELOC_CTOR: howto manager. (line 628) 9787* BFD_RELOC_D10V_10_PCREL_L: howto manager. (line 1002) 9788* BFD_RELOC_D10V_10_PCREL_R: howto manager. (line 998) 9789* BFD_RELOC_D10V_18: howto manager. (line 1007) 9790* BFD_RELOC_D10V_18_PCREL: howto manager. (line 1010) 9791* BFD_RELOC_D30V_15: howto manager. (line 1025) 9792* BFD_RELOC_D30V_15_PCREL: howto manager. (line 1029) 9793* BFD_RELOC_D30V_15_PCREL_R: howto manager. (line 1033) 9794* BFD_RELOC_D30V_21: howto manager. (line 1038) 9795* BFD_RELOC_D30V_21_PCREL: howto manager. (line 1042) 9796* BFD_RELOC_D30V_21_PCREL_R: howto manager. (line 1046) 9797* BFD_RELOC_D30V_32: howto manager. (line 1051) 9798* BFD_RELOC_D30V_32_PCREL: howto manager. (line 1054) 9799* BFD_RELOC_D30V_6: howto manager. (line 1013) 9800* BFD_RELOC_D30V_9_PCREL: howto manager. (line 1016) 9801* BFD_RELOC_D30V_9_PCREL_R: howto manager. (line 1020) 9802* BFD_RELOC_DLX_HI16_S: howto manager. (line 1057) 9803* BFD_RELOC_DLX_JMP26: howto manager. (line 1063) 9804* BFD_RELOC_DLX_LO16: howto manager. (line 1060) 9805* BFD_RELOC_FR30_10_IN_8: howto manager. (line 1242) 9806* BFD_RELOC_FR30_12_PCREL: howto manager. (line 1250) 9807* BFD_RELOC_FR30_20: howto manager. (line 1226) 9808* BFD_RELOC_FR30_48: howto manager. (line 1223) 9809* BFD_RELOC_FR30_6_IN_4: howto manager. (line 1230) 9810* BFD_RELOC_FR30_8_IN_8: howto manager. (line 1234) 9811* BFD_RELOC_FR30_9_IN_8: howto manager. (line 1238) 9812* BFD_RELOC_FR30_9_PCREL: howto manager. (line 1246) 9813* BFD_RELOC_FRV_FUNCDESC: howto manager. (line 393) 9814* BFD_RELOC_FRV_FUNCDESC_GOT12: howto manager. (line 394) 9815* BFD_RELOC_FRV_FUNCDESC_GOTHI: howto manager. (line 395) 9816* BFD_RELOC_FRV_FUNCDESC_GOTLO: howto manager. (line 396) 9817* BFD_RELOC_FRV_FUNCDESC_GOTOFF12: howto manager. (line 398) 9818* BFD_RELOC_FRV_FUNCDESC_GOTOFFHI: howto manager. (line 399) 9819* BFD_RELOC_FRV_FUNCDESC_GOTOFFLO: howto manager. (line 400) 9820* BFD_RELOC_FRV_FUNCDESC_VALUE: howto manager. (line 397) 9821* BFD_RELOC_FRV_GETTLSOFF: howto manager. (line 404) 9822* BFD_RELOC_FRV_GETTLSOFF_RELAX: howto manager. (line 417) 9823* BFD_RELOC_FRV_GOT12: howto manager. (line 390) 9824* BFD_RELOC_FRV_GOTHI: howto manager. (line 391) 9825* BFD_RELOC_FRV_GOTLO: howto manager. (line 392) 9826* BFD_RELOC_FRV_GOTOFF12: howto manager. (line 401) 9827* BFD_RELOC_FRV_GOTOFFHI: howto manager. (line 402) 9828* BFD_RELOC_FRV_GOTOFFLO: howto manager. (line 403) 9829* BFD_RELOC_FRV_GOTTLSDESC12: howto manager. (line 406) 9830* BFD_RELOC_FRV_GOTTLSDESCHI: howto manager. (line 407) 9831* BFD_RELOC_FRV_GOTTLSDESCLO: howto manager. (line 408) 9832* BFD_RELOC_FRV_GOTTLSOFF12: howto manager. (line 412) 9833* BFD_RELOC_FRV_GOTTLSOFFHI: howto manager. (line 413) 9834* BFD_RELOC_FRV_GOTTLSOFFLO: howto manager. (line 414) 9835* BFD_RELOC_FRV_GPREL12: howto manager. (line 385) 9836* BFD_RELOC_FRV_GPREL32: howto manager. (line 387) 9837* BFD_RELOC_FRV_GPRELHI: howto manager. (line 388) 9838* BFD_RELOC_FRV_GPRELLO: howto manager. (line 389) 9839* BFD_RELOC_FRV_GPRELU12: howto manager. (line 386) 9840* BFD_RELOC_FRV_HI16: howto manager. (line 384) 9841* BFD_RELOC_FRV_LABEL16: howto manager. (line 381) 9842* BFD_RELOC_FRV_LABEL24: howto manager. (line 382) 9843* BFD_RELOC_FRV_LO16: howto manager. (line 383) 9844* BFD_RELOC_FRV_TLSDESC_RELAX: howto manager. (line 416) 9845* BFD_RELOC_FRV_TLSDESC_VALUE: howto manager. (line 405) 9846* BFD_RELOC_FRV_TLSMOFF: howto manager. (line 419) 9847* BFD_RELOC_FRV_TLSMOFF12: howto manager. (line 409) 9848* BFD_RELOC_FRV_TLSMOFFHI: howto manager. (line 410) 9849* BFD_RELOC_FRV_TLSMOFFLO: howto manager. (line 411) 9850* BFD_RELOC_FRV_TLSOFF: howto manager. (line 415) 9851* BFD_RELOC_FRV_TLSOFF_RELAX: howto manager. (line 418) 9852* BFD_RELOC_GPREL16: howto manager. (line 106) 9853* BFD_RELOC_GPREL32: howto manager. (line 107) 9854* BFD_RELOC_H8_DIR16A8: howto manager. (line 1917) 9855* BFD_RELOC_H8_DIR16R8: howto manager. (line 1918) 9856* BFD_RELOC_H8_DIR24A8: howto manager. (line 1919) 9857* BFD_RELOC_H8_DIR24R8: howto manager. (line 1920) 9858* BFD_RELOC_H8_DIR32A16: howto manager. (line 1921) 9859* BFD_RELOC_HI16: howto manager. (line 305) 9860* BFD_RELOC_HI16_BASEREL: howto manager. (line 82) 9861* BFD_RELOC_HI16_GOTOFF: howto manager. (line 57) 9862* BFD_RELOC_HI16_PCREL: howto manager. (line 317) 9863* BFD_RELOC_HI16_PLTOFF: howto manager. (line 69) 9864* BFD_RELOC_HI16_S: howto manager. (line 308) 9865* BFD_RELOC_HI16_S_BASEREL: howto manager. (line 83) 9866* BFD_RELOC_HI16_S_GOTOFF: howto manager. (line 58) 9867* BFD_RELOC_HI16_S_PCREL: howto manager. (line 320) 9868* BFD_RELOC_HI16_S_PLTOFF: howto manager. (line 70) 9869* BFD_RELOC_HI22: howto manager. (line 101) 9870* BFD_RELOC_I370_D12: howto manager. (line 625) 9871* BFD_RELOC_I960_CALLJ: howto manager. (line 113) 9872* BFD_RELOC_IA64_COPY: howto manager. (line 1681) 9873* BFD_RELOC_IA64_DIR32LSB: howto manager. (line 1626) 9874* BFD_RELOC_IA64_DIR32MSB: howto manager. (line 1625) 9875* BFD_RELOC_IA64_DIR64LSB: howto manager. (line 1628) 9876* BFD_RELOC_IA64_DIR64MSB: howto manager. (line 1627) 9877* BFD_RELOC_IA64_DTPMOD64LSB: howto manager. (line 1691) 9878* BFD_RELOC_IA64_DTPMOD64MSB: howto manager. (line 1690) 9879* BFD_RELOC_IA64_DTPREL14: howto manager. (line 1693) 9880* BFD_RELOC_IA64_DTPREL22: howto manager. (line 1694) 9881* BFD_RELOC_IA64_DTPREL32LSB: howto manager. (line 1697) 9882* BFD_RELOC_IA64_DTPREL32MSB: howto manager. (line 1696) 9883* BFD_RELOC_IA64_DTPREL64I: howto manager. (line 1695) 9884* BFD_RELOC_IA64_DTPREL64LSB: howto manager. (line 1699) 9885* BFD_RELOC_IA64_DTPREL64MSB: howto manager. (line 1698) 9886* BFD_RELOC_IA64_FPTR32LSB: howto manager. (line 1643) 9887* BFD_RELOC_IA64_FPTR32MSB: howto manager. (line 1642) 9888* BFD_RELOC_IA64_FPTR64I: howto manager. (line 1641) 9889* BFD_RELOC_IA64_FPTR64LSB: howto manager. (line 1645) 9890* BFD_RELOC_IA64_FPTR64MSB: howto manager. (line 1644) 9891* BFD_RELOC_IA64_GPREL22: howto manager. (line 1629) 9892* BFD_RELOC_IA64_GPREL32LSB: howto manager. (line 1632) 9893* BFD_RELOC_IA64_GPREL32MSB: howto manager. (line 1631) 9894* BFD_RELOC_IA64_GPREL64I: howto manager. (line 1630) 9895* BFD_RELOC_IA64_GPREL64LSB: howto manager. (line 1634) 9896* BFD_RELOC_IA64_GPREL64MSB: howto manager. (line 1633) 9897* BFD_RELOC_IA64_IMM14: howto manager. (line 1622) 9898* BFD_RELOC_IA64_IMM22: howto manager. (line 1623) 9899* BFD_RELOC_IA64_IMM64: howto manager. (line 1624) 9900* BFD_RELOC_IA64_IPLTLSB: howto manager. (line 1680) 9901* BFD_RELOC_IA64_IPLTMSB: howto manager. (line 1679) 9902* BFD_RELOC_IA64_LDXMOV: howto manager. (line 1683) 9903* BFD_RELOC_IA64_LTOFF22: howto manager. (line 1635) 9904* BFD_RELOC_IA64_LTOFF22X: howto manager. (line 1682) 9905* BFD_RELOC_IA64_LTOFF64I: howto manager. (line 1636) 9906* BFD_RELOC_IA64_LTOFF_DTPMOD22: howto manager. (line 1692) 9907* BFD_RELOC_IA64_LTOFF_DTPREL22: howto manager. (line 1700) 9908* BFD_RELOC_IA64_LTOFF_FPTR22: howto manager. (line 1657) 9909* BFD_RELOC_IA64_LTOFF_FPTR32LSB: howto manager. (line 1660) 9910* BFD_RELOC_IA64_LTOFF_FPTR32MSB: howto manager. (line 1659) 9911* BFD_RELOC_IA64_LTOFF_FPTR64I: howto manager. (line 1658) 9912* BFD_RELOC_IA64_LTOFF_FPTR64LSB: howto manager. (line 1662) 9913* BFD_RELOC_IA64_LTOFF_FPTR64MSB: howto manager. (line 1661) 9914* BFD_RELOC_IA64_LTOFF_TPREL22: howto manager. (line 1689) 9915* BFD_RELOC_IA64_LTV32LSB: howto manager. (line 1676) 9916* BFD_RELOC_IA64_LTV32MSB: howto manager. (line 1675) 9917* BFD_RELOC_IA64_LTV64LSB: howto manager. (line 1678) 9918* BFD_RELOC_IA64_LTV64MSB: howto manager. (line 1677) 9919* BFD_RELOC_IA64_PCREL21B: howto manager. (line 1646) 9920* BFD_RELOC_IA64_PCREL21BI: howto manager. (line 1647) 9921* BFD_RELOC_IA64_PCREL21F: howto manager. (line 1649) 9922* BFD_RELOC_IA64_PCREL21M: howto manager. (line 1648) 9923* BFD_RELOC_IA64_PCREL22: howto manager. (line 1650) 9924* BFD_RELOC_IA64_PCREL32LSB: howto manager. (line 1654) 9925* BFD_RELOC_IA64_PCREL32MSB: howto manager. (line 1653) 9926* BFD_RELOC_IA64_PCREL60B: howto manager. (line 1651) 9927* BFD_RELOC_IA64_PCREL64I: howto manager. (line 1652) 9928* BFD_RELOC_IA64_PCREL64LSB: howto manager. (line 1656) 9929* BFD_RELOC_IA64_PCREL64MSB: howto manager. (line 1655) 9930* BFD_RELOC_IA64_PLTOFF22: howto manager. (line 1637) 9931* BFD_RELOC_IA64_PLTOFF64I: howto manager. (line 1638) 9932* BFD_RELOC_IA64_PLTOFF64LSB: howto manager. (line 1640) 9933* BFD_RELOC_IA64_PLTOFF64MSB: howto manager. (line 1639) 9934* BFD_RELOC_IA64_REL32LSB: howto manager. (line 1672) 9935* BFD_RELOC_IA64_REL32MSB: howto manager. (line 1671) 9936* BFD_RELOC_IA64_REL64LSB: howto manager. (line 1674) 9937* BFD_RELOC_IA64_REL64MSB: howto manager. (line 1673) 9938* BFD_RELOC_IA64_SECREL32LSB: howto manager. (line 1668) 9939* BFD_RELOC_IA64_SECREL32MSB: howto manager. (line 1667) 9940* BFD_RELOC_IA64_SECREL64LSB: howto manager. (line 1670) 9941* BFD_RELOC_IA64_SECREL64MSB: howto manager. (line 1669) 9942* BFD_RELOC_IA64_SEGREL32LSB: howto manager. (line 1664) 9943* BFD_RELOC_IA64_SEGREL32MSB: howto manager. (line 1663) 9944* BFD_RELOC_IA64_SEGREL64LSB: howto manager. (line 1666) 9945* BFD_RELOC_IA64_SEGREL64MSB: howto manager. (line 1665) 9946* BFD_RELOC_IA64_TPREL14: howto manager. (line 1684) 9947* BFD_RELOC_IA64_TPREL22: howto manager. (line 1685) 9948* BFD_RELOC_IA64_TPREL64I: howto manager. (line 1686) 9949* BFD_RELOC_IA64_TPREL64LSB: howto manager. (line 1688) 9950* BFD_RELOC_IA64_TPREL64MSB: howto manager. (line 1687) 9951* BFD_RELOC_IP2K_ADDR16CJP: howto manager. (line 1574) 9952* BFD_RELOC_IP2K_BANK: howto manager. (line 1571) 9953* BFD_RELOC_IP2K_EX8DATA: howto manager. (line 1582) 9954* BFD_RELOC_IP2K_FR9: howto manager. (line 1568) 9955* BFD_RELOC_IP2K_FR_OFFSET: howto manager. (line 1595) 9956* BFD_RELOC_IP2K_HI8DATA: howto manager. (line 1581) 9957* BFD_RELOC_IP2K_HI8INSN: howto manager. (line 1586) 9958* BFD_RELOC_IP2K_LO8DATA: howto manager. (line 1580) 9959* BFD_RELOC_IP2K_LO8INSN: howto manager. (line 1585) 9960* BFD_RELOC_IP2K_PAGE3: howto manager. (line 1577) 9961* BFD_RELOC_IP2K_PC_SKIP: howto manager. (line 1589) 9962* BFD_RELOC_IP2K_TEXT: howto manager. (line 1592) 9963* BFD_RELOC_IQ2000_OFFSET_16: howto manager. (line 1971) 9964* BFD_RELOC_IQ2000_OFFSET_21: howto manager. (line 1972) 9965* BFD_RELOC_IQ2000_UHI16: howto manager. (line 1973) 9966* BFD_RELOC_LO10: howto manager. (line 102) 9967* BFD_RELOC_LO16: howto manager. (line 314) 9968* BFD_RELOC_LO16_BASEREL: howto manager. (line 81) 9969* BFD_RELOC_LO16_GOTOFF: howto manager. (line 56) 9970* BFD_RELOC_LO16_PCREL: howto manager. (line 323) 9971* BFD_RELOC_LO16_PLTOFF: howto manager. (line 68) 9972* BFD_RELOC_M32C_HI8: howto manager. (line 1066) 9973* BFD_RELOC_M32C_RL_1ADDR: howto manager. (line 1068) 9974* BFD_RELOC_M32C_RL_2ADDR: howto manager. (line 1069) 9975* BFD_RELOC_M32C_RL_JUMP: howto manager. (line 1067) 9976* BFD_RELOC_M32R_10_PCREL: howto manager. (line 1076) 9977* BFD_RELOC_M32R_18_PCREL: howto manager. (line 1080) 9978* BFD_RELOC_M32R_24: howto manager. (line 1072) 9979* BFD_RELOC_M32R_26_PCREL: howto manager. (line 1083) 9980* BFD_RELOC_M32R_26_PLTREL: howto manager. (line 1102) 9981* BFD_RELOC_M32R_COPY: howto manager. (line 1103) 9982* BFD_RELOC_M32R_GLOB_DAT: howto manager. (line 1104) 9983* BFD_RELOC_M32R_GOT16_HI_SLO: howto manager. (line 1113) 9984* BFD_RELOC_M32R_GOT16_HI_ULO: howto manager. (line 1112) 9985* BFD_RELOC_M32R_GOT16_LO: howto manager. (line 1114) 9986* BFD_RELOC_M32R_GOT24: howto manager. (line 1101) 9987* BFD_RELOC_M32R_GOTOFF: howto manager. (line 1107) 9988* BFD_RELOC_M32R_GOTOFF_HI_SLO: howto manager. (line 1109) 9989* BFD_RELOC_M32R_GOTOFF_HI_ULO: howto manager. (line 1108) 9990* BFD_RELOC_M32R_GOTOFF_LO: howto manager. (line 1110) 9991* BFD_RELOC_M32R_GOTPC24: howto manager. (line 1111) 9992* BFD_RELOC_M32R_GOTPC_HI_SLO: howto manager. (line 1116) 9993* BFD_RELOC_M32R_GOTPC_HI_ULO: howto manager. (line 1115) 9994* BFD_RELOC_M32R_GOTPC_LO: howto manager. (line 1117) 9995* BFD_RELOC_M32R_HI16_SLO: howto manager. (line 1090) 9996* BFD_RELOC_M32R_HI16_ULO: howto manager. (line 1086) 9997* BFD_RELOC_M32R_JMP_SLOT: howto manager. (line 1105) 9998* BFD_RELOC_M32R_LO16: howto manager. (line 1094) 9999* BFD_RELOC_M32R_RELATIVE: howto manager. (line 1106) 10000* BFD_RELOC_M32R_SDA16: howto manager. (line 1097) 10001* BFD_RELOC_M68HC11_24: howto manager. (line 1736) 10002* BFD_RELOC_M68HC11_3B: howto manager. (line 1711) 10003* BFD_RELOC_M68HC11_HI8: howto manager. (line 1703) 10004* BFD_RELOC_M68HC11_LO16: howto manager. (line 1725) 10005* BFD_RELOC_M68HC11_LO8: howto manager. (line 1707) 10006* BFD_RELOC_M68HC11_PAGE: howto manager. (line 1731) 10007* BFD_RELOC_M68HC11_RL_GROUP: howto manager. (line 1720) 10008* BFD_RELOC_M68HC11_RL_JUMP: howto manager. (line 1714) 10009* BFD_RELOC_M68HC12_5B: howto manager. (line 1742) 10010* BFD_RELOC_MCORE_PCREL_32: howto manager. (line 1257) 10011* BFD_RELOC_MCORE_PCREL_IMM11BY2: howto manager. (line 1255) 10012* BFD_RELOC_MCORE_PCREL_IMM4BY2: howto manager. (line 1256) 10013* BFD_RELOC_MCORE_PCREL_IMM8BY4: howto manager. (line 1254) 10014* BFD_RELOC_MCORE_PCREL_JSR_IMM11BY2: howto manager. (line 1258) 10015* BFD_RELOC_MCORE_RVA: howto manager. (line 1259) 10016* BFD_RELOC_MEP_16: howto manager. (line 1263) 10017* BFD_RELOC_MEP_32: howto manager. (line 1264) 10018* BFD_RELOC_MEP_8: howto manager. (line 1262) 10019* BFD_RELOC_MEP_ADDR24A4: howto manager. (line 1279) 10020* BFD_RELOC_MEP_GNU_VTENTRY: howto manager. (line 1281) 10021* BFD_RELOC_MEP_GNU_VTINHERIT: howto manager. (line 1280) 10022* BFD_RELOC_MEP_GPREL: howto manager. (line 1273) 10023* BFD_RELOC_MEP_HI16S: howto manager. (line 1272) 10024* BFD_RELOC_MEP_HI16U: howto manager. (line 1271) 10025* BFD_RELOC_MEP_LOW16: howto manager. (line 1270) 10026* BFD_RELOC_MEP_PCABS24A2: howto manager. (line 1269) 10027* BFD_RELOC_MEP_PCREL12A2: howto manager. (line 1266) 10028* BFD_RELOC_MEP_PCREL17A2: howto manager. (line 1267) 10029* BFD_RELOC_MEP_PCREL24A2: howto manager. (line 1268) 10030* BFD_RELOC_MEP_PCREL8A2: howto manager. (line 1265) 10031* BFD_RELOC_MEP_TPREL: howto manager. (line 1274) 10032* BFD_RELOC_MEP_TPREL7: howto manager. (line 1275) 10033* BFD_RELOC_MEP_TPREL7A2: howto manager. (line 1276) 10034* BFD_RELOC_MEP_TPREL7A4: howto manager. (line 1277) 10035* BFD_RELOC_MEP_UIMM24: howto manager. (line 1278) 10036* BFD_RELOC_MIPS16_GPREL: howto manager. (line 302) 10037* BFD_RELOC_MIPS16_HI16: howto manager. (line 326) 10038* BFD_RELOC_MIPS16_HI16_S: howto manager. (line 329) 10039* BFD_RELOC_MIPS16_JMP: howto manager. (line 299) 10040* BFD_RELOC_MIPS16_LO16: howto manager. (line 335) 10041* BFD_RELOC_MIPS_CALL16: howto manager. (line 342) 10042* BFD_RELOC_MIPS_CALL_HI16: howto manager. (line 345) 10043* BFD_RELOC_MIPS_CALL_LO16: howto manager. (line 346) 10044* BFD_RELOC_MIPS_COPY: howto manager. (line 377) 10045* BFD_RELOC_MIPS_DELETE: howto manager. (line 355) 10046* BFD_RELOC_MIPS_GOT16: howto manager. (line 341) 10047* BFD_RELOC_MIPS_GOT_DISP: howto manager. (line 350) 10048* BFD_RELOC_MIPS_GOT_HI16: howto manager. (line 343) 10049* BFD_RELOC_MIPS_GOT_LO16: howto manager. (line 344) 10050* BFD_RELOC_MIPS_GOT_OFST: howto manager. (line 349) 10051* BFD_RELOC_MIPS_GOT_PAGE: howto manager. (line 348) 10052* BFD_RELOC_MIPS_HIGHER: howto manager. (line 357) 10053* BFD_RELOC_MIPS_HIGHEST: howto manager. (line 356) 10054* BFD_RELOC_MIPS_INSERT_A: howto manager. (line 353) 10055* BFD_RELOC_MIPS_INSERT_B: howto manager. (line 354) 10056* BFD_RELOC_MIPS_JALR: howto manager. (line 361) 10057* BFD_RELOC_MIPS_JMP: howto manager. (line 295) 10058* BFD_RELOC_MIPS_JUMP_SLOT: howto manager. (line 378) 10059* BFD_RELOC_MIPS_LITERAL: howto manager. (line 338) 10060* BFD_RELOC_MIPS_REL16: howto manager. (line 359) 10061* BFD_RELOC_MIPS_RELGOT: howto manager. (line 360) 10062* BFD_RELOC_MIPS_SCN_DISP: howto manager. (line 358) 10063* BFD_RELOC_MIPS_SHIFT5: howto manager. (line 351) 10064* BFD_RELOC_MIPS_SHIFT6: howto manager. (line 352) 10065* BFD_RELOC_MIPS_SUB: howto manager. (line 347) 10066* BFD_RELOC_MIPS_TLS_DTPMOD32: howto manager. (line 362) 10067* BFD_RELOC_MIPS_TLS_DTPMOD64: howto manager. (line 364) 10068* BFD_RELOC_MIPS_TLS_DTPREL32: howto manager. (line 363) 10069* BFD_RELOC_MIPS_TLS_DTPREL64: howto manager. (line 365) 10070* BFD_RELOC_MIPS_TLS_DTPREL_HI16: howto manager. (line 368) 10071* BFD_RELOC_MIPS_TLS_DTPREL_LO16: howto manager. (line 369) 10072* BFD_RELOC_MIPS_TLS_GD: howto manager. (line 366) 10073* BFD_RELOC_MIPS_TLS_GOTTPREL: howto manager. (line 370) 10074* BFD_RELOC_MIPS_TLS_LDM: howto manager. (line 367) 10075* BFD_RELOC_MIPS_TLS_TPREL32: howto manager. (line 371) 10076* BFD_RELOC_MIPS_TLS_TPREL64: howto manager. (line 372) 10077* BFD_RELOC_MIPS_TLS_TPREL_HI16: howto manager. (line 373) 10078* BFD_RELOC_MIPS_TLS_TPREL_LO16: howto manager. (line 374) 10079* BFD_RELOC_MMIX_ADDR19: howto manager. (line 1310) 10080* BFD_RELOC_MMIX_ADDR27: howto manager. (line 1314) 10081* BFD_RELOC_MMIX_BASE_PLUS_OFFSET: howto manager. (line 1326) 10082* BFD_RELOC_MMIX_CBRANCH: howto manager. (line 1290) 10083* BFD_RELOC_MMIX_CBRANCH_1: howto manager. (line 1292) 10084* BFD_RELOC_MMIX_CBRANCH_2: howto manager. (line 1293) 10085* BFD_RELOC_MMIX_CBRANCH_3: howto manager. (line 1294) 10086* BFD_RELOC_MMIX_CBRANCH_J: howto manager. (line 1291) 10087* BFD_RELOC_MMIX_GETA: howto manager. (line 1284) 10088* BFD_RELOC_MMIX_GETA_1: howto manager. (line 1285) 10089* BFD_RELOC_MMIX_GETA_2: howto manager. (line 1286) 10090* BFD_RELOC_MMIX_GETA_3: howto manager. (line 1287) 10091* BFD_RELOC_MMIX_JMP: howto manager. (line 1304) 10092* BFD_RELOC_MMIX_JMP_1: howto manager. (line 1305) 10093* BFD_RELOC_MMIX_JMP_2: howto manager. (line 1306) 10094* BFD_RELOC_MMIX_JMP_3: howto manager. (line 1307) 10095* BFD_RELOC_MMIX_LOCAL: howto manager. (line 1330) 10096* BFD_RELOC_MMIX_PUSHJ: howto manager. (line 1297) 10097* BFD_RELOC_MMIX_PUSHJ_1: howto manager. (line 1298) 10098* BFD_RELOC_MMIX_PUSHJ_2: howto manager. (line 1299) 10099* BFD_RELOC_MMIX_PUSHJ_3: howto manager. (line 1300) 10100* BFD_RELOC_MMIX_PUSHJ_STUBBABLE: howto manager. (line 1301) 10101* BFD_RELOC_MMIX_REG: howto manager. (line 1322) 10102* BFD_RELOC_MMIX_REG_OR_BYTE: howto manager. (line 1318) 10103* BFD_RELOC_MN10300_16_PCREL: howto manager. (line 1192) 10104* BFD_RELOC_MN10300_32_PCREL: howto manager. (line 1188) 10105* BFD_RELOC_MN10300_COPY: howto manager. (line 437) 10106* BFD_RELOC_MN10300_GLOB_DAT: howto manager. (line 440) 10107* BFD_RELOC_MN10300_GOT16: howto manager. (line 433) 10108* BFD_RELOC_MN10300_GOT24: howto manager. (line 429) 10109* BFD_RELOC_MN10300_GOT32: howto manager. (line 425) 10110* BFD_RELOC_MN10300_GOTOFF24: howto manager. (line 422) 10111* BFD_RELOC_MN10300_JMP_SLOT: howto manager. (line 443) 10112* BFD_RELOC_MN10300_RELATIVE: howto manager. (line 446) 10113* BFD_RELOC_MSP430_10_PCREL: howto manager. (line 1962) 10114* BFD_RELOC_MSP430_16: howto manager. (line 1964) 10115* BFD_RELOC_MSP430_16_BYTE: howto manager. (line 1966) 10116* BFD_RELOC_MSP430_16_PCREL: howto manager. (line 1963) 10117* BFD_RELOC_MSP430_16_PCREL_BYTE: howto manager. (line 1965) 10118* BFD_RELOC_MSP430_2X_PCREL: howto manager. (line 1967) 10119* BFD_RELOC_MSP430_RL_PCREL: howto manager. (line 1968) 10120* BFD_RELOC_MT_GNU_VTENTRY: howto manager. (line 1956) 10121* BFD_RELOC_MT_GNU_VTINHERIT: howto manager. (line 1953) 10122* BFD_RELOC_MT_HI16: howto manager. (line 1947) 10123* BFD_RELOC_MT_LO16: howto manager. (line 1950) 10124* BFD_RELOC_MT_PC16: howto manager. (line 1944) 10125* BFD_RELOC_MT_PCINSN8: howto manager. (line 1959) 10126* BFD_RELOC_NONE: howto manager. (line 116) 10127* BFD_RELOC_NS32K_DISP_16: howto manager. (line 509) 10128* BFD_RELOC_NS32K_DISP_16_PCREL: howto manager. (line 512) 10129* BFD_RELOC_NS32K_DISP_32: howto manager. (line 510) 10130* BFD_RELOC_NS32K_DISP_32_PCREL: howto manager. (line 513) 10131* BFD_RELOC_NS32K_DISP_8: howto manager. (line 508) 10132* BFD_RELOC_NS32K_DISP_8_PCREL: howto manager. (line 511) 10133* BFD_RELOC_NS32K_IMM_16: howto manager. (line 503) 10134* BFD_RELOC_NS32K_IMM_16_PCREL: howto manager. (line 506) 10135* BFD_RELOC_NS32K_IMM_32: howto manager. (line 504) 10136* BFD_RELOC_NS32K_IMM_32_PCREL: howto manager. (line 507) 10137* BFD_RELOC_NS32K_IMM_8: howto manager. (line 502) 10138* BFD_RELOC_NS32K_IMM_8_PCREL: howto manager. (line 505) 10139* BFD_RELOC_OPENRISC_ABS_26: howto manager. (line 1913) 10140* BFD_RELOC_OPENRISC_REL_26: howto manager. (line 1914) 10141* BFD_RELOC_PDP11_DISP_6_PCREL: howto manager. (line 517) 10142* BFD_RELOC_PDP11_DISP_8_PCREL: howto manager. (line 516) 10143* BFD_RELOC_PJ_CODE_DIR16: howto manager. (line 522) 10144* BFD_RELOC_PJ_CODE_DIR32: howto manager. (line 523) 10145* BFD_RELOC_PJ_CODE_HI16: howto manager. (line 520) 10146* BFD_RELOC_PJ_CODE_LO16: howto manager. (line 521) 10147* BFD_RELOC_PJ_CODE_REL16: howto manager. (line 524) 10148* BFD_RELOC_PJ_CODE_REL32: howto manager. (line 525) 10149* BFD_RELOC_PPC64_ADDR16_DS: howto manager. (line 570) 10150* BFD_RELOC_PPC64_ADDR16_LO_DS: howto manager. (line 571) 10151* BFD_RELOC_PPC64_DTPREL16_DS: howto manager. (line 617) 10152* BFD_RELOC_PPC64_DTPREL16_HIGHER: howto manager. (line 619) 10153* BFD_RELOC_PPC64_DTPREL16_HIGHERA: howto manager. (line 620) 10154* BFD_RELOC_PPC64_DTPREL16_HIGHEST: howto manager. (line 621) 10155* BFD_RELOC_PPC64_DTPREL16_HIGHESTA: howto manager. (line 622) 10156* BFD_RELOC_PPC64_DTPREL16_LO_DS: howto manager. (line 618) 10157* BFD_RELOC_PPC64_GOT16_DS: howto manager. (line 572) 10158* BFD_RELOC_PPC64_GOT16_LO_DS: howto manager. (line 573) 10159* BFD_RELOC_PPC64_HIGHER: howto manager. (line 558) 10160* BFD_RELOC_PPC64_HIGHER_S: howto manager. (line 559) 10161* BFD_RELOC_PPC64_HIGHEST: howto manager. (line 560) 10162* BFD_RELOC_PPC64_HIGHEST_S: howto manager. (line 561) 10163* BFD_RELOC_PPC64_PLT16_LO_DS: howto manager. (line 574) 10164* BFD_RELOC_PPC64_PLTGOT16: howto manager. (line 566) 10165* BFD_RELOC_PPC64_PLTGOT16_DS: howto manager. (line 579) 10166* BFD_RELOC_PPC64_PLTGOT16_HA: howto manager. (line 569) 10167* BFD_RELOC_PPC64_PLTGOT16_HI: howto manager. (line 568) 10168* BFD_RELOC_PPC64_PLTGOT16_LO: howto manager. (line 567) 10169* BFD_RELOC_PPC64_PLTGOT16_LO_DS: howto manager. (line 580) 10170* BFD_RELOC_PPC64_SECTOFF_DS: howto manager. (line 575) 10171* BFD_RELOC_PPC64_SECTOFF_LO_DS: howto manager. (line 576) 10172* BFD_RELOC_PPC64_TOC: howto manager. (line 565) 10173* BFD_RELOC_PPC64_TOC16_DS: howto manager. (line 577) 10174* BFD_RELOC_PPC64_TOC16_HA: howto manager. (line 564) 10175* BFD_RELOC_PPC64_TOC16_HI: howto manager. (line 563) 10176* BFD_RELOC_PPC64_TOC16_LO: howto manager. (line 562) 10177* BFD_RELOC_PPC64_TOC16_LO_DS: howto manager. (line 578) 10178* BFD_RELOC_PPC64_TPREL16_DS: howto manager. (line 611) 10179* BFD_RELOC_PPC64_TPREL16_HIGHER: howto manager. (line 613) 10180* BFD_RELOC_PPC64_TPREL16_HIGHERA: howto manager. (line 614) 10181* BFD_RELOC_PPC64_TPREL16_HIGHEST: howto manager. (line 615) 10182* BFD_RELOC_PPC64_TPREL16_HIGHESTA: howto manager. (line 616) 10183* BFD_RELOC_PPC64_TPREL16_LO_DS: howto manager. (line 612) 10184* BFD_RELOC_PPC_B16: howto manager. (line 531) 10185* BFD_RELOC_PPC_B16_BRNTAKEN: howto manager. (line 533) 10186* BFD_RELOC_PPC_B16_BRTAKEN: howto manager. (line 532) 10187* BFD_RELOC_PPC_B26: howto manager. (line 528) 10188* BFD_RELOC_PPC_BA16: howto manager. (line 534) 10189* BFD_RELOC_PPC_BA16_BRNTAKEN: howto manager. (line 536) 10190* BFD_RELOC_PPC_BA16_BRTAKEN: howto manager. (line 535) 10191* BFD_RELOC_PPC_BA26: howto manager. (line 529) 10192* BFD_RELOC_PPC_COPY: howto manager. (line 537) 10193* BFD_RELOC_PPC_DTPMOD: howto manager. (line 584) 10194* BFD_RELOC_PPC_DTPREL: howto manager. (line 594) 10195* BFD_RELOC_PPC_DTPREL16: howto manager. (line 590) 10196* BFD_RELOC_PPC_DTPREL16_HA: howto manager. (line 593) 10197* BFD_RELOC_PPC_DTPREL16_HI: howto manager. (line 592) 10198* BFD_RELOC_PPC_DTPREL16_LO: howto manager. (line 591) 10199* BFD_RELOC_PPC_EMB_BIT_FLD: howto manager. (line 556) 10200* BFD_RELOC_PPC_EMB_MRKREF: howto manager. (line 551) 10201* BFD_RELOC_PPC_EMB_NADDR16: howto manager. (line 543) 10202* BFD_RELOC_PPC_EMB_NADDR16_HA: howto manager. (line 546) 10203* BFD_RELOC_PPC_EMB_NADDR16_HI: howto manager. (line 545) 10204* BFD_RELOC_PPC_EMB_NADDR16_LO: howto manager. (line 544) 10205* BFD_RELOC_PPC_EMB_NADDR32: howto manager. (line 542) 10206* BFD_RELOC_PPC_EMB_RELSDA: howto manager. (line 557) 10207* BFD_RELOC_PPC_EMB_RELSEC16: howto manager. (line 552) 10208* BFD_RELOC_PPC_EMB_RELST_HA: howto manager. (line 555) 10209* BFD_RELOC_PPC_EMB_RELST_HI: howto manager. (line 554) 10210* BFD_RELOC_PPC_EMB_RELST_LO: howto manager. (line 553) 10211* BFD_RELOC_PPC_EMB_SDA21: howto manager. (line 550) 10212* BFD_RELOC_PPC_EMB_SDA2I16: howto manager. (line 548) 10213* BFD_RELOC_PPC_EMB_SDA2REL: howto manager. (line 549) 10214* BFD_RELOC_PPC_EMB_SDAI16: howto manager. (line 547) 10215* BFD_RELOC_PPC_GLOB_DAT: howto manager. (line 538) 10216* BFD_RELOC_PPC_GOT_DTPREL16: howto manager. (line 607) 10217* BFD_RELOC_PPC_GOT_DTPREL16_HA: howto manager. (line 610) 10218* BFD_RELOC_PPC_GOT_DTPREL16_HI: howto manager. (line 609) 10219* BFD_RELOC_PPC_GOT_DTPREL16_LO: howto manager. (line 608) 10220* BFD_RELOC_PPC_GOT_TLSGD16: howto manager. (line 595) 10221* BFD_RELOC_PPC_GOT_TLSGD16_HA: howto manager. (line 598) 10222* BFD_RELOC_PPC_GOT_TLSGD16_HI: howto manager. (line 597) 10223* BFD_RELOC_PPC_GOT_TLSGD16_LO: howto manager. (line 596) 10224* BFD_RELOC_PPC_GOT_TLSLD16: howto manager. (line 599) 10225* BFD_RELOC_PPC_GOT_TLSLD16_HA: howto manager. (line 602) 10226* BFD_RELOC_PPC_GOT_TLSLD16_HI: howto manager. (line 601) 10227* BFD_RELOC_PPC_GOT_TLSLD16_LO: howto manager. (line 600) 10228* BFD_RELOC_PPC_GOT_TPREL16: howto manager. (line 603) 10229* BFD_RELOC_PPC_GOT_TPREL16_HA: howto manager. (line 606) 10230* BFD_RELOC_PPC_GOT_TPREL16_HI: howto manager. (line 605) 10231* BFD_RELOC_PPC_GOT_TPREL16_LO: howto manager. (line 604) 10232* BFD_RELOC_PPC_JMP_SLOT: howto manager. (line 539) 10233* BFD_RELOC_PPC_LOCAL24PC: howto manager. (line 541) 10234* BFD_RELOC_PPC_RELATIVE: howto manager. (line 540) 10235* BFD_RELOC_PPC_TLS: howto manager. (line 583) 10236* BFD_RELOC_PPC_TOC16: howto manager. (line 530) 10237* BFD_RELOC_PPC_TPREL: howto manager. (line 589) 10238* BFD_RELOC_PPC_TPREL16: howto manager. (line 585) 10239* BFD_RELOC_PPC_TPREL16_HA: howto manager. (line 588) 10240* BFD_RELOC_PPC_TPREL16_HI: howto manager. (line 587) 10241* BFD_RELOC_PPC_TPREL16_LO: howto manager. (line 586) 10242* BFD_RELOC_RELC: howto manager. (line 1930) 10243* BFD_RELOC_RVA: howto manager. (line 85) 10244* BFD_RELOC_SCORE16_BRANCH: howto manager. (line 1559) 10245* BFD_RELOC_SCORE16_JMP: howto manager. (line 1556) 10246* BFD_RELOC_SCORE_BRANCH: howto manager. (line 1553) 10247* BFD_RELOC_SCORE_CALL15: howto manager. (line 1564) 10248* BFD_RELOC_SCORE_DUMMY1: howto manager. (line 1543) 10249* BFD_RELOC_SCORE_DUMMY2: howto manager. (line 1549) 10250* BFD_RELOC_SCORE_DUMMY_HI16: howto manager. (line 1565) 10251* BFD_RELOC_SCORE_GOT15: howto manager. (line 1562) 10252* BFD_RELOC_SCORE_GOT_LO16: howto manager. (line 1563) 10253* BFD_RELOC_SCORE_GPREL15: howto manager. (line 1546) 10254* BFD_RELOC_SCORE_JMP: howto manager. (line 1550) 10255* BFD_RELOC_SH_ALIGN: howto manager. (line 802) 10256* BFD_RELOC_SH_CODE: howto manager. (line 803) 10257* BFD_RELOC_SH_COPY: howto manager. (line 808) 10258* BFD_RELOC_SH_COPY64: howto manager. (line 833) 10259* BFD_RELOC_SH_COUNT: howto manager. (line 801) 10260* BFD_RELOC_SH_DATA: howto manager. (line 804) 10261* BFD_RELOC_SH_DISP12: howto manager. (line 784) 10262* BFD_RELOC_SH_DISP12BY2: howto manager. (line 785) 10263* BFD_RELOC_SH_DISP12BY4: howto manager. (line 786) 10264* BFD_RELOC_SH_DISP12BY8: howto manager. (line 787) 10265* BFD_RELOC_SH_DISP20: howto manager. (line 788) 10266* BFD_RELOC_SH_DISP20BY8: howto manager. (line 789) 10267* BFD_RELOC_SH_GLOB_DAT: howto manager. (line 809) 10268* BFD_RELOC_SH_GLOB_DAT64: howto manager. (line 834) 10269* BFD_RELOC_SH_GOT10BY4: howto manager. (line 837) 10270* BFD_RELOC_SH_GOT10BY8: howto manager. (line 838) 10271* BFD_RELOC_SH_GOT_HI16: howto manager. (line 816) 10272* BFD_RELOC_SH_GOT_LOW16: howto manager. (line 813) 10273* BFD_RELOC_SH_GOT_MEDHI16: howto manager. (line 815) 10274* BFD_RELOC_SH_GOT_MEDLOW16: howto manager. (line 814) 10275* BFD_RELOC_SH_GOTOFF_HI16: howto manager. (line 828) 10276* BFD_RELOC_SH_GOTOFF_LOW16: howto manager. (line 825) 10277* BFD_RELOC_SH_GOTOFF_MEDHI16: howto manager. (line 827) 10278* BFD_RELOC_SH_GOTOFF_MEDLOW16: howto manager. (line 826) 10279* BFD_RELOC_SH_GOTPC: howto manager. (line 812) 10280* BFD_RELOC_SH_GOTPC_HI16: howto manager. (line 832) 10281* BFD_RELOC_SH_GOTPC_LOW16: howto manager. (line 829) 10282* BFD_RELOC_SH_GOTPC_MEDHI16: howto manager. (line 831) 10283* BFD_RELOC_SH_GOTPC_MEDLOW16: howto manager. (line 830) 10284* BFD_RELOC_SH_GOTPLT10BY4: howto manager. (line 839) 10285* BFD_RELOC_SH_GOTPLT10BY8: howto manager. (line 840) 10286* BFD_RELOC_SH_GOTPLT32: howto manager. (line 841) 10287* BFD_RELOC_SH_GOTPLT_HI16: howto manager. (line 820) 10288* BFD_RELOC_SH_GOTPLT_LOW16: howto manager. (line 817) 10289* BFD_RELOC_SH_GOTPLT_MEDHI16: howto manager. (line 819) 10290* BFD_RELOC_SH_GOTPLT_MEDLOW16: howto manager. (line 818) 10291* BFD_RELOC_SH_IMM3: howto manager. (line 782) 10292* BFD_RELOC_SH_IMM3U: howto manager. (line 783) 10293* BFD_RELOC_SH_IMM4: howto manager. (line 790) 10294* BFD_RELOC_SH_IMM4BY2: howto manager. (line 791) 10295* BFD_RELOC_SH_IMM4BY4: howto manager. (line 792) 10296* BFD_RELOC_SH_IMM8: howto manager. (line 793) 10297* BFD_RELOC_SH_IMM8BY2: howto manager. (line 794) 10298* BFD_RELOC_SH_IMM8BY4: howto manager. (line 795) 10299* BFD_RELOC_SH_IMM_HI16: howto manager. (line 859) 10300* BFD_RELOC_SH_IMM_HI16_PCREL: howto manager. (line 860) 10301* BFD_RELOC_SH_IMM_LOW16: howto manager. (line 853) 10302* BFD_RELOC_SH_IMM_LOW16_PCREL: howto manager. (line 854) 10303* BFD_RELOC_SH_IMM_MEDHI16: howto manager. (line 857) 10304* BFD_RELOC_SH_IMM_MEDHI16_PCREL: howto manager. (line 858) 10305* BFD_RELOC_SH_IMM_MEDLOW16: howto manager. (line 855) 10306* BFD_RELOC_SH_IMM_MEDLOW16_PCREL: howto manager. (line 856) 10307* BFD_RELOC_SH_IMMS10: howto manager. (line 847) 10308* BFD_RELOC_SH_IMMS10BY2: howto manager. (line 848) 10309* BFD_RELOC_SH_IMMS10BY4: howto manager. (line 849) 10310* BFD_RELOC_SH_IMMS10BY8: howto manager. (line 850) 10311* BFD_RELOC_SH_IMMS16: howto manager. (line 851) 10312* BFD_RELOC_SH_IMMS6: howto manager. (line 844) 10313* BFD_RELOC_SH_IMMS6BY32: howto manager. (line 845) 10314* BFD_RELOC_SH_IMMU16: howto manager. (line 852) 10315* BFD_RELOC_SH_IMMU5: howto manager. (line 843) 10316* BFD_RELOC_SH_IMMU6: howto manager. (line 846) 10317* BFD_RELOC_SH_JMP_SLOT: howto manager. (line 810) 10318* BFD_RELOC_SH_JMP_SLOT64: howto manager. (line 835) 10319* BFD_RELOC_SH_LABEL: howto manager. (line 805) 10320* BFD_RELOC_SH_LOOP_END: howto manager. (line 807) 10321* BFD_RELOC_SH_LOOP_START: howto manager. (line 806) 10322* BFD_RELOC_SH_PCDISP12BY2: howto manager. (line 781) 10323* BFD_RELOC_SH_PCDISP8BY2: howto manager. (line 780) 10324* BFD_RELOC_SH_PCRELIMM8BY2: howto manager. (line 796) 10325* BFD_RELOC_SH_PCRELIMM8BY4: howto manager. (line 797) 10326* BFD_RELOC_SH_PLT_HI16: howto manager. (line 824) 10327* BFD_RELOC_SH_PLT_LOW16: howto manager. (line 821) 10328* BFD_RELOC_SH_PLT_MEDHI16: howto manager. (line 823) 10329* BFD_RELOC_SH_PLT_MEDLOW16: howto manager. (line 822) 10330* BFD_RELOC_SH_PT_16: howto manager. (line 861) 10331* BFD_RELOC_SH_RELATIVE: howto manager. (line 811) 10332* BFD_RELOC_SH_RELATIVE64: howto manager. (line 836) 10333* BFD_RELOC_SH_SHMEDIA_CODE: howto manager. (line 842) 10334* BFD_RELOC_SH_SWITCH16: howto manager. (line 798) 10335* BFD_RELOC_SH_SWITCH32: howto manager. (line 799) 10336* BFD_RELOC_SH_TLS_DTPMOD32: howto manager. (line 867) 10337* BFD_RELOC_SH_TLS_DTPOFF32: howto manager. (line 868) 10338* BFD_RELOC_SH_TLS_GD_32: howto manager. (line 862) 10339* BFD_RELOC_SH_TLS_IE_32: howto manager. (line 865) 10340* BFD_RELOC_SH_TLS_LD_32: howto manager. (line 863) 10341* BFD_RELOC_SH_TLS_LDO_32: howto manager. (line 864) 10342* BFD_RELOC_SH_TLS_LE_32: howto manager. (line 866) 10343* BFD_RELOC_SH_TLS_TPOFF32: howto manager. (line 869) 10344* BFD_RELOC_SH_USES: howto manager. (line 800) 10345* BFD_RELOC_SPARC13: howto manager. (line 119) 10346* BFD_RELOC_SPARC22: howto manager. (line 118) 10347* BFD_RELOC_SPARC_10: howto manager. (line 141) 10348* BFD_RELOC_SPARC_11: howto manager. (line 142) 10349* BFD_RELOC_SPARC_5: howto manager. (line 154) 10350* BFD_RELOC_SPARC_6: howto manager. (line 153) 10351* BFD_RELOC_SPARC_64: howto manager. (line 140) 10352* BFD_RELOC_SPARC_7: howto manager. (line 152) 10353* BFD_RELOC_SPARC_BASE13: howto manager. (line 136) 10354* BFD_RELOC_SPARC_BASE22: howto manager. (line 137) 10355* BFD_RELOC_SPARC_COPY: howto manager. (line 126) 10356* BFD_RELOC_SPARC_DISP64: howto manager. (line 155) 10357* BFD_RELOC_SPARC_GLOB_DAT: howto manager. (line 127) 10358* BFD_RELOC_SPARC_GOT10: howto manager. (line 120) 10359* BFD_RELOC_SPARC_GOT13: howto manager. (line 121) 10360* BFD_RELOC_SPARC_GOT22: howto manager. (line 122) 10361* BFD_RELOC_SPARC_H44: howto manager. (line 160) 10362* BFD_RELOC_SPARC_HH22: howto manager. (line 144) 10363* BFD_RELOC_SPARC_HIX22: howto manager. (line 158) 10364* BFD_RELOC_SPARC_HM10: howto manager. (line 145) 10365* BFD_RELOC_SPARC_JMP_SLOT: howto manager. (line 128) 10366* BFD_RELOC_SPARC_L44: howto manager. (line 162) 10367* BFD_RELOC_SPARC_LM22: howto manager. (line 146) 10368* BFD_RELOC_SPARC_LOX10: howto manager. (line 159) 10369* BFD_RELOC_SPARC_M44: howto manager. (line 161) 10370* BFD_RELOC_SPARC_OLO10: howto manager. (line 143) 10371* BFD_RELOC_SPARC_PC10: howto manager. (line 123) 10372* BFD_RELOC_SPARC_PC22: howto manager. (line 124) 10373* BFD_RELOC_SPARC_PC_HH22: howto manager. (line 147) 10374* BFD_RELOC_SPARC_PC_HM10: howto manager. (line 148) 10375* BFD_RELOC_SPARC_PC_LM22: howto manager. (line 149) 10376* BFD_RELOC_SPARC_PLT32: howto manager. (line 156) 10377* BFD_RELOC_SPARC_PLT64: howto manager. (line 157) 10378* BFD_RELOC_SPARC_REGISTER: howto manager. (line 163) 10379* BFD_RELOC_SPARC_RELATIVE: howto manager. (line 129) 10380* BFD_RELOC_SPARC_REV32: howto manager. (line 166) 10381* BFD_RELOC_SPARC_TLS_DTPMOD32: howto manager. (line 187) 10382* BFD_RELOC_SPARC_TLS_DTPMOD64: howto manager. (line 188) 10383* BFD_RELOC_SPARC_TLS_DTPOFF32: howto manager. (line 189) 10384* BFD_RELOC_SPARC_TLS_DTPOFF64: howto manager. (line 190) 10385* BFD_RELOC_SPARC_TLS_GD_ADD: howto manager. (line 171) 10386* BFD_RELOC_SPARC_TLS_GD_CALL: howto manager. (line 172) 10387* BFD_RELOC_SPARC_TLS_GD_HI22: howto manager. (line 169) 10388* BFD_RELOC_SPARC_TLS_GD_LO10: howto manager. (line 170) 10389* BFD_RELOC_SPARC_TLS_IE_ADD: howto manager. (line 184) 10390* BFD_RELOC_SPARC_TLS_IE_HI22: howto manager. (line 180) 10391* BFD_RELOC_SPARC_TLS_IE_LD: howto manager. (line 182) 10392* BFD_RELOC_SPARC_TLS_IE_LDX: howto manager. (line 183) 10393* BFD_RELOC_SPARC_TLS_IE_LO10: howto manager. (line 181) 10394* BFD_RELOC_SPARC_TLS_LDM_ADD: howto manager. (line 175) 10395* BFD_RELOC_SPARC_TLS_LDM_CALL: howto manager. (line 176) 10396* BFD_RELOC_SPARC_TLS_LDM_HI22: howto manager. (line 173) 10397* BFD_RELOC_SPARC_TLS_LDM_LO10: howto manager. (line 174) 10398* BFD_RELOC_SPARC_TLS_LDO_ADD: howto manager. (line 179) 10399* BFD_RELOC_SPARC_TLS_LDO_HIX22: howto manager. (line 177) 10400* BFD_RELOC_SPARC_TLS_LDO_LOX10: howto manager. (line 178) 10401* BFD_RELOC_SPARC_TLS_LE_HIX22: howto manager. (line 185) 10402* BFD_RELOC_SPARC_TLS_LE_LOX10: howto manager. (line 186) 10403* BFD_RELOC_SPARC_TLS_TPOFF32: howto manager. (line 191) 10404* BFD_RELOC_SPARC_TLS_TPOFF64: howto manager. (line 192) 10405* BFD_RELOC_SPARC_UA16: howto manager. (line 130) 10406* BFD_RELOC_SPARC_UA32: howto manager. (line 131) 10407* BFD_RELOC_SPARC_UA64: howto manager. (line 132) 10408* BFD_RELOC_SPARC_WDISP16: howto manager. (line 150) 10409* BFD_RELOC_SPARC_WDISP19: howto manager. (line 151) 10410* BFD_RELOC_SPARC_WDISP22: howto manager. (line 117) 10411* BFD_RELOC_SPARC_WPLT30: howto manager. (line 125) 10412* BFD_RELOC_SPU_HI16: howto manager. (line 206) 10413* BFD_RELOC_SPU_IMM10: howto manager. (line 197) 10414* BFD_RELOC_SPU_IMM10W: howto manager. (line 198) 10415* BFD_RELOC_SPU_IMM16: howto manager. (line 199) 10416* BFD_RELOC_SPU_IMM16W: howto manager. (line 200) 10417* BFD_RELOC_SPU_IMM18: howto manager. (line 201) 10418* BFD_RELOC_SPU_IMM7: howto manager. (line 195) 10419* BFD_RELOC_SPU_IMM8: howto manager. (line 196) 10420* BFD_RELOC_SPU_LO16: howto manager. (line 205) 10421* BFD_RELOC_SPU_PCREL16: howto manager. (line 204) 10422* BFD_RELOC_SPU_PCREL9a: howto manager. (line 202) 10423* BFD_RELOC_SPU_PCREL9b: howto manager. (line 203) 10424* BFD_RELOC_SPU_PPU32: howto manager. (line 207) 10425* BFD_RELOC_SPU_PPU64: howto manager. (line 208) 10426* BFD_RELOC_THUMB_PCREL_BLX: howto manager. (line 643) 10427* BFD_RELOC_THUMB_PCREL_BRANCH12: howto manager. (line 657) 10428* BFD_RELOC_THUMB_PCREL_BRANCH20: howto manager. (line 658) 10429* BFD_RELOC_THUMB_PCREL_BRANCH23: howto manager. (line 659) 10430* BFD_RELOC_THUMB_PCREL_BRANCH25: howto manager. (line 660) 10431* BFD_RELOC_THUMB_PCREL_BRANCH7: howto manager. (line 655) 10432* BFD_RELOC_THUMB_PCREL_BRANCH9: howto manager. (line 656) 10433* BFD_RELOC_TIC30_LDP: howto manager. (line 1196) 10434* BFD_RELOC_TIC54X_16_OF_23: howto manager. (line 1214) 10435* BFD_RELOC_TIC54X_23: howto manager. (line 1211) 10436* BFD_RELOC_TIC54X_MS7_OF_23: howto manager. (line 1219) 10437* BFD_RELOC_TIC54X_PARTLS7: howto manager. (line 1201) 10438* BFD_RELOC_TIC54X_PARTMS9: howto manager. (line 1206) 10439* bfd_reloc_type_lookup: howto manager. (line 2068) 10440* BFD_RELOC_V850_22_PCREL: howto manager. (line 1123) 10441* BFD_RELOC_V850_9_PCREL: howto manager. (line 1120) 10442* BFD_RELOC_V850_ALIGN: howto manager. (line 1181) 10443* BFD_RELOC_V850_CALLT_16_16_OFFSET: howto manager. (line 1172) 10444* BFD_RELOC_V850_CALLT_6_7_OFFSET: howto manager. (line 1169) 10445* BFD_RELOC_V850_LO16_SPLIT_OFFSET: howto manager. (line 1184) 10446* BFD_RELOC_V850_LONGCALL: howto manager. (line 1175) 10447* BFD_RELOC_V850_LONGJUMP: howto manager. (line 1178) 10448* BFD_RELOC_V850_SDA_15_16_OFFSET: howto manager. (line 1129) 10449* BFD_RELOC_V850_SDA_16_16_OFFSET: howto manager. (line 1126) 10450* BFD_RELOC_V850_SDA_16_16_SPLIT_OFFSET: howto manager. (line 1161) 10451* BFD_RELOC_V850_TDA_16_16_OFFSET: howto manager. (line 1151) 10452* BFD_RELOC_V850_TDA_4_4_OFFSET: howto manager. (line 1158) 10453* BFD_RELOC_V850_TDA_4_5_OFFSET: howto manager. (line 1154) 10454* BFD_RELOC_V850_TDA_6_8_OFFSET: howto manager. (line 1140) 10455* BFD_RELOC_V850_TDA_7_7_OFFSET: howto manager. (line 1148) 10456* BFD_RELOC_V850_TDA_7_8_OFFSET: howto manager. (line 1144) 10457* BFD_RELOC_V850_ZDA_15_16_OFFSET: howto manager. (line 1136) 10458* BFD_RELOC_V850_ZDA_16_16_OFFSET: howto manager. (line 1133) 10459* BFD_RELOC_V850_ZDA_16_16_SPLIT_OFFSET: howto manager. (line 1165) 10460* BFD_RELOC_VAX_GLOB_DAT: howto manager. (line 1939) 10461* BFD_RELOC_VAX_JMP_SLOT: howto manager. (line 1940) 10462* BFD_RELOC_VAX_RELATIVE: howto manager. (line 1941) 10463* BFD_RELOC_VPE4KMATH_DATA: howto manager. (line 1598) 10464* BFD_RELOC_VPE4KMATH_INSN: howto manager. (line 1599) 10465* BFD_RELOC_VTABLE_ENTRY: howto manager. (line 1603) 10466* BFD_RELOC_VTABLE_INHERIT: howto manager. (line 1602) 10467* BFD_RELOC_X86_64_32S: howto manager. (line 481) 10468* BFD_RELOC_X86_64_COPY: howto manager. (line 476) 10469* BFD_RELOC_X86_64_DTPMOD64: howto manager. (line 482) 10470* BFD_RELOC_X86_64_DTPOFF32: howto manager. (line 487) 10471* BFD_RELOC_X86_64_DTPOFF64: howto manager. (line 483) 10472* BFD_RELOC_X86_64_GLOB_DAT: howto manager. (line 477) 10473* BFD_RELOC_X86_64_GOT32: howto manager. (line 474) 10474* BFD_RELOC_X86_64_GOT64: howto manager. (line 492) 10475* BFD_RELOC_X86_64_GOTOFF64: howto manager. (line 490) 10476* BFD_RELOC_X86_64_GOTPC32: howto manager. (line 491) 10477* BFD_RELOC_X86_64_GOTPC32_TLSDESC: howto manager. (line 497) 10478* BFD_RELOC_X86_64_GOTPC64: howto manager. (line 494) 10479* BFD_RELOC_X86_64_GOTPCREL: howto manager. (line 480) 10480* BFD_RELOC_X86_64_GOTPCREL64: howto manager. (line 493) 10481* BFD_RELOC_X86_64_GOTPLT64: howto manager. (line 495) 10482* BFD_RELOC_X86_64_GOTTPOFF: howto manager. (line 488) 10483* BFD_RELOC_X86_64_JUMP_SLOT: howto manager. (line 478) 10484* BFD_RELOC_X86_64_PLT32: howto manager. (line 475) 10485* BFD_RELOC_X86_64_PLTOFF64: howto manager. (line 496) 10486* BFD_RELOC_X86_64_RELATIVE: howto manager. (line 479) 10487* BFD_RELOC_X86_64_TLSDESC: howto manager. (line 499) 10488* BFD_RELOC_X86_64_TLSDESC_CALL: howto manager. (line 498) 10489* BFD_RELOC_X86_64_TLSGD: howto manager. (line 485) 10490* BFD_RELOC_X86_64_TLSLD: howto manager. (line 486) 10491* BFD_RELOC_X86_64_TPOFF32: howto manager. (line 489) 10492* BFD_RELOC_X86_64_TPOFF64: howto manager. (line 484) 10493* BFD_RELOC_XC16X_PAG: howto manager. (line 1933) 10494* BFD_RELOC_XC16X_POF: howto manager. (line 1934) 10495* BFD_RELOC_XC16X_SEG: howto manager. (line 1935) 10496* BFD_RELOC_XC16X_SOF: howto manager. (line 1936) 10497* BFD_RELOC_XSTORMY16_12: howto manager. (line 1925) 10498* BFD_RELOC_XSTORMY16_24: howto manager. (line 1926) 10499* BFD_RELOC_XSTORMY16_FPTR16: howto manager. (line 1927) 10500* BFD_RELOC_XSTORMY16_REL_12: howto manager. (line 1924) 10501* BFD_RELOC_XTENSA_ASM_EXPAND: howto manager. (line 2045) 10502* BFD_RELOC_XTENSA_ASM_SIMPLIFY: howto manager. (line 2050) 10503* BFD_RELOC_XTENSA_DIFF16: howto manager. (line 1992) 10504* BFD_RELOC_XTENSA_DIFF32: howto manager. (line 1993) 10505* BFD_RELOC_XTENSA_DIFF8: howto manager. (line 1991) 10506* BFD_RELOC_XTENSA_GLOB_DAT: howto manager. (line 1981) 10507* BFD_RELOC_XTENSA_JMP_SLOT: howto manager. (line 1982) 10508* BFD_RELOC_XTENSA_OP0: howto manager. (line 2039) 10509* BFD_RELOC_XTENSA_OP1: howto manager. (line 2040) 10510* BFD_RELOC_XTENSA_OP2: howto manager. (line 2041) 10511* BFD_RELOC_XTENSA_PLT: howto manager. (line 1986) 10512* BFD_RELOC_XTENSA_RELATIVE: howto manager. (line 1983) 10513* BFD_RELOC_XTENSA_RTLD: howto manager. (line 1976) 10514* BFD_RELOC_XTENSA_SLOT0_ALT: howto manager. (line 2021) 10515* BFD_RELOC_XTENSA_SLOT0_OP: howto manager. (line 2001) 10516* BFD_RELOC_XTENSA_SLOT10_ALT: howto manager. (line 2031) 10517* BFD_RELOC_XTENSA_SLOT10_OP: howto manager. (line 2011) 10518* BFD_RELOC_XTENSA_SLOT11_ALT: howto manager. (line 2032) 10519* BFD_RELOC_XTENSA_SLOT11_OP: howto manager. (line 2012) 10520* BFD_RELOC_XTENSA_SLOT12_ALT: howto manager. (line 2033) 10521* BFD_RELOC_XTENSA_SLOT12_OP: howto manager. (line 2013) 10522* BFD_RELOC_XTENSA_SLOT13_ALT: howto manager. (line 2034) 10523* BFD_RELOC_XTENSA_SLOT13_OP: howto manager. (line 2014) 10524* BFD_RELOC_XTENSA_SLOT14_ALT: howto manager. (line 2035) 10525* BFD_RELOC_XTENSA_SLOT14_OP: howto manager. (line 2015) 10526* BFD_RELOC_XTENSA_SLOT1_ALT: howto manager. (line 2022) 10527* BFD_RELOC_XTENSA_SLOT1_OP: howto manager. (line 2002) 10528* BFD_RELOC_XTENSA_SLOT2_ALT: howto manager. (line 2023) 10529* BFD_RELOC_XTENSA_SLOT2_OP: howto manager. (line 2003) 10530* BFD_RELOC_XTENSA_SLOT3_ALT: howto manager. (line 2024) 10531* BFD_RELOC_XTENSA_SLOT3_OP: howto manager. (line 2004) 10532* BFD_RELOC_XTENSA_SLOT4_ALT: howto manager. (line 2025) 10533* BFD_RELOC_XTENSA_SLOT4_OP: howto manager. (line 2005) 10534* BFD_RELOC_XTENSA_SLOT5_ALT: howto manager. (line 2026) 10535* BFD_RELOC_XTENSA_SLOT5_OP: howto manager. (line 2006) 10536* BFD_RELOC_XTENSA_SLOT6_ALT: howto manager. (line 2027) 10537* BFD_RELOC_XTENSA_SLOT6_OP: howto manager. (line 2007) 10538* BFD_RELOC_XTENSA_SLOT7_ALT: howto manager. (line 2028) 10539* BFD_RELOC_XTENSA_SLOT7_OP: howto manager. (line 2008) 10540* BFD_RELOC_XTENSA_SLOT8_ALT: howto manager. (line 2029) 10541* BFD_RELOC_XTENSA_SLOT8_OP: howto manager. (line 2009) 10542* BFD_RELOC_XTENSA_SLOT9_ALT: howto manager. (line 2030) 10543* BFD_RELOC_XTENSA_SLOT9_OP: howto manager. (line 2010) 10544* BFD_RELOC_Z80_DISP8: howto manager. (line 2055) 10545* BFD_RELOC_Z8K_CALLR: howto manager. (line 2061) 10546* BFD_RELOC_Z8K_DISP7: howto manager. (line 2058) 10547* BFD_RELOC_Z8K_IMM4L: howto manager. (line 2064) 10548* bfd_scan_arch: Architectures. (line 406) 10549* bfd_scan_vma: BFD front end. (line 426) 10550* bfd_seach_for_target: bfd_target. (line 464) 10551* bfd_section_already_linked: Writing the symbol table. 10552 (line 55) 10553* bfd_section_list_clear: section prototypes. (line 8) 10554* bfd_sections_find_if: section prototypes. (line 176) 10555* bfd_set_arch_info: Architectures. (line 447) 10556* bfd_set_archive_head: Archives. (line 69) 10557* bfd_set_default_target: bfd_target. (line 429) 10558* bfd_set_error: BFD front end. (line 236) 10559* bfd_set_error_handler: BFD front end. (line 278) 10560* bfd_set_error_program_name: BFD front end. (line 287) 10561* bfd_set_file_flags: BFD front end. (line 346) 10562* bfd_set_format: Formats. (line 68) 10563* bfd_set_gp_size: BFD front end. (line 416) 10564* bfd_set_private_flags: BFD front end. (line 493) 10565* bfd_set_reloc: BFD front end. (line 336) 10566* bfd_set_section_contents: section prototypes. (line 207) 10567* bfd_set_section_flags: section prototypes. (line 140) 10568* bfd_set_section_size: section prototypes. (line 193) 10569* bfd_set_start_address: BFD front end. (line 395) 10570* bfd_set_symtab: symbol handling functions. 10571 (line 60) 10572* bfd_symbol_info: symbol handling functions. 10573 (line 130) 10574* bfd_target_list: bfd_target. (line 455) 10575* bfd_write_bigendian_4byte_int: Internal. (line 13) 10576* bfd_zalloc: Opening and Closing. 10577 (line 228) 10578* bfd_zalloc2: Opening and Closing. 10579 (line 237) 10580* coff_symbol_type: coff. (line 186) 10581* core_file_matches_executable_p: Core Files. (line 30) 10582* find_separate_debug_file: Opening and Closing. 10583 (line 279) 10584* generic_core_file_matches_executable_p: Core Files. (line 40) 10585* get_debug_link_info: Opening and Closing. 10586 (line 260) 10587* Hash tables: Hash Tables. (line 6) 10588* internal object-file format: Canonical format. (line 11) 10589* Linker: Linker Functions. (line 6) 10590* Other functions: BFD front end. (line 508) 10591* separate_debug_file_exists: Opening and Closing. 10592 (line 270) 10593* struct bfd_iovec: BFD front end. (line 711) 10594* target vector (_bfd_final_link): Performing the Final Link. 10595 (line 6) 10596* target vector (_bfd_link_add_symbols): Adding Symbols to the Hash Table. 10597 (line 6) 10598* target vector (_bfd_link_hash_table_create): Creating a Linker Hash Table. 10599 (line 6) 10600* The HOWTO Macro: typedef arelent. (line 291) 10601* what is it?: Overview. (line 6) 10602 10603 10604 10605Tag Table: 10606Node: Top1045 10607Node: Overview1384 10608Node: History2435 10609Node: How It Works3381 10610Node: What BFD Version 2 Can Do4924 10611Node: BFD information loss6239 10612Node: Canonical format8771 10613Node: BFD front end13143 10614Node: Memory Usage40479 10615Node: Initialization41707 10616Node: Sections42166 10617Node: Section Input42649 10618Node: Section Output44014 10619Node: typedef asection46500 10620Node: section prototypes71101 10621Node: Symbols80781 10622Node: Reading Symbols82376 10623Node: Writing Symbols83483 10624Node: Mini Symbols85192 10625Node: typedef asymbol86166 10626Node: symbol handling functions91427 10627Node: Archives96769 10628Node: Formats100495 10629Node: Relocations103443 10630Node: typedef arelent104170 10631Node: howto manager119981 10632Node: Core Files186663 10633Node: Targets188480 10634Node: bfd_target190450 10635Node: Architectures210755 10636Node: Opening and Closing232762 10637Node: Internal244026 10638Node: File Caching250359 10639Node: Linker Functions252273 10640Node: Creating a Linker Hash Table253946 10641Node: Adding Symbols to the Hash Table255684 10642Node: Differing file formats256584 10643Node: Adding symbols from an object file258332 10644Node: Adding symbols from an archive260483 10645Node: Performing the Final Link262897 10646Node: Information provided by the linker264139 10647Node: Relocating the section contents265293 10648Node: Writing the symbol table267044 10649Node: Hash Tables270086 10650Node: Creating and Freeing a Hash Table271284 10651Node: Looking Up or Entering a String272534 10652Node: Traversing a Hash Table273787 10653Node: Deriving a New Hash Table Type274576 10654Node: Define the Derived Structures275642 10655Node: Write the Derived Creation Routine276723 10656Node: Write Other Derived Routines279347 10657Node: BFD back ends280662 10658Node: What to Put Where280932 10659Node: aout281112 10660Node: coff287430 10661Node: elf311907 10662Node: mmo312770 10663Node: File layout313698 10664Node: Symbol-table319345 10665Node: mmo section mapping323114 10666Node: GNU Free Documentation License326766 10667Node: BFD Index346495 10668 10669End Tag Table 10670