From: Joel Brobecker Date: Thu, 17 Apr 2008 21:00:53 +0000 (+0000) Subject: * rs6000-tdep.c (rs6000_gdbarch_init): Use the BFD architecture, X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=475bbd17e013a6aaa565d2d664572af56a1bd23d;p=binutils-gdb.git * rs6000-tdep.c (rs6000_gdbarch_init): Use the BFD architecture, rather than a hard-coded architecture, for xcoff executables. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index ffb98b2ab1b..7fdc17d10c5 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2008-04-17 Dennis Roberts + + * rs6000-tdep.c (rs6000_gdbarch_init): Use the BFD architecture, + rather than a hard-coded architecture, for xcoff executables. + 2008-04-17 Doug Evans * buildsym.c (watch_main_source_file_lossage): New fn. diff --git a/gdb/rs6000-tdep.c b/gdb/rs6000-tdep.c index fc12619a7b0..50dbf2b27b8 100644 --- a/gdb/rs6000-tdep.c +++ b/gdb/rs6000-tdep.c @@ -3307,18 +3307,9 @@ rs6000_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) wordsize = 4; } - if (!from_xcoff_exec) - { - arch = info.bfd_arch_info->arch; - mach = info.bfd_arch_info->mach; - } - else - { - arch = bfd_arch_powerpc; - bfd_default_set_arch_mach (&abfd, arch, 0); - info.bfd_arch_info = bfd_get_arch_info (&abfd); - mach = info.bfd_arch_info->mach; - } + /* Get the architecture and machine from the BFD. */ + arch = info.bfd_arch_info->arch; + mach = info.bfd_arch_info->mach; /* For e500 executables, the apuinfo section is of help here. Such section contains the identifier and revision number of each