This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: need help with untyped core dumps and multi-arch
- To: gdb at sourceware dot cygnus dot com
- Subject: Re: need help with untyped core dumps and multi-arch
- From: jtc at redback dot com (J.T. Conklin)
- Date: 27 Oct 2000 10:38:26 -0700
- Cc: binutils at sourceware dot cygnus dot com
- References: <5mitqhan5h.fsf@jtc.redback.com>
- Reply-To: jtc at redback dot com
>>>>> "jtc" == J T Conklin <jtc@redback.com> writes:
jtc> Now that the powerpc-port is multi-arched, I get a failure in set_
jtc> gdbarch_from_file(), as gdbarch_update_p() is not able to set the
jtc> architecture from the core dump file. The problem is bfd_get_arch_
jtc> info() returns bfd_arch_unknown.
After thinking about this for a few days, I've convinced myself that
while BFD could probably be made to return the target architecture of
our crash dump files, that GDB needs to handle untyped core dumps for
those formats that don't the target arch (e.g. Cisco dump format).
A quick hack that works fine for me, is to remove the call to
set_gdbarch_from_file() in corelow.c:core_open(). But I suspect that
this isn't the right fix --- presumably there was a reason to set the
architecture from the core dump file. Anyone know the scoop here?
My best guess is that we need a function to set the architecture from
a bfd if it is known, otherwise to leave things as they are. In that
case, GDB would continue to use the architecture of the exec file.
Thoughts?
--jtc
--
J.T. Conklin
RedBack Networks