aboutsummaryrefslogtreecommitdiff
path: root/gdb/dwarfread.c
diff options
context:
space:
mode:
authorFred Fish <fnf@specifix.com>1996-04-06 10:19:19 +0000
committerFred Fish <fnf@specifix.com>1996-04-06 10:19:19 +0000
commiteae8aa302e9a76565bca1cf381e76125e1d9ff89 (patch)
treef9011ec07116881c3b35017a75e521143c2af693 /gdb/dwarfread.c
parente24146ec9529e0c028962910ac2efba45e42b9cf (diff)
downloadgdb-eae8aa302e9a76565bca1cf381e76125e1d9ff89.zip
gdb-eae8aa302e9a76565bca1cf381e76125e1d9ff89.tar.gz
gdb-eae8aa302e9a76565bca1cf381e76125e1d9ff89.tar.bz2
* symfile.c (INLINE_ADD_PSYMBOL): Remove ifdef.
(add_psymbol_to_list): Add an arg for passing CORE_ADDR values and use it, rather than calling add_psymbol_addr_to_list. (add_psymbol_addr_to_list): Delete. (add_psymbol_to_list): Make psymbol static to avoid random data in gaps due to alignment of structure members. * symfile.h (INLINE_ADD_PSYMBOL, ADD_PSYMBOL_TO_LIST, ADD_PSYMBOL_ADDR_TO_LIST): Remove. Real world tests show no performance improvements by inlining via complicated macros and they just make gdb larger and harder to maintain. * dwarfread.c (add_enum_psymbol): Replace ADD_PSYMBOL_TO_LIST and/or ADD_PSYMBOL_ADDR_TO_LIST macro(s) with call to add_psymbol_to_list with appropriate long or CORE_ADDR args. (add_partial_symbol): Ditto. * partial-stab.h: Ditto. * os9kread.c (read_os9k_psymtab): Ditto * mdebugread.c (parse_partial_symbols): Ditto. (handle_psymbol_enumerators): Ditto. (demangle.h): Include. * hpread.c (hpread_build_psymtabs): Ditto. (hpread_build_psymtabs): Ditto. (demangle.h): Include
Diffstat (limited to 'gdb/dwarfread.c')
-rw-r--r--gdb/dwarfread.c46
1 files changed, 23 insertions, 23 deletions
diff --git a/gdb/dwarfread.c b/gdb/dwarfread.c
index bdbd4ad..ed82009 100644
--- a/gdb/dwarfread.c
+++ b/gdb/dwarfread.c
@@ -2553,8 +2553,8 @@ add_enum_psymbol (dip, objfile)
while (scan < listend)
{
scan += TARGET_FT_LONG_SIZE (objfile);
- ADD_PSYMBOL_TO_LIST (scan, strlen (scan), VAR_NAMESPACE, LOC_CONST,
- objfile -> static_psymbols, 0, cu_language,
+ add_psymbol_to_list (scan, strlen (scan), VAR_NAMESPACE, LOC_CONST,
+ &objfile -> static_psymbols, 0, 0, cu_language,
objfile);
scan += strlen (scan) + 1;
}
@@ -2586,34 +2586,34 @@ add_partial_symbol (dip, objfile)
switch (dip -> die_tag)
{
case TAG_global_subroutine:
- ADD_PSYMBOL_ADDR_TO_LIST (dip -> at_name, strlen (dip -> at_name),
+ add_psymbol_to_list (dip -> at_name, strlen (dip -> at_name),
VAR_NAMESPACE, LOC_BLOCK,
- objfile -> global_psymbols,
- dip -> at_low_pc, cu_language, objfile);
+ &objfile -> global_psymbols,
+ 0, dip -> at_low_pc, cu_language, objfile);
break;
case TAG_global_variable:
- ADD_PSYMBOL_TO_LIST (dip -> at_name, strlen (dip -> at_name),
+ add_psymbol_to_list (dip -> at_name, strlen (dip -> at_name),
VAR_NAMESPACE, LOC_STATIC,
- objfile -> global_psymbols,
- 0, cu_language, objfile);
+ &objfile -> global_psymbols,
+ 0, 0, cu_language, objfile);
break;
case TAG_subroutine:
- ADD_PSYMBOL_ADDR_TO_LIST (dip -> at_name, strlen (dip -> at_name),
+ add_psymbol_to_list (dip -> at_name, strlen (dip -> at_name),
VAR_NAMESPACE, LOC_BLOCK,
- objfile -> static_psymbols,
- dip -> at_low_pc, cu_language, objfile);
+ &objfile -> static_psymbols,
+ 0, dip -> at_low_pc, cu_language, objfile);
break;
case TAG_local_variable:
- ADD_PSYMBOL_TO_LIST (dip -> at_name, strlen (dip -> at_name),
+ add_psymbol_to_list (dip -> at_name, strlen (dip -> at_name),
VAR_NAMESPACE, LOC_STATIC,
- objfile -> static_psymbols,
- 0, cu_language, objfile);
+ &objfile -> static_psymbols,
+ 0, 0, cu_language, objfile);
break;
case TAG_typedef:
- ADD_PSYMBOL_TO_LIST (dip -> at_name, strlen (dip -> at_name),
+ add_psymbol_to_list (dip -> at_name, strlen (dip -> at_name),
VAR_NAMESPACE, LOC_TYPEDEF,
- objfile -> static_psymbols,
- 0, cu_language, objfile);
+ &objfile -> static_psymbols,
+ 0, 0, cu_language, objfile);
break;
case TAG_class_type:
case TAG_structure_type:
@@ -2622,17 +2622,17 @@ add_partial_symbol (dip, objfile)
/* Do not add opaque aggregate definitions to the psymtab. */
if (!dip -> has_at_byte_size)
break;
- ADD_PSYMBOL_TO_LIST (dip -> at_name, strlen (dip -> at_name),
+ add_psymbol_to_list (dip -> at_name, strlen (dip -> at_name),
STRUCT_NAMESPACE, LOC_TYPEDEF,
- objfile -> static_psymbols,
- 0, cu_language, objfile);
+ &objfile -> static_psymbols,
+ 0, 0, cu_language, objfile);
if (cu_language == language_cplus)
{
/* For C++, these implicitly act as typedefs as well. */
- ADD_PSYMBOL_TO_LIST (dip -> at_name, strlen (dip -> at_name),
+ add_psymbol_to_list (dip -> at_name, strlen (dip -> at_name),
VAR_NAMESPACE, LOC_TYPEDEF,
- objfile -> static_psymbols,
- 0, cu_language, objfile);
+ &objfile -> static_psymbols,
+ 0, 0, cu_language, objfile);
}
break;
}