aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2004-09-21Merge from mainline.drow_intercu-20040221-branchDaniel Jacobowitz106-7261/+9659
2004-09-20This commit was manufactured by cvs2svn to create branchnobody5-0/+396
'drow_intercu-20040221-branch'. Cherrypick from master 2004-09-20 20:06:29 UTC Jeff Johnston <jjohnstn@redhat.com> '': gdb/fbsd-nat.c gdb/fbsd-nat.h gdb/i386bsd-nat.h gdb/testsuite/gdb.java/jprint.exp gdb/testsuite/gdb.java/jprint.java
2004-09-16Merge mainline to intercu branch - 2004-09-15Daniel Jacobowitz1171-72437/+96945
2004-09-16This commit was manufactured by cvs2svn to create branchnobody137-0/+22943
'drow_intercu-20040221-branch'. Cherrypick from master 2004-09-16 14:52:12 UTC Alan Modra <amodra@gmail.com> ' * elf-bfd.h (struct elf_link_hash_entry): Replace elf_link_hash_flags': bfd/cpu-crx.c bfd/elf32-crx.c bfd/elf32-sh-symbian.c bfd/m88kopenbsd.c config/mh-ppc-darwin config/mt-gnu gdb/bsd-kvm.c gdb/bsd-kvm.h gdb/config/i386/i386.mt gdb/config/m68k/nbsd.mt gdb/config/m68k/nbsdelf.mh gdb/config/m68k/obsd.mh gdb/config/m68k/obsd.mt gdb/config/m88k/obsd.mh gdb/config/m88k/obsd.mt gdb/config/pa/linux.mh gdb/config/pa/linux.mt gdb/config/pa/nm-linux.h gdb/config/pa/obsd.mh gdb/config/pa/obsd.mt gdb/config/pa/tm-linux.h gdb/config/powerpc/obsd.mh gdb/config/powerpc/obsd.mt gdb/config/vax/nbsd.mt gdb/config/vax/nbsdaout.mh gdb/config/vax/nbsdelf.mh gdb/config/vax/nm-nbsdaout.h gdb/config/vax/obsd.mh gdb/config/vax/vax.mh gdb/gdb_ptrace.h gdb/hppa-linux-nat.c gdb/hppa-linux-tdep.c gdb/hppabsd-nat.c gdb/hppabsd-tdep.c gdb/i386nbsd-nat.c gdb/inf-child.c gdb/inf-child.h gdb/inf-ptrace.c gdb/inf-ptrace.h gdb/m68kbsd-nat.c gdb/m68kbsd-tdep.c gdb/m88k-tdep.c gdb/m88k-tdep.h gdb/m88kbsd-nat.c gdb/mi/gdb-mi.el gdb/observer.sh gdb/po/gdbtext gdb/ppcobsd-nat.c gdb/ppcobsd-tdep.c gdb/ppcobsd-tdep.h gdb/regset.c gdb/symfile-mem.c gdb/testsuite/gdb.ada/gnat_ada.gin gdb/testsuite/gdb.arch/e500-prologue.c gdb/testsuite/gdb.arch/e500-prologue.exp gdb/testsuite/gdb.arch/i386-cpuid.h gdb/testsuite/gdb.arch/i386-sse.c gdb/testsuite/gdb.arch/i386-sse.exp gdb/testsuite/gdb.arch/powerpc-aix-prologue.c gdb/testsuite/gdb.arch/powerpc-aix-prologue.exp gdb/testsuite/gdb.asm/pa.inc gdb/testsuite/gdb.base/call-sc.c gdb/testsuite/gdb.base/call-sc.exp gdb/testsuite/gdb.base/lineinc.c gdb/testsuite/gdb.base/lineinc.exp gdb/testsuite/gdb.base/lineinc1.h gdb/testsuite/gdb.base/lineinc2.h gdb/testsuite/gdb.base/lineinc3.h gdb/testsuite/gdb.base/sep-proc.c gdb/testsuite/gdb.base/sep.c gdb/testsuite/gdb.base/sep.exp gdb/testsuite/gdb.base/sigaltstack.c gdb/testsuite/gdb.base/sigaltstack.exp gdb/testsuite/gdb.base/sigbpt.c gdb/testsuite/gdb.base/sigbpt.exp gdb/testsuite/gdb.base/siginfo.c gdb/testsuite/gdb.base/siginfo.exp gdb/testsuite/gdb.base/signull.c gdb/testsuite/gdb.base/signull.exp gdb/testsuite/gdb.base/sigstep.c gdb/testsuite/gdb.base/sigstep.exp gdb/testsuite/gdb.base/unload.c gdb/testsuite/gdb.base/unload.exp gdb/testsuite/gdb.base/unloadshr.c gdb/testsuite/gdb.fortran/Makefile.in gdb/testsuite/gdb.gdb/selftest.exp gdb/testsuite/gdb.java/jmain.exp gdb/testsuite/gdb.java/jmain.java gdb/testsuite/gdb.stabs/exclfwd.exp gdb/testsuite/gdb.stabs/exclfwd.h gdb/testsuite/gdb.stabs/exclfwd1.c gdb/testsuite/gdb.stabs/exclfwd2.c gdb/testsuite/gdb.threads/bp_in_thread.exp gdb/testsuite/gdb.threads/manythreads.c gdb/testsuite/gdb.threads/manythreads.exp gdb/testsuite/gdb.threads/pthread_cond_wait.c gdb/testsuite/gdb.threads/pthread_cond_wait.exp gdb/testsuite/gdb.threads/staticthreads.c gdb/testsuite/gdb.threads/staticthreads.exp gdb/testsuite/gdb.threads/thread_check.c gdb/testsuite/gdb.threads/thread_check.exp gdb/testsuite/gdb.threads/watchthreads.exp gdb/testsuite/lib/cp-support.exp gdb/vax-nat.c gdb/vaxbsd-nat.c gdb/vaxnbsd-tdep.c include/elf/crx.h include/gdb/sim-ppc.h include/opcode/crx.h opcodes/crx-dis.c opcodes/crx-opc.c sim/mn10300/am33-2.igen sim/ppc/gdb-sim.c sim/testsuite/sim/mips/fpu64-ps-sb1.s sim/testsuite/sim/mips/fpu64-ps.s sim/testsuite/sim/mips/mdmx-ob-sb1.s sim/testsuite/sim/mips/mdmx-ob.s sim/testsuite/sim/mips/utils-fpu.inc sim/testsuite/sim/mips/utils-mdmx.inc sim/testsuite/sim/sh/bandor.s sim/testsuite/sim/sh/bandornot.s sim/testsuite/sim/sh/bclr.s sim/testsuite/sim/sh/bld.s sim/testsuite/sim/sh/bldnot.s sim/testsuite/sim/sh/bset.s sim/testsuite/sim/sh/bst.s sim/testsuite/sim/sh/bxor.s sim/testsuite/sim/sh/clip.s sim/testsuite/sim/sh/div.s sim/testsuite/sim/sh/fail.s sim/testsuite/sim/sh/fsca.s sim/testsuite/sim/sh/fsrra.s sim/testsuite/sim/sh/mov.s sim/testsuite/sim/sh/mulr.s sim/testsuite/sim/sh/pass.s sim/testsuite/sim/sh/pushpop.s sim/testsuite/sim/sh/resbank.s
2004-08-07 * dwarf2read.c (struct dwarf2_per_objfile): Replace cu_treeDaniel Jacobowitz2-54/+104
with all_comp_units and n_comp_units. (dwarf2_find_containing_comp_unit): Take an objfile argument instead of a dwarf2_cu. Search all_comp_units. (dwarf2_find_comp_unit): New function. (create_all_comp_units): Renamed from create_comp_unit_tree. Create a list instead of a splay tree. (dwarf2_build_psymtabs_hard): Call create_comp_unit_tree and dwarf2_find_comp_unit. (psymtab_to_symtab_1): Check all_comp_units. Use dwarf2_find_comp_unit. (find_partial_die, read_full_die, follow_die_ref): Update calls to dwarf2_find_containing_comp_unit.
2004-04-19 * dwarf2read.c (free_comp_units_worker): Remove incorrect aging.Daniel Jacobowitz2-17/+19
(_initialize_dwarf2_read): Use var_zinteger.
2004-04-19./Daniel Jacobowitz6-11/+94
* Makefile.in (dwarf2read.o): Update dependencies. * dwarf2read.c: Include "command.h" and "gdbcmd.h". (MAX_CACHE_AGE): Remove. (dwarf2_max_cache_age): New variable. (free_comp_units_worker): Update. (set_dwarf2_cmdlist, show_dwarf2_cmdlist, set_dwarf2_cmd) (show_dwarf2_cmd): New. (_initialize_dwarf2_read): Provide "maint set dwarf2 max-cache-age" and "maint show dwarf2 max-cache-age". * gdbcmd.h (maintenance_set_cmdlist, maintenance_show_cmdlist): New externs. * maint.c (maintenance_set_cmdlist, maintenance_show_cmdlist): Make global. doc/ * gdb.texinfo (Maintenance Commands): Document "maint set dwarf2 max-cache-age" and "maint show dwarf2 max-cache-age".
2004-04-19 * cli/cli-setshow.c (cmd_show_list): Check for "show" in the middleDaniel Jacobowitz2-2/+9
of prefixes. Don't print the prefix twice in the CLI.
2004-04-19 * dwarf2read.c (add_partial_structure): Remove.Daniel Jacobowitz2-158/+154
(load_partial_die): Rename to read_partial_die. (skip_one_die): Move prototype. (clear_per_cu_pointer): Rename to free_stack_comp_unit. Always free the obstack. (dwarf2_build_psymtabs_hard): Update comments. Move cleanup. Initialize the comp_unit_obstack. Remove hash table creation. (load_comp_unit): Initialize the comp_unit_obstack. Remove hash table creation. (create_comp_unit_tree): Update comments. Read less data. (scan_partial_symbols): Update comment. Rename pdi_p to pdi. (add_partial_enumeration): Likewise. (add_partial_symbol): Remove psym2. (add_partial_namespace): Don't set the name here. (guess_structure_name): Make static. (locate_pdi_sibling): Rearrange. (determine_class_name): Update comment. (load_partial_dies): Create the hash table here. Update comments. Don't use obstack_free. (fixup_partial_die): Add comment. Fix typo. (dwarf_alloc_block): Readd comment.
2004-04-02 * dwarf2read.c (struct dwarf2_cu): Add comments. RenameDaniel Jacobowitz2-134/+159
partial_die_obstack to comp_unit_obstack. (struct partial_die_info): Move higher in file. Add comments. Use ENUM_BITFIELD. (dwarf2_tmp_obstack, dwarf2_free_tmp_obstack): Remove. (partial_die_hash, partial_die_eq): Move lower in file. (hashtab_obstack_allocate): Likewise. Renamed from hash_obstack_allocate. (dummy_obstack_deallocate): Likewise. Renamed from splay_tree_obstack_deallocate. (dwarf2_build_psymtabs_hard): Remove references to dwarf2_tmp_obstack. Update names of changed variables/functions. (load_comp_unit, create_comp_unit_tree, partial_die_parent_scope) (guess_structure_name, psymtab_to_symtab_1, load_full_comp_unit) (add_to_cu_func_list, load_partial_dies, dwarf_alloc_block) (free_one_comp_unit, clear_per_cu_pointer, set_die_type) (dwarf2_add_dependence): Likewise.
2004-04-02Merge GDB mainline of 20040402 to intercu branch.Daniel Jacobowitz110-4916/+5958
2004-04-02This commit was manufactured by cvs2svn to create branchnobody13-0/+1941
'drow_intercu-20040221-branch'. Cherrypick from master 2004-04-02 15:26:04 UTC H.J. Lu <hjl.tools@gmail.com> '2004-04-02 H.J. Lu <hongjiu.lu@intel.com>': bfd/cpu-cr16c.c bfd/elf32-cr16c.c gdb/testsuite/gdb.ada/Makefile.in gdb/testsuite/gdb.ada/bar.adb gdb/testsuite/gdb.ada/bar.ads gdb/testsuite/gdb.ada/gnat_ada.gpr.in gdb/testsuite/gdb.ada/null_record.adb gdb/testsuite/gdb.ada/null_record.exp gdb/testsuite/lib/ada.exp include/elf/cr16c.h sim/testsuite/sim/mips/hilo-hazard-1.s sim/testsuite/sim/mips/hilo-hazard-2.s sim/testsuite/sim/mips/hilo-hazard-3.s
2004-04-02 * dwarf2read.c (struct partial_die_info): Replace full_name andDaniel Jacobowitz2-74/+151
full_name_set with scope and scope_set. (partial_die_parent_scope): New function. (partial_die_full_name): Use it. (add_partial_symbol): Don't check full_name_set or set full_name. (add_partial_namespace): Remove unused variable. (guess_partial_structure): New function, broken out from add_partial_structure. Set the name field of the partial DIE. (add_partial_structure): Simplify. (find_partial_die): Always set *TARGET_CU. (fixup_partial_die): Call guess_structure_scope. Set the names of anonymous classes and namespaces.
2004-04-01 * dwarf2read.c (struct dwarf2_cu): Add has_form_ref_addr andDaniel Jacobowitz2-47/+63
has_namespace_info. (dwarf2_read_abbrevs): Set the new flags. Change return type back to void. Update comments. (dwarf2_build_psymtabs_hard): Update call to dwarf2_read_abbrevs. Use new has_form_ref_addr flag. Update call to scan_partial_symbols. (scan_partial_symbols, add_partial_symbol, add_partial_structure) (add_partial_enumeration, add_partial_namespace): Remove have_namespace_info argument. Use new has_namespace_info CU flag. Update calls to changed functions.
2004-03-27Merge mainline to intercu branch.Daniel Jacobowitz484-40287/+58513
2004-03-26This commit was manufactured by cvs2svn to create branchnobody26-0/+5823
'drow_intercu-20040221-branch'. Cherrypick from master 2004-03-26 23:15:40 UTC Joel Brobecker <brobecker@gnat.com> ' * amd64-tdep.c (amd64_classify): make RANGE_TYPE objects be part': gdb/amd64-linux-nat.c gdb/amd64-linux-tdep.c gdb/amd64-tdep.c gdb/amd64-tdep.h gdb/config/i386/linux64.mh gdb/config/i386/linux64.mt gdb/config/i386/nm-linux64.h gdb/config/i386/obsdaout.mh gdb/config/i386/tm-linux64.h gdb/config/nm-bsd.h gdb/frv-linux-tdep.c gdb/frv-tdep.h gdb/solib-frv.c gdb/testsuite/gdb.arch/gdb1431.s gdb/testsuite/gdb.base/auxv.c gdb/testsuite/gdb.base/auxv.exp gdb/testsuite/gdb.cp/classes.cc gdb/testsuite/gdb.cp/pr-1553.cc gdb/testsuite/gdb.cp/pr-1553.exp gdb/tramp-frame.c gdb/tramp-frame.h sim/frv/profile-fr450.c sim/testsuite/sim/frv/mqlclrhs.cgs sim/testsuite/sim/frv/mqlmths.cgs sim/testsuite/sim/frv/mqsllhi.cgs sim/testsuite/sim/frv/mqsrahi.cgs
2004-03-14 * dwarf2read.c (read_structure_type): Renamed fromDaniel Jacobowitz2-12/+20
read_structure_scope. (process_enumeration_scope): Renamed from read_enumeration_scope. (add_partial_structure, process_die, new_symbol) (read_type_die): Update calls and comments.
2004-02-25 * dwarf2read.c (struct comp_unit_head): Remove dwarf2_abbrevs array.Daniel Jacobowitz2-18/+33
(struct dwarf2_cu): Add dwarf2_abbrevs pointer. Update comment about comp_unit_head. (dwarf2_free_abbrev_table): Renamed from dwarf2_empty_abbrev_table. Clear the pointer abbrev table pointer. (dwarf2_build_psymtabs_hard, load_comp_unit, load_full_comp_unit): Update calls. (dwarf2_read_abbrevs): Update for moved dwarf2_abbrevs pointer. Allocate the hash table from the obstack. (dwarf2_lookup_abbrev): Update for moved dwarf2_abbrevs pointer.
2004-02-25 * dwarf2read.c (skip_leb128, peek_die_abbrev, skip_one_die)Daniel Jacobowitz2-19/+43
(skip_children, locate_pdi_sibling): Update comments and clean up.
2004-02-25 * dwarf2read.c (free_one_comp_unit): Update signature so it can beDaniel Jacobowitz2-15/+84
used as a cleanup. Clear the per_cu pointer. Add some comments. (free_one_cached_comp_unit): Update signature so it can be used as a cleanup. Remove unused argument. (dwarf2_build_psymtabs_hard): Update call to free_one_cached_comp_unit. Don't free the obstack here. (process_queue): Keep dwarf2_queue up to date as we remove items from the queue. (dwarf2_release_queue): New function. (psymtab_to_symtab_1): Use cleanups. (load_full_comp_unit): Likewise. (free_comp_units_worker): Remove clearing of the cu pointer. (clear_per_cu_pointer): Also free the partial_die_obstack. Update comments.
2004-02-24 * dwarf2read.c (MAX_CACHE_AGE): Lower to 5.Daniel Jacobowitz2-26/+127
(struct dwarf2_cu): Add dependencies and mark fields. (free_one_comp_unit): New function, broken out from free_comp_units_worker. (dwarf2_add_dependence, dwarf2_clear_marks, dwarf2_mark) (dwarf2_mark_helper): New functions. (psymtab_to_symtab_1): Call free_one_comp_unit. Re-enable aging. (read_full_die): Call dwarf2_add_dependence. (free_comp_units_worker): Call free_one_comp_unit. Use marking to free old comp units.
2004-02-24 * dwarf2read.c (struct dwarf2_cu): Add dies.Daniel Jacobowitz2-93/+312
(struct dwarf2_per_cu_data): Shrink length field to add new queued flag. (make_cleanup_free_die_list, do_free_die_list_cleanup): Remove. (dwarf_alloc_block): Take a dwarf2_cu argument. Allocate blocks on the partial_die_obstack. (dwarf2_find_comp_unit_psymtab, struct dwarf2_queue_item) (dwarf2_queue, queue_comp_unit, process_queue): New. (load_full_comp_unit, process_full_comp_unit): New functions, split from psymtab_to_symtab_1. (psymtab_to_symtab_1): Remove. (dwarf2_build_psymtabs_hard): Initialize the whole dwarf2_cu structure. Cache the psymtab if we have a per_cu structure. (load_comp_unit): Initialize the whole dwarf2_cu structure. (dwarf2_psymtab_to_symtab): Restore dwarf2_per_objfile here. (read_full_die): Queue compilation units for references. (read_attribute_value): Update calls to dwarf_alloc_block. (follow_die_ref): Follow inter-complation-unit references. (free_comp_units_worker): Free the die list. (get_die_type): Take the hash table as an argument. (reset_die_and_siblings_types): Don't try to restore types if none were saved.
2004-02-23 * dwarf2read.c (struct dwarf2_per_objfile_data): Add commentDaniel Jacobowitz2-26/+58
for cu_tree. Add read_in_chain. (age_cached_comp_units): New function. (clear_per_cu_pointer): Clear the pointer ourself. Call age_cached_comp_units. (free_cached_comp_units, free_one_cached_comp_unit): Update call to free_comp_units_worker. (dwarf2_build_psymtabs_hard): Use the per-objfile read_in_chain. (find_partial_die): Likewise. (free_comp_units_worker): Don't try to clear the per_cu pointer for the list head. Remove now-unused argument. Use the per-objfile read_in_chain.
2004-02-23 * dwarf2read.c (dwarf2_read_abbrevs): Return 1 for DW_FORM_indirectDaniel Jacobowitz2-0/+10
also.
2004-02-23 * dwarf2read.c (dwarf2_read_abbrevs): Return 1 iff we saw anyDaniel Jacobowitz2-24/+54
DW_FORM_ref_addr tags. (create_comp_unit_tree): Add prototype. Take an objfile instead of a compilation unit. (dwarf2_build_psymtabs_hard): Build the compilation unit tree as soon as we find an inter-CU reference. Update call to create_comp_unit_tree. (dwarf2_find_containing_comp_unit): Don't create the tree here. (psymtab_to_symtab_1): Update to support no tree having been built. (set_die_type): Likewise.
2004-02-23 * dwarf2read.c (dwarf2_per_objfile_data): New.Daniel Jacobowitz5-134/+105
(struct dwarf2_per_objfile_data): New. (dwarf2_per_objfile): New. (dwarf_info_size, dwarf_abbrev_size, dwarf_line_size) (dwarf_pubnames_size, dwarf_aranges_size, dwarf_loc_size) (dwarf_macinfo_size, dwarf_str_size, dwarf_ranges_size) (dwarf_frame_size, dwarf_eh_frame_size, dwarf_info_buffer) (dwarf_abbrev_buffer, dwarf_line_buffer, dwarf_str_buffer) (dwarf_macinfo_buffer, dwarf_ranges_buffer, dwarf_loc_buffer): Replace with macros. (dwarf2_cu_tree): Remove. (struct dwarf2_pinfo): Remove per-objfile members. (DWARF_INFO_SIZE, DWARF_ABBREV_SIZE, DWARF_LINE_SIZE) (DWARF_LOC_SIZE, DWARF_MACINFO_SIZE, DWARF_STR_SIZE) (DWARF_RANGES_SIZE, DWARF_INFO_BUFFER) (DWARF_ABBREV_BUFFER, DWARF_LINE_BUFFER, DWARF_STR_BUFFER) (DWARF_MACINFO_BUFFER, DWARF_RANGES_BUFFER, DWARF_LOC_BUFFER): Remove macros. (dwarf2_has_info): Take an objfile argument. Allocate per-objfile data. (dwarf2_build_psymtabs_hard): Remove use of removed macros. Fetch cu_tree from dwarf2_per_objfile. (create_comp_unit_tree): Save cu_tree in dwarf2_per_objfile. (psymtab_to_symtab_1): Restore per-objfile data pointer. Remove use of removed macros. (dwarf2_find_containing_comp_unit): Fetch cu_tree from dwarf2_per_objfile. (_initialize_dwarf2_read): Register dwarf2_per_objfile_data instead of dwarf2_cu_tree. * symfile.h (dwarf2_has_info): Update prototype. * coffread.c (coff_symfile_read): Update call to dwarf2_has_info. * elfread.c (elf_symfile_read): Likewise.
2004-02-23 * dwarf2read.c (struct dwarf2_per_cu_data): Add psymtab member.Daniel Jacobowitz2-21/+166
(struct dwarf2_pinfo): Add dwarf_info_size and type_hash. Rearrange and update comments. (DWARF_INFO_SIZE): Define. (set_die_type, get_die_type, reset_die_and_siblings_types): New fucntions. (dwarf2_build_psymtabs_hard): Save dwarf_info_size. Initialize type_hash. (psymtab_to_symtab_1): Restore dwarf_info_size. Create per_cu data for the current compilation unit. (read_structure_scope, read_enumeration_type, read_array_type) (read_tag_pointer_type, read_tag_ptr_to_member_type) (read_tag_reference_type, read_tag_const_type) (read_tag_volatile_type, read_tag_string_type) (read_subroutine_type, read_typedef, read_base_type): Call set_die_type. (read_subrange_type): Likewise. Use dwarf2_attr_with_cu, since array bounds may be DIE references. (struct dwarf2_offset_and_type, offset_and_type_hash) (offset_and_type_eq): New.
2004-02-23 * dwarf2read.c (REF_HASH_SIZE): Move above struct dwarf2_cu.Daniel Jacobowitz2-21/+34
(struct dwarf2_cu): Add die_ref_table. (die_ref_table): Delete static variable. (store_in_ref_table): Take a comp unit argument and use its die_ref_table. (dwarf2_empty_hash_tables): Likewise. (read_comp_unit): Update call to dwarf2_empty_hash_tables. (read_die_and_children): Update call to store_in_ref_table. (follow_die_ref): Use the comp unit's die_ref_table.
2004-02-23 * dwarf2read.c (read_structure_scope): Don't create a symbolDaniel Jacobowitz2-40/+107
or call process_die. Return immediately if die->type is set. Call read_type_die before dwarf2_add_member_fn. (process_structure_scope): New function. (read_enumeration_type, read_enumeration_scope): New functions, broken out from read_enumeration. Don't create the enumeration type if it has already been created. (read_enumeration): Removed. (process_die): Call process_structure_scope, read_enumeration_type, and read_enumeration_scope. Just call new_symbol for base and subrange types. Add a comment about other type dies. (read_type_die): Call read_enumeration_type.
2004-02-22 * dwarf2read.c (dwarf2_attr_with_cu): New function, renamedDaniel Jacobowitz2-44/+119
from dwarf2_attr. Also return the compilation unit associated with the attribute if we have followed a reference. Complain if we return a reference attribute and the caller does not want the target compilation unit. (dwarf2_attr): Call dwarf2_attr_with_cu. (die_specification, dwarf2_extension): Also return a compilation unit. (follow_die_ref): Take attribute and compilation unit arguments. Call dwarf2_get_ref_die_offset. Also return the target compilation unit. (read_func_scope, read_structure_scope): Update calls to die_specification. Use the result. (read_namespace): Update call to dwarf2_extension. (namespace_name): Likewise. Use the result. (new_symbol): Call dwarf2_attr_with_cu to check for DIE type. (die_type): Likewise. Update call to follow_die_ref. Use the results. (dwarf2_add_member_fn, read_structure_scope): Likewise for DW_AT_containing_type. (die_containing_type): Likewise. (die_is_declaration): Likewise for DW_AT_specification.
2004-02-22Fix botched commit.Daniel Jacobowitz1-1/+1
2004-02-22 * dwarf2read.c (MAX_CACHE_AGE): Define.Daniel Jacobowitz2-14/+88
(struct dwarf2_cu): Add last_used counter. (free_comp_units_worker): New function, based on clear_per_cu_pointer. Support aging. (clear_per_cu_pointer): Use it. (free_cached_comp_units, free_one_cached_comp_unit): New functions. (dwarf2_build_psymtabs_hard): Keep read_in_chain across iterations. Free all cached comp units after building psymtabs. Free any cached copy of a comp unit before building a psymtab for it. (find_partial_die): Clear the last_used counter.
2004-02-22 * dwarf2read.c (partial_die_full_name): Always return NULL orDaniel Jacobowitz2-6/+13
malloc'd memory. Don't try to free real_parent->full_name.
2004-02-22 * dwarf2read.c (struct dwarf2_cu): Add read_in_chain and per_cu.Daniel Jacobowitz2-57/+386
(dwarf2_cu_tree): New variable. (struct dwarf2_per_cu_data): New type. (struct partial_die_info): Remove abbrev. Make tag a bitfield. Add full_name_set. (load_partial_dies): Take a flag indicating whether we are building a psymtab. (find_partial_die_in_comp_unit): Rename frome find_partial_die. (find_partial_die): New function to support inter-CU references. Return the CU of the found DIE. (splay_tree_obstack_allocate): Remove #if 0. (partial_read_comp_unit_head): New function, broken out from dwarf2_build_psymtabs_hard. (dwarf2_build_psymtabs_hard): Remove unused variable abbrev_ptr. Add the current CU to the splay tree if the tree already exists. Update call to load_partial_dies. (partial_die_full_name): Rewrite to support inter-CU references. (add_partial_symbol): Check and set pdi->full_name_set. (fixup_partial_die): Support inter-CU references. (dwarf2_find_containing_comp_unit, clear_per_cu_pointer) (load_comp_unit, create_comp_unit_tree, _initialize_dwarf2_read): New functions.
2004-02-22 * dwarf2read.c (partial_die_full_name): Remove allocate argument,Daniel Jacobowitz2-49/+51
always use concat. (add_partial_symbol): Copy the name from the psymbol.
2004-02-22 * dwarf2read.c (struct partial_die_info): Add full_name.Daniel Jacobowitz2-169/+138
(scan_partial_symbols, add_partial_symbol, add_partial_structure) (add_partial_enumeration): Change namespace argument to have_namespace_info flag. Move DW_TAG_namespace handling to add_partial_symbol. Update comments. (pdi_needs_namespace): Remove namespace argument. Handle DW_TAG_namespace. (partial_determine_prefix, partial_determine_prefix_aux): Remove. (dwarf2_build_psymtabs_hard): Update call to scan_partial_symbols. (partial_die_full_name): New function. (load_partial_die): Correct comment formatting. Don't handle DW_TAG_enumeration_type. (load_partial_dies): Correct comment formatting.
2004-02-22 * dwarf2read.c (load_partial_dies): Check for NULL name beforeDaniel Jacobowitz2-4/+10
adding types.
2004-02-22 * dwarf2read.c (maybe_specification_partial_die): Removed.Daniel Jacobowitz2-41/+79
(is_type_tag_for_partial): Renamed from is_type_tag. Remove some tags. (load_partial_dies): Call is_type_tag_for_partial. Handle simple DIEs early.
2004-02-21 * dwarf2read.c (scan_partial_symbols): Don't return anything. TakeDaniel Jacobowitz2-56/+85
a DIE argument instead of an info_ptr. (add_partial_namespace, add_partial_structure) add_partial_enumeration): Likewise. (load_partial_dies): Return the first interesting DIE. Do not add DIEs to the hash table if we aren't going to look them up. (dwarf2_build_psymtabs_hard): Adjust call to scan_partial_symbols.
2004-02-21 * dwarf2read.c (peek_die_abbrev): Add prototype.Daniel Jacobowitz2-17/+27
(load_partial_die): Take an abbrev and its uleb128 length as arguments. (dwarf2_build_psymtabs_hard): Adjust call to load_partial_die. (load_partial_dies): Likewise.
2004-02-21 * dwarf2read.c (splay_tree_obstack_allocate): Disable.Daniel Jacobowitz2-1/+11
(add_partial_symbol): Fix a warning. (fixup_partial_die): Recurse if necessary.
2004-02-21 * dwarf2read.c (partial_determine_prefix)Daniel Jacobowitz2-22/+96
(partial_determine_prefix_aux): New functions. (add_partial_symbol): Call partial_determine_prefix. (add_partial_structure): Remove workaround for DW_AT_specification. (load_partial_die): Save DW_AT_extension. (determine_prefix_aux): Reuse the return value of dwarf2_name.
2004-02-21 * dwarf2read.c (load_partial_dies): Follow unions. FollowDaniel Jacobowitz2-6/+12
aggregates for all non-C languages.
2004-02-21 * dwarf2read.c (dwarf2_build_psymtabs_hard): Estimate the initialDaniel Jacobowitz2-1/+7
size of the hash table.
2004-02-21 * Makefile.in (hashtab_h): Add.Daniel Jacobowitz1-1/+2
(dwarf2read.o): Update dependencies.
2004-02-21 * dwarf2read.c (struct dwarf2_cu): Add abbrev_obstack.Daniel Jacobowitz2-34/+50
(struct abbrev_info): Shorten two int flags. (dwarf_alloc_abbrev): Take a CU argument. (dwarf2_build_psymtabs_hard): Call dwarf2_empty_abbrev_table each time through the loop. Update cleanup argument. (psymtab_to_symtab_1): Update cleanup argument. (dwarf2_read_abbrevs, dwarf2_alloc_abbrev): Allocate on the abbrev_obstack. (dwarf2_empty_abbrev_table): Just call obstack_free.
2004-02-21 * Makefile.in (hashtab_h): Add.Daniel Jacobowitz2-11/+55
(dwarf2read.o): Update dependencies. * dwarf2read.c: Include "hashtab.h". (struct dwarf2_cu): Change partial_dies to an htab_t. (hash_obstack_allocate, partial_die_hash, partial_die_eq): New functions. (dwarf2_build_psymtabs_hard): Call htab_create_alloc_ex. (load_partial_dies): Call htab_find_slot_with_hash. (find_partial_die): Call htab_find_with_hash.
2004-02-21 * dwarf2read.c (struct partial_die_info): Use bitfields andDaniel Jacobowitz2-27/+36
rearrange members for packing. Replace spec_attr with spec_offset. (load_partial_dies): Only follow structures for C++. (load_partial_die): Use memset. Save specification attributes only as offsets. (fixup_partial_die): Adjust to use spec_offset.
2004-02-21 * dwarf2read.c (struct dwarf2_cu): Add partial_die_obstack.Daniel Jacobowitz2-7/+41
(splay_tree_obstack_allocate, splay_tree_obstack_deallocate): New functions. (dwarf2_build_psymtabs_hard): Use splay_tree_new_with_allocator and obstack_free to manage partial_dies. (load_partial_dies): Allocate partial DIEs on the obstack. Don't initialize the splay tree here.
2004-02-21 * dwarf2read.c (skip_leb128, peek_die_abbrev, skip_one_die)Daniel Jacobowitz2-27/+177
(skip_children): New functions. (locate_pdi_sibling): Call skip_children. (load_partial_dies): Use peek_die_abbrev and skip_one_die.