aboutsummaryrefslogtreecommitdiff
path: root/gdb/stack.c
diff options
context:
space:
mode:
authorJim Blandy <jimb@codesourcery.com>2007-12-04 23:43:57 +0000
committerJim Blandy <jimb@codesourcery.com>2007-12-04 23:43:57 +0000
commit801e3a5b5681c44b2fec1b392dddec386870647c (patch)
treefc5540169fef73f5721542765234f47023c7763d /gdb/stack.c
parentc420411fe81ad583b2154fd9338fd0076761d99d (diff)
downloadgdb-801e3a5b5681c44b2fec1b392dddec386870647c.zip
gdb-801e3a5b5681c44b2fec1b392dddec386870647c.tar.gz
gdb-801e3a5b5681c44b2fec1b392dddec386870647c.tar.bz2
Support lexical blocks and function bodies that occupy
non-contiguous address ranges. * addrmap.c, addrmap.h: New files. * block.h (struct addrmap): New forward declaration. (struct blockvector): New member, 'map'. (BLOCKVECTOR_MAP): New accessor macro. * block.c: #include "addrmap.h" (blockvector_for_pc_sect): If the blockvector we've found has an address map, use it instead of searching the blocks. * buildsym.c: #include "addrmap.h" (pending_addrmap_obstack, pending_addrmap_interesting): New static variables. (really_free_pendings): If we have a pending addrmap, free it too. (record_block_range): New function. (make_blockvector): If we have an interesting pending addrmap, record it in the new blockvector. (start_symtab, buildsym_init): Assert that there is no pending addrmap now; we should have cleaned up any addrmaps we'd built previously. (end_symtab): If there is a pending addrmap left over that didn't get included in the blockvector, free it. * buildsym.h (struct addrmap): New forward declaration. (record_block_range): New prototype. * objfiles.c: #include "addrmap.h". (objfile_relocate): Relocate the blockvector's address map, if present. * dwarf2read.c (dwarf2_record_block_ranges): New function. (read_func_scope, read_lexical_block_scope): Call it. * Makefile.in (SFILES): Add addrmap.c. (addrmap_h): New header dependency variable. (COMMON_OBS): Add addrmap.o. (addrmap.o): New rule.l (block.o, objfiles.o, buildsym.o): Depend on $(addrmap_h). * block.c (blockvector_for_pc, blockvector_for_pc_sect): Return a pointer to the block, not its index in the blockvector. (block_for_pc_sect): Use the returned block, instead of looking it up ourselves. * block.h (blockvector_for_pc, blockvector_for_pc_sect): Update declarations. * breakpoint.c (resolve_sal_pc): Use returned block, instead of looking it up ourselves. * stack.c (print_frame_label_vars): Disable function, which depends on the block's index. * buildsym.c (finish_block): Return the block we've built. * buildsym.h (finish_block): Update prototype. * defs.h (CORE_ADDR_MAX): New constant.
Diffstat (limited to 'gdb/stack.c')
-rw-r--r--gdb/stack.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/gdb/stack.c b/gdb/stack.c
index caf23a4..c23529f 100644
--- a/gdb/stack.c
+++ b/gdb/stack.c
@@ -1471,6 +1471,9 @@ static void
print_frame_label_vars (struct frame_info *frame, int this_level_only,
struct ui_file *stream)
{
+#if 1
+ fprintf_filtered (stream, "print_frame_label_vars disabled.\n");
+#else
struct blockvector *bl;
struct block *block = get_frame_block (frame, 0);
int values_printed = 0;
@@ -1531,6 +1534,7 @@ print_frame_label_vars (struct frame_info *frame, int this_level_only,
if (!values_printed && !this_level_only)
fprintf_filtered (stream, _("No catches.\n"));
+#endif
}
void