Home | History | Annotate | Download | only in bfd

Lines Matching refs:symbol

83 	Coff targets except that they use the external symbol format
193 and @code{coff_swap_lineno_in}. @code{GDB} reads the symbol
200 of all the symbol table and reloc drudgery itself, thereby
207 Symbol reading
210 enough to keep all the information available in a coff symbol
212 symbol table around, "behind the scenes".
214 When a symbol table is requested (through a call to
216 @code{coff_get_normalized_symtab}. This reads the symbol table from
219 (represented in the file by offsets from the first symbol in
223 pointer to another structure in the symbol table at one moment
228 rather than the normal text associated with the symbol
231 At this time the symbol names are moved around. Coff stores
233 within the symbol table; longer strings are kept at the end of
237 The symbol table is massaged once again, this time to create
238 the canonical table used by the BFD application. Each symbol
242 shares strings with the hidden internal symbol table.
248 Symbol writing
250 Writing a symbol to a coff file which didn't come from a coff
252 structure remembers the BFD from which the symbol was taken, and on
259 Symbol tables are provided for writing to the back end in a
261 the linker to accumulate and output large symbol tables
264 This function runs through the provided symbol table and
265 patches each symbol marked as a file place holder
268 the offset from the first symbol of the current symbol.
272 expects symbol values to be offsets from a section base; so a
273 symbol physically at 0x120, but in a section starting at
283 This routine runs though the provided symbol table and uses
285 generated when the symbol table was read in to create the
287 to a symbol into the index into the symbol table of the asymbol.
291 This routine runs through the symbol table and patches up the
309 . {* Remembers the offset from the first symbol in the file for
310 . this symbol. Generated by coff_renumber_symbols. *}
313 . {* Should the value of this symbol be renumbered. Used for
317 . {* Should the tag field of this symbol be renumbered.
321 . {* Should the endidx field of this symbol be renumbered.
329 . {* Fix up an XCOFF C_BINCL/C_EINCL symbol. The value is the
333 . {* The container for the symbol structure as read and translated
350 . {* The actual symbol which the rest of BFD works with *}
351 . asymbol symbol;
353 . {* A pointer to the hidden information for this symbol *}
356 . {* A pointer to the linenumber information for this symbol *}
905 the symbol table, of all places. We need to extract that
911 /* COMDAT sections are special. The first symbol is the section
912 symbol, which tells what kind of COMDAT section it is. The
913 second symbol is the "comdat symbol" - the one with the
914 unique name. GNU uses the section symbol for the unique
942 symbol" (section name). The second is the comdat
943 symbol name. Here, we've found the first
949 second one. It may be some other later symbol.
958 precisely the second symbol for the comdat name.
961 follows the $) as the comdat symbol. */
977 /* The first time we've seen the symbol. */
983 as the comdat symbol and the defining
984 symbol record (either C_STAT or C_EXT,
1008 _bfd_error_handler (_("%B: warning: COMDAT symbol '%s' does not match section name '%s'"),
1013 /* This is the section symbol. */
1069 /* There may be no symbol... we'll search
1082 default: /* 0 means "no symbol" */
1107 /* MSVC mode: the lexically second symbol (or
1113 /* This must the second symbol with the
1114 section #. It is the actual symbol name.
1124 coff_section_data (abfd, section)->comdat->symbol =
1152 look at the symbol table anyway, we return the symbol table index
1153 of the symbol being used as the COMDAT symbol. This is admittedly
1155 required information. FIXME: Is the COMDAT symbol index used for
1325 #define get_index(symbol) ((symbol)->udata.i)
1333 .{* COFF symbol classifications. *}
1337 . {* Global symbol. *}
1339 . {* Common symbol. *}
1341 . {* Undefined symbol. *}
1343 . {* Local symbol. *}
1345 . {* PE section symbol. *}
1349 Special entry points for gdb to swap in coff symbol table parts:
1580 .#define bfd_coff_print_aux(abfd, file, base, symbol, aux, indaux)\
1582 . (abfd, file, base, symbol, aux, indaux))
1783 /* Set up the section symbol. */
1798 symbol information, since they'll be overridden by the BFD symbol
1800 in case this symbol winds up getting written out. The value 0
1807 coffsymbol (section->symbol)->native = native;
2018 /* These members communicate important constants about the symbol
2019 table to GDB's symbol-reading code. These `constants'
2271 architecture information from the first symbol, if it
2272 is a .file symbol. */
2496 /* Handle the csect auxent of a C_EXT, C_AIX_WEAKEXT or C_HIDEXT symbol. */
2501 combined_entry_type *symbol,
2505 BFD_ASSERT (symbol->is_sym);
2506 int n_sclass = symbol->u.syment.n_sclass;
2509 && indaux + 1 == symbol->u.syment.n_numaux)
2537 combined_entry_type *symbol,
2542 is the case for the lastfirst aux entry for a C_LEAFPROC symbol. */
2544 && symbol->is_sym
2545 && (symbol->u.syment.n_sclass == C_LEAFPROC
2546 || symbol->u.syment.n_sclass == C_LEAFSTAT
2547 || symbol->u.syment.n_sclass == C_LEAFEXT));
2563 combined_entry_type *symbol ATTRIBUTE_UNUSED,
2567 BFD_ASSERT (symbol->is_sym);
2570 if (CSECT_SYM_P (symbol->u.syment.n_sclass)
2571 && indaux + 1 == symbol->u.syment.n_numaux)
2622 @code{internal_reloc}. The symbol index to use is removed from
2623 the @code{offset} field in the symbol table supplied. The
2706 This is because the symbol was undefined (which means
2710 entries know which symbol index they point to. So we
2711 have to look up the output symbol here. */
2736 part doesn't have a symbol; it has an offset. So rebuilt
2750 /* This is a relocation relative to the absolute symbol. */
2755 /* Check to see if the symbol reloc points to a symbol
2756 we don't have in our symbol table. */
2760 _bfd_error_handler (_("%B: reloc against a non-existant symbol index: %ld"),
3607 /* Make a pass through the symbol table to count line number entries and
3851 /* PE stores COMDAT section information in the symbol table. If
3853 the symbol in the symbol table and modify it. */
3868 /* Remember the location of the first symbol in this
3873 /* See if this is the section symbol. */
3885 /* Here *PSYM is the section symbol for CURRENT. */
3925 /* The COMDAT symbol must be the first symbol from this
3926 section in the symbol table. In order to make this
3927 work, we move the COMDAT symbol before the first
3928 symbol we found in the search above. It's OK to
3929 rearrange the symbol table at this point, because
4487 the symbol associated with the function.
4493 table, and each symbol which marks a function is marked by
4509 if (s1->symbol.value < s2->symbol.value)
4511 else if (s1->symbol.value > s2->symbol.value)
4576 (_("%B: warning: illegal symbol index 0x%lx in line number entry %d"),
4588 (_("%B: warning: illegal symbol index 0x%lx in line number entry %d"),
4600 (_("%B: warning: illegal symbol in line number entry %d"),
4612 abfd, bfd_asymbol_name (&sym->symbol));
4615 if (sym->symbol.value < prev_offset)
4617 prev_offset = sym->symbol.value;
4689 /* Slurp in the symbol table, converting it to generic form. Note
4705 /* Read in the symbol table. */
4733 dst->symbol.the_bfd = abfd;
4735 dst->symbol.name = (char *) (src->u.syment._n._n_n._n_offset);
4738 dst->symbol.section = coff_section_from_bfd_index (abfd,
4740 dst->symbol.flags = 0;
4742 dst->symbol.value = 0;
4765 /* In PE, 0x68 (104) denotes a section symbol. */
4767 /* In PE, 0x69 (105) denotes a weak external symbol. */
4773 dst->symbol.flags = BSF_EXPORT | BSF_GLOBAL;
4775 /* PE sets the symbol to a value relative to the
4777 dst->symbol.value = src->u.syment.n_value;
4779 dst->symbol.value = (src->u.syment.n_value
4780 - dst->symbol.section->vma);
4785 dst->symbol.flags |= BSF_NOT_AT_END | BSF_FUNCTION;
4789 dst->symbol.section = bfd_com_section_ptr;
4790 dst->symbol.value = src->u.syment.n_value;
4794 dst->symbol.section = bfd_und_section_ptr;
4795 dst->symbol.value = 0;
4799 dst->symbol.flags |= BSF_EXPORT | BSF_SECTION_SYM;
4800 dst->symbol.value = 0;
4804 dst->symbol.flags = BSF_LOCAL;
4806 /* PE sets the symbol to a value relative to the
4808 dst->symbol.value = src->u.syment.n_value;
4810 dst->symbol.value = (src->u.syment.n_value
4811 - dst->symbol.section->vma);
4814 dst->symbol.flags |= BSF_NOT_AT_END | BSF_FUNCTION;
4819 /* A symbol with a csect entry should not go at the end. */
4821 dst->symbol.flags |= BSF_NOT_AT_END;
4826 dst->symbol.flags |= BSF_WEAK;
4830 dst->symbol.flags = BSF_LOCAL;
4833 dst->symbol.flags |= BSF_WEAK;
4852 dst->symbol.flags = BSF_DEBUGGING;
4854 dst->symbol.flags = BSF_LOCAL;
4858 if (dst->symbol.section)
4861 /* PE sets the symbol to a value relative to the
4863 dst->symbol.value = src->u.syment.n_value;
4865 dst->symbol.value = (src->u.syment.n_value
4866 - dst->symbol.section->vma);
4870 dst->symbol.value = src->u.syment.n_value;
4891 dst->symbol.flags = BSF_DEBUGGING;
4892 dst->symbol.value = (src->u.syment.n_value);
4913 dst->symbol.flags = BSF_DEBUGGING;
4914 dst->symbol.value = (src->u.syment.n_value);
4927 dst->symbol.flags = BSF_DEBUGGING;
4935 dst->symbol.value = 0;
4938 dst->symbol.section = sec;
4939 dst->symbol.value = ((src->u.syment.n_value
4948 dst->symbol.flags = BSF_DEBUGGING;
4950 /* The value is actually a symbol index. Save a pointer
4951 to the symbol instead of the index. FIXME: This
4955 dst->symbol.value = src->u.syment.n_value;
4964 /* PE sets the symbol to a value relative to the start
4966 dst->symbol.value = src->u.syment.n_value;
4967 if (strcmp (dst->symbol.name, ".bf") != 0)
4971 dst->symbol.flags = BSF_DEBUGGING;
4974 dst->symbol.flags = BSF_DEBUGGING | BSF_DEBUGGING_RELOC;
4978 dst->symbol.flags = BSF_LOCAL;
4979 dst->symbol.value = (src->u.syment.n_value
4980 - dst->symbol.section->vma);
4985 dst->symbol.value = src->u.syment.n_value;
4986 dst->symbol.flags = BSF_GLOBAL;
5007 class to represent a section symbol. */
5008 case C_LINE: /* line # reformatted as symbol table entry. */
5009 /* NT uses 0x67 for a weak symbol, not C_ALIAS. */
5017 case C_HIDDEN: /* Ext symbol in dmert public lib. */
5020 (_("%B: Unrecognized storage class %d for %s symbol `%s'"),
5022 dst->symbol.section->name, dst->symbol.name);
5023 dst->symbol.flags = BSF_DEBUGGING;
5024 dst->symbol.value = (src->u.syment.n_value);
5029 dst->symbol.udata.i = 0;
5058 /* Classify a COFF symbol. A couple of targets have globally visible
5104 The function is discarded, but the symbol table entry
5140 /* If it is not a global symbol, we presume it is a local symbol. */
5146 (_("warning: %B: local symbol `%s' has no section"),
5167 o Turn the symbol referenced in the relocation's symbol index
5168 into a pointer into the canonical symbol table.
5252 (_("%B: warning: illegal symbol index %ld in relocs"),
5277 /* Calculate any reloc addend by looking at the symbol. */
5998 UNDER, /* Leading symbol underscore. */ \
6049 UNDER, /* Leading symbol underscore. */ \
6100 UNDER, /* Leading symbol underscore. */ \