* dwarfread.c (struct dwfinfo), dbxread.c (struct symloc),
mdebugread.c (struct symloc), hpread.c (struct symloc): Clean up comments.
This commit is contained in:
parent
4c92f0648f
commit
989d9cbac8
5 changed files with 96 additions and 84 deletions
|
@ -1,3 +1,9 @@
|
||||||
|
Thu Apr 20 10:12:21 1995 Jim Kingdon (kingdon@lioth.cygnus.com)
|
||||||
|
|
||||||
|
* dwarfread.c (struct dwfinfo), dbxread.c (struct symloc),
|
||||||
|
mdebugread.c (struct symloc), hpread.c (struct symloc): Clean
|
||||||
|
up comments.
|
||||||
|
|
||||||
Wed Apr 19 16:58:11 1995 Stu Grossman (grossman@andros.cygnus.com)
|
Wed Apr 19 16:58:11 1995 Stu Grossman (grossman@andros.cygnus.com)
|
||||||
|
|
||||||
* hppa-tdep.c (deposit_17): New routine to deposit 17 bit
|
* hppa-tdep.c (deposit_17): New routine to deposit 17 bit
|
||||||
|
|
|
@ -69,19 +69,37 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
|
||||||
#define SEEK_SET 0
|
#define SEEK_SET 0
|
||||||
#define SEEK_CUR 1
|
#define SEEK_CUR 1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Each partial symbol table entry contains a pointer to private data for the
|
/* Each partial symbol table entry contains a pointer to private data for the
|
||||||
read_symtab() function to use when expanding a partial symbol table entry
|
sym_read function to use when expanding a partial symbol table entry
|
||||||
to a full symbol table entry.
|
to a full symbol table entry. */
|
||||||
|
|
||||||
For dbxread this structure contains the offset within the file symbol table
|
struct symloc {
|
||||||
of first local symbol for this file, and length (in bytes) of the section
|
|
||||||
of the symbol table devoted to this file's symbols (actually, the section
|
|
||||||
bracketed may contain more than just this file's symbols). It also contains
|
|
||||||
further information needed to locate the symbols if they are in an ELF file.
|
|
||||||
|
|
||||||
If ldsymlen is 0, the only reason for this thing's existence is the
|
/* Offset within the file symbol table of first local symbol for this
|
||||||
dependency list. Nothing else will happen when it is read in. */
|
file. */
|
||||||
|
|
||||||
|
int ldsymoff;
|
||||||
|
|
||||||
|
/* Length (in bytes) of the section of the symbol table devoted to
|
||||||
|
this file's symbols (actually, the section bracketed may contain
|
||||||
|
more than just this file's symbols). If ldsymlen is 0, the only
|
||||||
|
reason for this thing's existence is the dependency list. Nothing
|
||||||
|
else will happen when it is read in. */
|
||||||
|
|
||||||
|
int ldsymlen;
|
||||||
|
|
||||||
|
/* The size of each symbol in the symbol file (in external form). */
|
||||||
|
|
||||||
|
int symbol_size;
|
||||||
|
|
||||||
|
/* Further information needed to locate the symbols if they are in
|
||||||
|
an ELF file. */
|
||||||
|
|
||||||
|
int symbol_offset;
|
||||||
|
int string_offset;
|
||||||
|
int file_string_offset;
|
||||||
|
};
|
||||||
|
|
||||||
#define LDSYMOFF(p) (((struct symloc *)((p)->read_symtab_private))->ldsymoff)
|
#define LDSYMOFF(p) (((struct symloc *)((p)->read_symtab_private))->ldsymoff)
|
||||||
#define LDSYMLEN(p) (((struct symloc *)((p)->read_symtab_private))->ldsymlen)
|
#define LDSYMLEN(p) (((struct symloc *)((p)->read_symtab_private))->ldsymlen)
|
||||||
|
@ -91,15 +109,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
|
||||||
#define STRING_OFFSET(p) (SYMLOC(p)->string_offset)
|
#define STRING_OFFSET(p) (SYMLOC(p)->string_offset)
|
||||||
#define FILE_STRING_OFFSET(p) (SYMLOC(p)->file_string_offset)
|
#define FILE_STRING_OFFSET(p) (SYMLOC(p)->file_string_offset)
|
||||||
|
|
||||||
struct symloc {
|
|
||||||
int ldsymoff;
|
|
||||||
int ldsymlen;
|
|
||||||
int symbol_size;
|
|
||||||
int symbol_offset;
|
|
||||||
int string_offset;
|
|
||||||
int file_string_offset;
|
|
||||||
};
|
|
||||||
|
|
||||||
/* Macro to determine which symbols to ignore when reading the first symbol
|
/* Macro to determine which symbols to ignore when reading the first symbol
|
||||||
of a file. Some machines override this definition. */
|
of a file. Some machines override this definition. */
|
||||||
#ifndef IGNORE_SYMBOL
|
#ifndef IGNORE_SYMBOL
|
||||||
|
@ -2050,7 +2060,8 @@ process_one_symbol (type, desc, valu, name, section_offsets, objfile)
|
||||||
#ifdef SOFUN_ADDRESS_MAYBE_MISSING
|
#ifdef SOFUN_ADDRESS_MAYBE_MISSING
|
||||||
/* Deal with the SunPRO 3.0 compiler which omits the address
|
/* Deal with the SunPRO 3.0 compiler which omits the address
|
||||||
from N_FUN symbols. */
|
from N_FUN symbols. */
|
||||||
if (type == N_FUN && valu == 0)
|
if (type == N_FUN
|
||||||
|
&& valu == ANOFFSET (section_offsets, SECT_OFF_TEXT))
|
||||||
{
|
{
|
||||||
struct minimal_symbol *msym;
|
struct minimal_symbol *msym;
|
||||||
char *p;
|
char *p;
|
||||||
|
|
|
@ -343,36 +343,29 @@ static CORE_ADDR baseaddr; /* Add to each symbol value */
|
||||||
static struct section_offsets *base_section_offsets;
|
static struct section_offsets *base_section_offsets;
|
||||||
|
|
||||||
/* Each partial symbol table entry contains a pointer to private data for the
|
/* Each partial symbol table entry contains a pointer to private data for the
|
||||||
read_symtab() function to use when expanding a partial symbol table entry
|
sym_read function to use when expanding a partial symbol table entry
|
||||||
to a full symbol table entry. For DWARF debugging info, this data is
|
to a full symbol table entry. */
|
||||||
contained in the following structure and macros are provided for easy
|
|
||||||
access to the members given a pointer to a partial symbol table entry.
|
|
||||||
|
|
||||||
dbfoff Always the absolute file offset to the start of the ".debug"
|
struct dwfinfo {
|
||||||
section for the file containing the DIE's being accessed.
|
/* Always the absolute file offset to the start of the ".debug"
|
||||||
|
section for the file containing the DIE's being accessed. */
|
||||||
dbroff Relative offset from the start of the ".debug" access to the
|
file_ptr dbfoff;
|
||||||
|
/* Relative offset from the start of the ".debug" section to the
|
||||||
first DIE to be accessed. When building the partial symbol
|
first DIE to be accessed. When building the partial symbol
|
||||||
table, this value will be zero since we are accessing the
|
table, this value will be zero since we are accessing the
|
||||||
entire ".debug" section. When expanding a partial symbol
|
entire ".debug" section. When expanding a partial symbol
|
||||||
table entry, this value will be the offset to the first
|
table entry, this value will be the offset to the first
|
||||||
DIE for the compilation unit containing the symbol that
|
DIE for the compilation unit containing the symbol that
|
||||||
triggers the expansion.
|
triggers the expansion. */
|
||||||
|
int dbroff;
|
||||||
dblength The size of the chunk of DIE's being examined, in bytes.
|
/* The size of the chunk of DIE's being examined, in bytes. */
|
||||||
|
int dblength;
|
||||||
lnfoff The absolute file offset to the line table fragment. Ignored
|
/* The absolute file offset to the line table fragment. Ignored
|
||||||
when building partial symbol tables, but used when expanding
|
when building partial symbol tables, but used when expanding
|
||||||
them, and contains the absolute file offset to the fragment
|
them, and contains the absolute file offset to the fragment
|
||||||
of the ".line" section containing the line numbers for the
|
of the ".line" section containing the line numbers for the
|
||||||
current compilation unit.
|
current compilation unit. */
|
||||||
*/
|
file_ptr lnfoff;
|
||||||
|
|
||||||
struct dwfinfo {
|
|
||||||
file_ptr dbfoff; /* Absolute file offset to start of .debug section */
|
|
||||||
int dbroff; /* Relative offset from start of .debug section */
|
|
||||||
int dblength; /* Size of the chunk of DIE's being examined */
|
|
||||||
file_ptr lnfoff; /* Absolute file offset to line table fragment */
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#define DBFOFF(p) (((struct dwfinfo *)((p)->read_symtab_private))->dbfoff)
|
#define DBFOFF(p) (((struct dwfinfo *)((p)->read_symtab_private))->dbfoff)
|
||||||
|
|
34
gdb/hpread.c
34
gdb/hpread.c
|
@ -99,29 +99,31 @@ struct hpread_symfile_info
|
||||||
} \
|
} \
|
||||||
else \
|
else \
|
||||||
*NAMEP = (SYM)->dsfile.name + VT (OBJFILE)
|
*NAMEP = (SYM)->dsfile.name + VT (OBJFILE)
|
||||||
|
|
||||||
/* Each partial symbol table entry contains a pointer to private data for the
|
/* Each partial symbol table entry contains a pointer to private data for the
|
||||||
read_symtab() function to use when expanding a partial symbol table entry
|
sym_read function to use when expanding a partial symbol table entry
|
||||||
to a full symbol table entry.
|
to a full symbol table entry. */
|
||||||
|
|
||||||
For hpuxread this structure contains the offset within the file symbol table
|
struct symloc
|
||||||
of first local symbol for this file, and length (in bytes) of the section
|
{
|
||||||
of the symbol table devoted to this file's symbols (actually, the section
|
/* The offset within the file symbol table of first local symbol for
|
||||||
bracketed may contain more than just this file's symbols).
|
this file. */
|
||||||
|
|
||||||
If ldsymlen is 0, the only reason for this thing's existence is the
|
int ldsymoff;
|
||||||
dependency list. Nothing else will happen when it is read in. */
|
|
||||||
|
/* Length (in bytes) of the section of the symbol table devoted to
|
||||||
|
this file's symbols (actually, the section bracketed may contain
|
||||||
|
more than just this file's symbols). If ldsymlen is 0, the only
|
||||||
|
reason for this thing's existence is the dependency list.
|
||||||
|
Nothing else will happen when it is read in. */
|
||||||
|
|
||||||
|
int ldsymlen;
|
||||||
|
};
|
||||||
|
|
||||||
#define LDSYMOFF(p) (((struct symloc *)((p)->read_symtab_private))->ldsymoff)
|
#define LDSYMOFF(p) (((struct symloc *)((p)->read_symtab_private))->ldsymoff)
|
||||||
#define LDSYMLEN(p) (((struct symloc *)((p)->read_symtab_private))->ldsymlen)
|
#define LDSYMLEN(p) (((struct symloc *)((p)->read_symtab_private))->ldsymlen)
|
||||||
#define SYMLOC(p) ((struct symloc *)((p)->read_symtab_private))
|
#define SYMLOC(p) ((struct symloc *)((p)->read_symtab_private))
|
||||||
|
|
||||||
struct symloc
|
|
||||||
{
|
|
||||||
int ldsymoff;
|
|
||||||
int ldsymlen;
|
|
||||||
};
|
|
||||||
|
|
||||||
/* FIXME: Shouldn't this stuff be in a .h file somewhere? */
|
/* FIXME: Shouldn't this stuff be in a .h file somewhere? */
|
||||||
/* Nonzero means give verbose info on gdb action. */
|
/* Nonzero means give verbose info on gdb action. */
|
||||||
extern int info_verbose;
|
extern int info_verbose;
|
||||||
|
|
|
@ -97,14 +97,26 @@ typedef struct mips_extra_func_info {
|
||||||
#ifndef ECOFF_REG_TO_REGNUM
|
#ifndef ECOFF_REG_TO_REGNUM
|
||||||
#define ECOFF_REG_TO_REGNUM(num) (num)
|
#define ECOFF_REG_TO_REGNUM(num) (num)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* Each partial symbol table entry contains a pointer to private data for the
|
||||||
|
sym_read function to use when expanding a partial symbol table entry
|
||||||
|
to a full symbol table entry. */
|
||||||
|
|
||||||
/* Each partial symbol table entry contains a pointer to private data
|
struct symloc
|
||||||
for the read_symtab() function to use when expanding a partial
|
{
|
||||||
symbol table entry to a full symbol table entry.
|
/* Index of the FDR that this psymtab represents. */
|
||||||
|
int fdr_idx;
|
||||||
For mdebugread this structure contains the index of the FDR that this
|
/* The BFD that the psymtab was created from. */
|
||||||
psymtab represents and a pointer to the BFD that the psymtab was
|
bfd *cur_bfd;
|
||||||
created from. */
|
const struct ecoff_debug_swap *debug_swap;
|
||||||
|
struct ecoff_debug_info *debug_info;
|
||||||
|
struct mdebug_pending **pending_list;
|
||||||
|
/* Pointer to external symbols for this file. */
|
||||||
|
EXTR *extern_tab;
|
||||||
|
/* Size of extern_tab. */
|
||||||
|
int extern_count;
|
||||||
|
enum language pst_language;
|
||||||
|
};
|
||||||
|
|
||||||
#define PST_PRIVATE(p) ((struct symloc *)(p)->read_symtab_private)
|
#define PST_PRIVATE(p) ((struct symloc *)(p)->read_symtab_private)
|
||||||
#define FDR_IDX(p) (PST_PRIVATE(p)->fdr_idx)
|
#define FDR_IDX(p) (PST_PRIVATE(p)->fdr_idx)
|
||||||
|
@ -112,19 +124,7 @@ typedef struct mips_extra_func_info {
|
||||||
#define DEBUG_SWAP(p) (PST_PRIVATE(p)->debug_swap)
|
#define DEBUG_SWAP(p) (PST_PRIVATE(p)->debug_swap)
|
||||||
#define DEBUG_INFO(p) (PST_PRIVATE(p)->debug_info)
|
#define DEBUG_INFO(p) (PST_PRIVATE(p)->debug_info)
|
||||||
#define PENDING_LIST(p) (PST_PRIVATE(p)->pending_list)
|
#define PENDING_LIST(p) (PST_PRIVATE(p)->pending_list)
|
||||||
|
|
||||||
struct symloc
|
|
||||||
{
|
|
||||||
int fdr_idx;
|
|
||||||
bfd *cur_bfd;
|
|
||||||
const struct ecoff_debug_swap *debug_swap;
|
|
||||||
struct ecoff_debug_info *debug_info;
|
|
||||||
struct mdebug_pending **pending_list;
|
|
||||||
EXTR *extern_tab; /* Pointer to external symbols for this file. */
|
|
||||||
int extern_count; /* Size of extern_tab. */
|
|
||||||
enum language pst_language;
|
|
||||||
};
|
|
||||||
|
|
||||||
/* Things we import explicitly from other modules */
|
/* Things we import explicitly from other modules */
|
||||||
|
|
||||||
extern int info_verbose;
|
extern int info_verbose;
|
||||||
|
|
Loading…
Add table
Reference in a new issue