From: Andrew Cagney Date: Fri, 18 Jul 2003 21:31:50 +0000 (+0000) Subject: 2003-07-18 Andrew Cagney X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=625b0b9752856b35e2052b4dacd96fd4cf4fd3e3;p=binutils-gdb.git 2003-07-18 Andrew Cagney * gdbarch.sh (DWARF2_BUILD_FRAME_INFO): Delete method. * gdbarch.h, gdbarch.c: Re-generate. * i386-tdep.c (i386_gdbarch_init): Do not set DWARF2_BUILD_FRAME_INFO. * elfread.c (elf_symfile_read): Call dwarf2_build_frame_info unconditionally. * alpha-tdep.c (alpha_dwarf2_init_abi): Do not set DWARF2_BUILD_FRAME_INFO. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 9fa5f4c5c97..7d5eedb08f3 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,14 @@ +2003-07-18 Andrew Cagney + + * gdbarch.sh (DWARF2_BUILD_FRAME_INFO): Delete method. + * gdbarch.h, gdbarch.c: Re-generate. + * i386-tdep.c (i386_gdbarch_init): Do not set + DWARF2_BUILD_FRAME_INFO. + * elfread.c (elf_symfile_read): Call dwarf2_build_frame_info + unconditionally. + * alpha-tdep.c (alpha_dwarf2_init_abi): Do not set + DWARF2_BUILD_FRAME_INFO. + 2003-07-18 Andrew Cagney From 2003-07-04 Kei Sakamoto : diff --git a/gdb/alpha-tdep.c b/gdb/alpha-tdep.c index 646b2619ffc..d6e95ca6b86 100644 --- a/gdb/alpha-tdep.c +++ b/gdb/alpha-tdep.c @@ -1585,7 +1585,6 @@ alpha_dwarf2_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch) { frame_unwind_append_sniffer (gdbarch, dwarf2_frame_sniffer); frame_base_append_sniffer (gdbarch, dwarf2_frame_base_sniffer); - set_gdbarch_dwarf2_build_frame_info (gdbarch, dwarf2_build_frame_info); } extern initialize_file_ftype _initialize_alpha_tdep; /* -Wmissing-prototypes */ diff --git a/gdb/elfread.c b/gdb/elfread.c index ff766fb7c26..a655797484f 100644 --- a/gdb/elfread.c +++ b/gdb/elfread.c @@ -610,8 +610,9 @@ elf_symfile_read (struct objfile *objfile, int mainline) ei.lnoffset, ei.lnsize); } - if (DWARF2_BUILD_FRAME_INFO_P ()) - DWARF2_BUILD_FRAME_INFO(objfile); + /* FIXME: kettenis/20030504: This still needs to be integrated with + dwarf2read.c in a better way. */ + dwarf2_build_frame_info (objfile); } /* This cleans up the objfile's sym_stab_info pointer, and the chain of diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c index 8567c0555ae..ee06a95e673 100644 --- a/gdb/gdbarch.c +++ b/gdb/gdbarch.c @@ -270,7 +270,6 @@ struct gdbarch gdbarch_sigtramp_end_ftype *sigtramp_end; gdbarch_in_function_epilogue_p_ftype *in_function_epilogue_p; gdbarch_construct_inferior_arguments_ftype *construct_inferior_arguments; - gdbarch_dwarf2_build_frame_info_ftype *dwarf2_build_frame_info; gdbarch_elf_make_msymbol_special_ftype *elf_make_msymbol_special; gdbarch_coff_make_msymbol_special_ftype *coff_make_msymbol_special; const char * name_of_malloc; @@ -437,7 +436,6 @@ struct gdbarch startup_gdbarch = 0, /* sigtramp_end */ generic_in_function_epilogue_p, /* in_function_epilogue_p */ construct_inferior_arguments, /* construct_inferior_arguments */ - 0, /* dwarf2_build_frame_info */ 0, /* elf_make_msymbol_special */ 0, /* coff_make_msymbol_special */ "malloc", /* name_of_malloc */ @@ -747,7 +745,6 @@ verify_gdbarch (struct gdbarch *gdbarch) /* Skip verify of sigtramp_end, has predicate */ /* Skip verify of in_function_epilogue_p, invalid_p == 0 */ /* Skip verify of construct_inferior_arguments, invalid_p == 0 */ - /* Skip verify of dwarf2_build_frame_info, has predicate */ /* Skip verify of elf_make_msymbol_special, invalid_p == 0 */ /* Skip verify of coff_make_msymbol_special, invalid_p == 0 */ /* Skip verify of name_of_malloc, invalid_p == 0 */ @@ -1687,29 +1684,6 @@ gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file) "gdbarch_dump: DEPRECATED_USE_GENERIC_DUMMY_FRAMES = %d\n", DEPRECATED_USE_GENERIC_DUMMY_FRAMES); #endif -#ifdef DWARF2_BUILD_FRAME_INFO_P - fprintf_unfiltered (file, - "gdbarch_dump: %s # %s\n", - "DWARF2_BUILD_FRAME_INFO_P()", - XSTRING (DWARF2_BUILD_FRAME_INFO_P ())); - fprintf_unfiltered (file, - "gdbarch_dump: DWARF2_BUILD_FRAME_INFO_P() = %d\n", - DWARF2_BUILD_FRAME_INFO_P ()); -#endif -#ifdef DWARF2_BUILD_FRAME_INFO -#if GDB_MULTI_ARCH - /* Macro might contain `[{}]' when not multi-arch */ - fprintf_unfiltered (file, - "gdbarch_dump: %s # %s\n", - "DWARF2_BUILD_FRAME_INFO(objfile)", - XSTRING (DWARF2_BUILD_FRAME_INFO (objfile))); -#endif - if (GDB_MULTI_ARCH) - fprintf_unfiltered (file, - "gdbarch_dump: DWARF2_BUILD_FRAME_INFO = <0x%08lx>\n", - (long) current_gdbarch->dwarf2_build_frame_info - /*DWARF2_BUILD_FRAME_INFO ()*/); -#endif #ifdef DWARF2_REG_TO_REGNUM fprintf_unfiltered (file, "gdbarch_dump: %s # %s\n", @@ -5419,30 +5393,6 @@ set_gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch, gdbarch->construct_inferior_arguments = construct_inferior_arguments; } -int -gdbarch_dwarf2_build_frame_info_p (struct gdbarch *gdbarch) -{ - gdb_assert (gdbarch != NULL); - return gdbarch->dwarf2_build_frame_info != NULL; -} - -void -gdbarch_dwarf2_build_frame_info (struct gdbarch *gdbarch, struct objfile *objfile) -{ - gdb_assert (gdbarch != NULL); - gdb_assert (gdbarch->dwarf2_build_frame_info != NULL); - if (gdbarch_debug >= 2) - fprintf_unfiltered (gdb_stdlog, "gdbarch_dwarf2_build_frame_info called\n"); - gdbarch->dwarf2_build_frame_info (objfile); -} - -void -set_gdbarch_dwarf2_build_frame_info (struct gdbarch *gdbarch, - gdbarch_dwarf2_build_frame_info_ftype dwarf2_build_frame_info) -{ - gdbarch->dwarf2_build_frame_info = dwarf2_build_frame_info; -} - void gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch, asymbol *sym, struct minimal_symbol *msym) { diff --git a/gdb/gdbarch.h b/gdb/gdbarch.h index e4252eae7e5..9de12223fa5 100644 --- a/gdb/gdbarch.h +++ b/gdb/gdbarch.h @@ -2939,41 +2939,6 @@ typedef char * (gdbarch_construct_inferior_arguments_ftype) (struct gdbarch *gdb extern char * gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch, int argc, char **argv); extern void set_gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch, gdbarch_construct_inferior_arguments_ftype *construct_inferior_arguments); -#if defined (DWARF2_BUILD_FRAME_INFO) -/* Legacy for systems yet to multi-arch DWARF2_BUILD_FRAME_INFO */ -#if !defined (DWARF2_BUILD_FRAME_INFO_P) -#define DWARF2_BUILD_FRAME_INFO_P() (1) -#endif -#endif - -/* Default predicate for non- multi-arch targets. */ -#if (!GDB_MULTI_ARCH) && !defined (DWARF2_BUILD_FRAME_INFO_P) -#define DWARF2_BUILD_FRAME_INFO_P() (0) -#endif - -extern int gdbarch_dwarf2_build_frame_info_p (struct gdbarch *gdbarch); -#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DWARF2_BUILD_FRAME_INFO_P) -#error "Non multi-arch definition of DWARF2_BUILD_FRAME_INFO" -#endif -#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DWARF2_BUILD_FRAME_INFO_P) -#define DWARF2_BUILD_FRAME_INFO_P() (gdbarch_dwarf2_build_frame_info_p (current_gdbarch)) -#endif - -/* Default (function) for non- multi-arch platforms. */ -#if (!GDB_MULTI_ARCH) && !defined (DWARF2_BUILD_FRAME_INFO) -#define DWARF2_BUILD_FRAME_INFO(objfile) (internal_error (__FILE__, __LINE__, "DWARF2_BUILD_FRAME_INFO"), 0) -#endif - -typedef void (gdbarch_dwarf2_build_frame_info_ftype) (struct objfile *objfile); -extern void gdbarch_dwarf2_build_frame_info (struct gdbarch *gdbarch, struct objfile *objfile); -extern void set_gdbarch_dwarf2_build_frame_info (struct gdbarch *gdbarch, gdbarch_dwarf2_build_frame_info_ftype *dwarf2_build_frame_info); -#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DWARF2_BUILD_FRAME_INFO) -#error "Non multi-arch definition of DWARF2_BUILD_FRAME_INFO" -#endif -#if !defined (DWARF2_BUILD_FRAME_INFO) -#define DWARF2_BUILD_FRAME_INFO(objfile) (gdbarch_dwarf2_build_frame_info (current_gdbarch, objfile)) -#endif - /* Default (function) for non- multi-arch platforms. */ #if (!GDB_MULTI_ARCH) && !defined (ELF_MAKE_MSYMBOL_SPECIAL) #define ELF_MAKE_MSYMBOL_SPECIAL(sym, msym) (default_elf_make_msymbol_special (sym, msym)) diff --git a/gdb/gdbarch.sh b/gdb/gdbarch.sh index 736547e7698..4a16d53fa86 100755 --- a/gdb/gdbarch.sh +++ b/gdb/gdbarch.sh @@ -725,7 +725,6 @@ m:::int:in_function_epilogue_p:CORE_ADDR addr:addr::0:generic_in_function_epilog # ARGC is the number of elements in the vector. # ARGV is an array of strings, one per argument. m::CONSTRUCT_INFERIOR_ARGUMENTS:char *:construct_inferior_arguments:int argc, char **argv:argc, argv:::construct_inferior_arguments::0 -F:2:DWARF2_BUILD_FRAME_INFO:void:dwarf2_build_frame_info:struct objfile *objfile:objfile f:2:ELF_MAKE_MSYMBOL_SPECIAL:void:elf_make_msymbol_special:asymbol *sym, struct minimal_symbol *msym:sym, msym:::default_elf_make_msymbol_special::0 f:2:COFF_MAKE_MSYMBOL_SPECIAL:void:coff_make_msymbol_special:int val, struct minimal_symbol *msym:val, msym:::default_coff_make_msymbol_special::0 v:2:NAME_OF_MALLOC:const char *:name_of_malloc::::"malloc":"malloc"::0:%s:NAME_OF_MALLOC diff --git a/gdb/i386-tdep.c b/gdb/i386-tdep.c index 66741944cf9..328dff29f3a 100644 --- a/gdb/i386-tdep.c +++ b/gdb/i386-tdep.c @@ -1813,7 +1813,6 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) /* Hook in the DWARF CFI frame unwinder. */ frame_unwind_append_sniffer (gdbarch, dwarf2_frame_sniffer); - set_gdbarch_dwarf2_build_frame_info (gdbarch, dwarf2_build_frame_info); frame_base_set_default (gdbarch, &i386_frame_base);