This is the mail archive of the
mailing list for the GDB project.
gdb in CVS is totally broken on Linux/i386
On Fri, Nov 12, 1999 at 02:11:33PM -0800, J.T. Conklin wrote:
> >>>>> "hjl" == H J Lu <firstname.lastname@example.org> writes:
> hjl> Hi, With old gdb, I can do
> hjl> (gdb) call foo (1)
> hjl> Now with gdb in CVS, I got "segmentation fault". Any ideas, BTW,
> hjl> I am using Linux/i386.
> You don't offer much to go on. For what it's worth, calling inferior
> functions with a freshly built-from-the-last-snapshot NetBSD/i386 gdb
> with the following test code:
The register fetch/store codes in i386-linux-nat.c are mostly bogus.
You cannot do
ptrace (PTRACE_GETFPREGS, inferior_pid, 0, (int) &buf);
since fpregset_t is not what the kernel expects. I got "segmentation
fault" even for "info reg". Jim, could you please take a look at
i386lnx-nat.c in my gdb 126.96.36.199 to see what the working one looks
like? I did
char inferior_fpregisters [FPREGISTER_BYTES];
ptrace (PTRACE_GETFPREGS, inferior_pid, 0, (int) inferior_fpregisters);