aboutsummaryrefslogtreecommitdiff
path: root/gdb/partial-stab.h
diff options
context:
space:
mode:
authorJim Blandy <jimb@codesourcery.com>2001-10-24 17:10:18 +0000
committerJim Blandy <jimb@codesourcery.com>2001-10-24 17:10:18 +0000
commit3973eaddf42f21fd7f36696381b8a2f9d210215a (patch)
tree7a05d0dc9222d5f18cc42ecc7c225f7a37cb601a /gdb/partial-stab.h
parent908d94bfcd7598fb97015ed5a7474a1d26cf56a5 (diff)
downloadgdb-3973eaddf42f21fd7f36696381b8a2f9d210215a.zip
gdb-3973eaddf42f21fd7f36696381b8a2f9d210215a.tar.gz
gdb-3973eaddf42f21fd7f36696381b8a2f9d210215a.tar.bz2
Isolate STABS readers' use of the `textlow' and `texthigh' fields
of `struct partial_symtab' to only a few locations. This change is not supposed to affect the way the values are computed, only where they live. * dbxread.c (struct symloc): Add `textlow' and `texthigh' fields to the reader-specific structure. * mdebugread.c (struct symloc): Same. * dbxread.c (TEXTLOW, TEXTHIGH): New accessor macros. * mdebugread.c (TEXTLOW, TEXTHIGH): Same. * dbxread.c (dbx_symfile_read): After we've built all our partial symbol tables, set each partial symtab's `textlow' and `texthigh' fields from our reader-specific structure. * mdebugread.c (mdebug_build_psymtabs): Same. * dbxread.c (start_psymtab): Initialize the reader-specific structure's `textlow' and `texthigh' from the new psymtab's. * mdebugread.c (parse_partial_symbols, new_psymtab): Same. * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab): Use the reader-specific `textlow' and `texthigh', not the generic psymtab fields. * mdebugread.c (parse_lines, parse_partial_symbols, psymtab_to_symtab_1): Same. * partial-stab.h: Same.
Diffstat (limited to 'gdb/partial-stab.h')
-rw-r--r--gdb/partial-stab.h26
1 files changed, 13 insertions, 13 deletions
diff --git a/gdb/partial-stab.h b/gdb/partial-stab.h
index e18cabb..dff74c2 100644
--- a/gdb/partial-stab.h
+++ b/gdb/partial-stab.h
@@ -104,12 +104,12 @@ switch (CUR_SYMBOL_TYPE)
if (past_first_source_file && pst
/* The gould NP1 uses low values for .o and -l symbols
which are not the address. */
- && CUR_SYMBOL_VALUE >= pst->textlow)
+ && CUR_SYMBOL_VALUE >= TEXTLOW (pst))
{
END_PSYMTAB (pst, psymtab_include_list, includes_used,
symnum * symbol_size,
- CUR_SYMBOL_VALUE > pst->texthigh
- ? CUR_SYMBOL_VALUE : pst->texthigh,
+ CUR_SYMBOL_VALUE > TEXTHIGH (pst)
+ ? CUR_SYMBOL_VALUE : TEXTHIGH (pst),
dependency_list, dependencies_used, textlow_not_set);
pst = (struct partial_symtab *) 0;
includes_used = 0;
@@ -236,7 +236,7 @@ switch (CUR_SYMBOL_TYPE)
{
END_PSYMTAB (pst, psymtab_include_list, includes_used,
symnum * symbol_size,
- valu > pst->texthigh ? valu : pst->texthigh,
+ valu > TEXTHIGH (pst) ? valu : TEXTHIGH (pst),
dependency_list, dependencies_used,
prev_textlow_not_set);
pst = (struct partial_symtab *) 0;
@@ -405,8 +405,8 @@ switch (CUR_SYMBOL_TYPE)
function relative stabs, or the address of the function's
end for old style stabs. */
valu = CUR_SYMBOL_VALUE + last_function_start;
- if (pst->texthigh == 0 || valu > pst->texthigh)
- pst->texthigh = valu;
+ if (TEXTHIGH (pst) == 0 || valu > TEXTHIGH (pst))
+ TEXTHIGH (pst) = valu;
break;
}
#endif
@@ -610,7 +610,7 @@ switch (CUR_SYMBOL_TYPE)
}
if (pst && textlow_not_set)
{
- pst->textlow = CUR_SYMBOL_VALUE;
+ TEXTLOW (pst) = CUR_SYMBOL_VALUE;
textlow_not_set = 0;
}
#endif
@@ -626,12 +626,12 @@ switch (CUR_SYMBOL_TYPE)
the partial symbol table. */
if (pst
&& (textlow_not_set
- || (CUR_SYMBOL_VALUE < pst->textlow
+ || (CUR_SYMBOL_VALUE < TEXTLOW (pst)
&& (CUR_SYMBOL_VALUE
!= ANOFFSET (objfile->section_offsets,
SECT_OFF_TEXT (objfile))))))
{
- pst->textlow = CUR_SYMBOL_VALUE;
+ TEXTLOW (pst) = CUR_SYMBOL_VALUE;
textlow_not_set = 0;
}
#endif /* DBXREAD_ONLY */
@@ -677,7 +677,7 @@ switch (CUR_SYMBOL_TYPE)
}
if (pst && textlow_not_set)
{
- pst->textlow = CUR_SYMBOL_VALUE;
+ TEXTLOW (pst) = CUR_SYMBOL_VALUE;
textlow_not_set = 0;
}
#endif
@@ -693,12 +693,12 @@ switch (CUR_SYMBOL_TYPE)
the partial symbol table. */
if (pst
&& (textlow_not_set
- || (CUR_SYMBOL_VALUE < pst->textlow
+ || (CUR_SYMBOL_VALUE < TEXTLOW (pst)
&& (CUR_SYMBOL_VALUE
!= ANOFFSET (objfile->section_offsets,
SECT_OFF_TEXT (objfile))))))
{
- pst->textlow = CUR_SYMBOL_VALUE;
+ TEXTLOW (pst) = CUR_SYMBOL_VALUE;
textlow_not_set = 0;
}
#endif /* DBXREAD_ONLY */
@@ -813,7 +813,7 @@ switch (CUR_SYMBOL_TYPE)
case N_ENDM:
#ifdef SOFUN_ADDRESS_MAYBE_MISSING
/* Solaris 2 end of module, finish current partial symbol table.
- END_PSYMTAB will set pst->texthigh to the proper value, which
+ END_PSYMTAB will set TEXTHIGH (pst) to the proper value, which
is necessary if a module compiled without debugging info
follows this module. */
if (pst)