This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: [RFC] Core files and the architecture vector
Date: Sat, 11 Oct 2003 18:26:22 -0400
From: Daniel Jacobowitz <drow@mvista.com>
I'll respond to the rest of your message later but...
On Sun, Oct 12, 2003 at 12:07:32AM +0200, Mark Kettenis wrote:
> Let me elaborate on the second point. When a 32-bit executable
> running on FreeBSD/amd64 or GNU/Linux x86-64 dumps, it produces an
> 64-bit ELF core file. To be able to make any sense out of this core
> file, we'll need the 64-bit register set definitions that are provided
> by the regset_from_core_section method from the 64-bit architecture
I still don't think this bit makes much sense. The process sees only
32-bit registers; the core should contain only 32-bit registers.
Well, it's not for me to decide what how the various OSes dump core
:-(.
Anyway even for 32-bit only stuff the core file architecture and
executable architecture might differ. When running a GNU/Linux i386
binary on FreeBSD/i386, it produces a FreeBSD/i386 corefile.
Do we see 32-bit or 64-bit registers from ptrace when debugging such a
process?
At least on FreeBSD/amd64 you see the 64-bit register with ptrace.
Mark