diff options
author | Doug Evans <xdje42@gmail.com> | 2014-12-17 00:00:14 -0800 |
---|---|---|
committer | Doug Evans <xdje42@gmail.com> | 2014-12-17 00:00:14 -0800 |
commit | 0ab9ce852ba65ef77cfc1fc82d1c48d03152f868 (patch) | |
tree | 394748921a97d73623ca72e4ce6d7277acbf8af1 /gdb/buildsym.h | |
parent | b6615d1086eb357e62ec2db85b48d1d1c75157bc (diff) | |
download | gdb-0ab9ce852ba65ef77cfc1fc82d1c48d03152f868.zip gdb-0ab9ce852ba65ef77cfc1fc82d1c48d03152f868.tar.gz gdb-0ab9ce852ba65ef77cfc1fc82d1c48d03152f868.tar.bz2 |
Make buildsym set-up/tear-down more consistent, and document it.
gdb/ChangeLog:
* buildsym.c: Add comments describing how the buildsym machinery
is used by the various file formats.
(really_free_pendings): Enhance function comment.
See pending_macros to NULL. Simplify resetting pending_addrmap.
Call free_buildsym_compunit.
(free_buildsym_compunit): Set current_subfile to NULL.
(prepare_for_building): New function.
(start_symtab): Call it. Remove call to set_last_source_file.
(restart_symtab): New arg "cust". All callers updated.
Simplify, call prepare_for_building. Re-initialize buildsym_compunit.
(reset_symtab_globals): Enhance function comment.
Set local_symbols, file_symbols, global_symbols to NULL.
Set pending_macros to NULL. Simplify resetting pending_addrmap.
Call free_buildysym_compunit.
(end_symtab_without_blockvector): Delete. All callers updated.
(end_symtab_with_blockvector): Remove redundant call to
free_buildsym_compunit.
(augment_type_symtab): Remove arg "cust". All callers updated.
(buildsym_init): Remove resetting of free_pendings, file_symbols,
global_symbols, pending_blocks, pending_macros. Instead make
handling consistent with pending_addrmap: Assert value was reset
at end of previous symtab building. Initialize context_stack here.
Diffstat (limited to 'gdb/buildsym.h')
-rw-r--r-- | gdb/buildsym.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gdb/buildsym.h b/gdb/buildsym.h index bddec5f..307ce0a 100644 --- a/gdb/buildsym.h +++ b/gdb/buildsym.h @@ -222,7 +222,7 @@ extern struct compunit_symtab *end_symtab (CORE_ADDR end_addr, int section); extern struct compunit_symtab *end_expandable_symtab (CORE_ADDR end_addr, int section); -extern void augment_type_symtab (struct compunit_symtab *cust); +extern void augment_type_symtab (void); /* Defined in stabsread.c. */ @@ -243,7 +243,8 @@ extern struct compunit_symtab *start_symtab (struct objfile *objfile, const char *comp_dir, CORE_ADDR start_addr); -extern void restart_symtab (CORE_ADDR start_addr); +extern void restart_symtab (struct compunit_symtab *cust, + const char *name, CORE_ADDR start_addr); extern int hashname (const char *name); |