diff options
author | Mark Kettenis <kettenis@gnu.org> | 2004-08-14 16:01:39 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@gnu.org> | 2004-08-14 16:01:39 +0000 |
commit | 102765c076d22178b4b5c4c60f4a72bcb65c8f78 (patch) | |
tree | 3fab35d7785938e6a0c920a6fbd4c232e1583d40 | |
parent | 7767906b4f53e296fb1696293a07c589cb43499a (diff) | |
download | gdb-102765c076d22178b4b5c4c60f4a72bcb65c8f78.tar.gz |
* i386-linux-nat.c (dummy_sse_values): Remove function and
prototype.
(i386_linux_dr_get): Fix typo in comment.
(LINUX_SYSCALL_REGNUM): Define as I386_EAX_REGNUM.
-rw-r--r-- | gdb/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/i386-linux-nat.c | 30 |
2 files changed, 7 insertions, 28 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 8e320853c14..3bebe26237c 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,10 @@ 2004-08-14 Mark Kettenis <kettenis@gnu.org> + * i386-linux-nat.c (dummy_sse_values): Remove function and + prototype. + (i386_linux_dr_get): Fix typo in comment. + (LINUX_SYSCALL_REGNUM): Define as I386_EAX_REGNUM. + * config/i386/obsd64.mt (TDEPFILES): Add i386obsd-tdep.o. * defs.h (deprecated_error_hook): Remove RETURN and ATTR_NORETURN diff --git a/gdb/i386-linux-nat.c b/gdb/i386-linux-nat.c index 38bfef65dc2..7229d0638b4 100644 --- a/gdb/i386-linux-nat.c +++ b/gdb/i386-linux-nat.c @@ -73,9 +73,6 @@ /* Defines ps_err_e, struct ps_prochandle. */ #include "gdb_proc_service.h" - -/* Prototypes for local functions. */ -static void dummy_sse_values (void); /* The register sets used in GNU/Linux ELF core-dumps are identical to @@ -323,7 +320,6 @@ void supply_fpregset (elf_fpregset_t *fpregsetp) { i387_supply_fsave (current_regcache, -1, fpregsetp); - dummy_sse_values (); } /* Fill register REGNO (if it is a floating-point register) in @@ -458,32 +454,10 @@ store_fpxregs (int tid, int regno) return 1; } -/* Fill the XMM registers in the register array with dummy values. For - cases where we don't have access to the XMM registers. I think - this is cleaner than printing a warning. For a cleaner solution, - we should gdbarchify the i386 family. */ - -static void -dummy_sse_values (void) -{ - struct gdbarch_tdep *tdep = gdbarch_tdep (current_gdbarch); - /* C doesn't have a syntax for NaN's, so write it out as an array of - longs. */ - static long dummy[4] = { 0xffffffff, 0xffffffff, 0xffffffff, 0xffffffff }; - static long mxcsr = 0x1f80; - int reg; - - for (reg = 0; reg < tdep->num_xmm_regs; reg++) - regcache_raw_supply (current_regcache, XMM0_REGNUM + reg, (char *) dummy); - if (tdep->num_xmm_regs > 0) - regcache_raw_supply (current_regcache, MXCSR_REGNUM, (char *) &mxcsr); -} - #else static int fetch_fpxregs (int tid) { return 0; } static int store_fpxregs (int tid, int regno) { return 0; } -static void dummy_sse_values (void) {} #endif /* HAVE_PTRACE_GETFPXREGS */ @@ -659,7 +633,7 @@ i386_linux_dr_get (int regnum) /* FIXME: kettenis/2001-03-27: Calling perror_with_name if the ptrace call fails breaks debugging remote targets. The correct way to fix this is to add the hardware breakpoint and watchpoint - stuff to the target vectore. For now, just return zero if the + stuff to the target vector. For now, just return zero if the ptrace call fails. */ errno = 0; value = ptrace (PTRACE_PEEKUSER, tid, @@ -769,7 +743,7 @@ static const unsigned char linux_syscall[] = { 0xcd, 0x80 }; #define LINUX_SYSCALL_LEN (sizeof linux_syscall) /* The system call number is stored in the %eax register. */ -#define LINUX_SYSCALL_REGNUM 0 /* %eax */ +#define LINUX_SYSCALL_REGNUM I386_EAX_REGNUM /* We are specifically interested in the sigreturn and rt_sigreturn system calls. */ |