Lines Matching refs:section

1 @section Sections
3 section abstraction. A single BFD may have any number of
7 Sections are supported in BFD in @code{section.c}.
13 * section prototypes::
18 When a BFD is opened for reading, the section structures are
21 Each section has a name which describes the section in the
30 constructor data, or an application may add a section (using
32 BFD. For example, the linker creates an extra section
37 the section descriptor is created. Some targets may leave the
56 section must be written. (If the section is being created from
57 scratch, @code{output_section} should probably point to the section
62 the output sections. The output section structure can be
63 considered a filter for the input section: the output section
65 input section determines the offset into the output section of
68 E.g., to create a section "O", starting at 0x100, 0x123 long,
74 section name "A"
77 output_section -----------> section name "O"
79 section name "B" | size 0x123
86 The data within a section is stored in a @dfn{link_order}.
88 abstraction allows a section to grow and shrink within itself.
103 @node typedef asection, section prototypes, Section Output, Sections
105 Here is the section structure:
110 /* This structure is used for a comdat section, as in PE. A comdat
111 section is associated with a particular symbol. When the linker
112 sees a comdat section, it keeps only one of the sections with a
117 /* The name of the symbol associated with a comdat section. */
121 comdat section. This is only meaningful to the object file format
129 /* The name of the section; the name isn't a copy, the pointer is
136 /* Which section in the bfd; 0..n-1 as sections are created in a bfd. */
139 /* The next section in the list belonging to the BFD, or NULL. */
142 /* The field flags contains attributes of the section. Some
149 /* Tells the OS to allocate space for this section when loading.
150 This is clear for a section containing debug information only. */
153 /* Tells the OS to load the section from the file when loading.
154 This is clear for a .bss section. */
157 /* The section contains data still to be relocated, so there is
167 /* A signal to the OS that the section contains read only data. */
170 /* The section contains code only. */
173 /* The section contains data only. */
176 /* The section will reside in ROM. */
179 /* The section contains constructor information. This section
183 section for the type of name (e.g., @code{__CTOR_LIST__}), attaches
191 /* The section has contents - a data section could be
192 @code{SEC_ALLOC} | @code{SEC_HAS_CONTENTS}; a debug section could be
196 /* An instruction to the linker to not output the section
200 /* The section is a COFF shared library section. This flag is
201 only for the linker. If this type of section appears in
211 /* The section contains thread local data. */
214 /* The section has GOT references. This flag is only for the
217 in this section, which indicate to the linker that the section
222 /* The section contains common symbols (symbols may be defined
229 /* The section contains only debugging information. For
231 strip tests this flag to see if a section can be
235 /* The contents of this section are held in memory pointed to
240 /* The contents of this section are to be excluded by the
245 /* The contents of this section are to be sorted based on the sum of
248 appended to the end of the section in an unspecified order. */
252 discarded, rather than being combined into a single section as
279 /* This section was created by the linker as part of dynamic
285 /* This section should not be subject to garbage collection. */
288 /* This section contains "short" data, and should be placed
292 /* This section contains data which may be shared with other
296 /* When a section with this flag is being linked, then if the size of
297 the input section is less than a page, it should not cross a page
298 boundary. If the size of the input section is one page or more, it
302 /* Conditionally link this section; do not link if there are no
303 references found to any symbol in the section. */
306 /* Attempt to merge identical entities in the section.
315 /* This section contains data about section groups. */
318 /* End of section flags. */
332 output sections that have an input section. */
351 /* Nonzero if this section uses RELA relocations, rather than REL. */
357 /* Nonzero if this section needs the relax finalize pass. */
360 /* Nonzero if this section has a gp reloc. */
373 /* The virtual memory address of the section - where it will be
381 /* The load address of the section - where it would be in a
382 rom image; really only used for writing section header
386 /* The size of the section in octets, as it will be output.
387 Contains a value even if the section has no contents (e.g., the
391 /* The original size on disk of the section, in octets. Normally this
396 /* If this section is going to be output, then this value is the
397 offset in *bytes* into the output section of the first byte in the
398 input section (byte ==> smallest addressable unit on the
400 100th octet (8-bit quantity) in the output section, this value
405 /* The output section through which to map on output. */
408 /* The alignment requirement of the section, as an exponent of 2 -
412 /* If an input section, a pointer to a vector of relocation
413 records for the data in this section. */
416 /* If an output section, a pointer to a vector of pointers to
417 relocation records for the data in this section. */
426 /* File position of section data. */
454 /* Points to the kept section if this section is a link-once section,
458 /* When a section is being output, this value changes as more
462 /* What the section number is in the target world. */
467 /* If this is a constructor section then here is a list of the
471 /* The BFD which owns the section. */
474 /* A symbol which points at this section only. */
492 /* The absolute section. */
496 /* Pointer to the undefined section. */
500 /* Pointer to the common section. */
503 /* Pointer to the indirect section. */
518 #define bfd_get_section_size_before_reloc(section) \
519 ((section)->_raw_size)
520 #define bfd_get_section_size_after_reloc(section) \
521 ((section)->reloc_done ? (section)->_cooked_size \
551 @node section prototypes, , typedef asection, Sections
553 These are the functions exported by the section handling part of BFD.
562 Clears the section list, and also resets the section count and
578 @code{strcmp} on the name (or better yet, base it on the section flags
579 or something else) for each section.
589 Invent a section name that is unique in @var{abfd} by tacking
602 Create a new empty section called @var{name}
604 BFD @var{abfd}. An attempt to create a section with a name which
606 section chain.
629 Create a new empty section called @var{name} and attach it to the end of
630 the chain of sections for @var{abfd}. Create a new section even if there
631 is already a section with that name.
650 bfd_set_error ()) without changing the section chain if there is already a
651 section named @var{name}. If there is an error, return @code{NULL} and set
662 Set the attributes of the section @var{sec} in the BFD
670 The section cannot have one or more of the attributes
671 requested. For example, a .bss section in @code{a.out} may not
685 Call the provided function @var{func} for each section
697 section *p;
726 (bfd *abfd, asection *section, const void *data,
730 Sets the contents of the section @var{section} in BFD
732 data is written to the output section starting at offset
741 The output section does not have the @code{SEC_HAS_CONTENTS}
754 (bfd *abfd, asection *section, void *location, file_ptr offset,
758 Read data from @var{section} in BFD @var{abfd}
760 offset of @var{offset} from the start of the input section,
764 flag set are requested or if the section does not have the
777 Copy private section information from @var{isec} in the BFD
778 @var{ibfd} to the section @var{osec} in the BFD @var{obfd}.
799 (struct bfd_link_info *info, asection *section);
802 Remove @var{section} from the output. If the output section