From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5772 invoked by alias); 26 Nov 2001 11:44:07 -0000 Mailing-List: contact gdb-patches-help@sourceware.cygnus.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 5646 invoked from network); 26 Nov 2001 11:44:01 -0000 Received: from unknown (HELO cerbere.u-strasbg.fr) (130.79.112.7) by sourceware.cygnus.com with SMTP; 26 Nov 2001 11:44:01 -0000 Received: from laocoon (laocoon.u-strasbg.fr [130.79.112.72]) by cerbere.u-strasbg.fr (8.9.3/8.8.7) with ESMTP id MAA27607 for ; Mon, 26 Nov 2001 12:44:00 +0100 Message-ID: <4.2.0.58.20011126123941.01cc22f0@ics.u-strasbg.fr> X-Sender: muller@ics.u-strasbg.fr X-Mailer: QUALCOMM Windows Eudora Pro Version 4.2.0.58 Date: Sun, 11 Nov 2001 13:37:00 -0000 To: gdb-patches From: Pierre Muller Subject: Re: [RFA] SSE registers for cygxin target. In-Reply-To: <20011126123525.R14975@cygbert.vinschen.de> References: <4.2.0.58.20011126110847.01cb6c20@ics.u-strasbg.fr> <4.2.0.58.20011126104808.00acab48@ics.u-strasbg.fr> <4.2.0.58.20011126110847.01cb6c20@ics.u-strasbg.fr> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=====================_241201679==_" X-SW-Source: 2001-11/txt/msg00225.txt.bz2 Message-ID: <20011111133700.-sQLYF9ZkkwQEEjox_rtYrO58YnCfbbu-TDnajAE8zE@z> --=====================_241201679==_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8bit Content-length: 3177 At 12:35 26/11/2001 , Corinna Vinschen a écrit: >On Mon, Nov 26, 2001 at 11:10:16AM +0100, Pierre Muller wrote: > > Apparently, my Eudora change is not enough to get the patch to be correct, > > so I add it attached. > >The attachment is corrupted as well, unfortunately. Sorry, its probably because Eudora also misbehaves with text files that only contain LF.... Lets try once again with Dos like CR/LF in source... hope that will help. I also send the diff again in the text itself with yet another Eudora setting. Index: win32-nat.c =================================================================== RCS file: /cvs/src/src/gdb/win32-nat.c,v retrieving revision 1.38 diff -u -r1.38 win32-nat.c --- win32-nat.c 2001/11/24 19:00:03 1.38 +++ win32-nat.c 2001/11/26 09:47:09 @@ -25,6 +25,7 @@ /* We assume we're being built with and will be used for cygwin. */ #include "defs.h" +#include "tm.h" /* required for SSE registers */ #include "frame.h" /* required by inferior.h */ #include "inferior.h" #include "target.h" @@ -66,6 +67,13 @@ #include #include +#ifdef HAVE_SSE_REGS +#define CONTEXT_DEBUGGER_DR CONTEXT_DEBUGGER | CONTEXT_EXTENDED_REGISTERS +#else +#define CONTEXT_DEBUGGER_DR CONTEXT_DEBUGGER +#endif + + /* The string sent by cygwin when it processes a signal. FIXME: This should be in a cygwin include file. */ #define CYGWIN_SIGNAL_STRING "cygwin: signal" @@ -169,6 +177,19 @@ context_offset (FloatSave.DataSelector), context_offset (FloatSave.DataOffset), context_offset (FloatSave.ErrorSelector) +#ifdef HAVE_SSE_REGS + /* XMM0-7 */ , + context_offset (ExtendedRegisters[0*16]), + context_offset (ExtendedRegisters[1*16]), + context_offset (ExtendedRegisters[2*16]), + context_offset (ExtendedRegisters[3*16]), + context_offset (ExtendedRegisters[4*16]), + context_offset (ExtendedRegisters[5*16]), + context_offset (ExtendedRegisters[6*16]), + context_offset (ExtendedRegisters[7*16]), + /* MXCSR untested */ + context_offset (ExtendedRegisters[8*16]) +#endif }; #undef context_offset @@ -210,7 +231,7 @@ else if (get_context < 0) th->suspend_count = -1; - th->context.ContextFlags = CONTEXT_DEBUGGER; + th->context.ContextFlags = CONTEXT_DEBUGGER_DR; GetThreadContext (th->h, &th->context); } return th; Index: config/i386/tm-cygwin.h =================================================================== RCS file: /cvs/src/src/gdb/config/i386/tm-cygwin.h,v retrieving revision 1.10 diff -u -r1.10 tm-cygwin.h --- tm-cygwin.h 2001/11/01 16:17:08 1.10 +++ tm-cygwin.h 2001/11/26 09:47:09 @@ -19,8 +19,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ - -#undef HAVE_SSE_REGS /* FIXME! win32-nat.c needs to support XMMi registers */ +/* Use SSE registers if winnt.h contains information about them. */ +#ifdef HAVE_CONTEXT_EXTENDED_REGISTERS +#define HAVE_SSE_REGS +#else +#undef HAVE_SSE_REGS +#endif /* CONTEXT_EXTENDED_REGISTERS */ #define HAVE_I387_REGS #include "i386/tm-i386.h" --=====================_241201679==_ Content-Type: text/plain; charset="us-ascii" Content-length: 2539 Index: win32-nat.c =================================================================== RCS file: /cvs/src/src/gdb/win32-nat.c,v retrieving revision 1.38 diff -u -r1.38 win32-nat.c --- win32-nat.c 2001/11/24 19:00:03 1.38 +++ win32-nat.c 2001/11/26 09:47:09 @@ -25,6 +25,7 @@ /* We assume we're being built with and will be used for cygwin. */ #include "defs.h" +#include "tm.h" /* required for SSE registers */ #include "frame.h" /* required by inferior.h */ #include "inferior.h" #include "target.h" @@ -66,6 +67,13 @@ #include #include +#ifdef HAVE_SSE_REGS +#define CONTEXT_DEBUGGER_DR CONTEXT_DEBUGGER | CONTEXT_EXTENDED_REGISTERS +#else +#define CONTEXT_DEBUGGER_DR CONTEXT_DEBUGGER +#endif + + /* The string sent by cygwin when it processes a signal. FIXME: This should be in a cygwin include file. */ #define CYGWIN_SIGNAL_STRING "cygwin: signal" @@ -169,6 +177,19 @@ context_offset (FloatSave.DataSelector), context_offset (FloatSave.DataOffset), context_offset (FloatSave.ErrorSelector) +#ifdef HAVE_SSE_REGS + /* XMM0-7 */ , + context_offset (ExtendedRegisters[0*16]), + context_offset (ExtendedRegisters[1*16]), + context_offset (ExtendedRegisters[2*16]), + context_offset (ExtendedRegisters[3*16]), + context_offset (ExtendedRegisters[4*16]), + context_offset (ExtendedRegisters[5*16]), + context_offset (ExtendedRegisters[6*16]), + context_offset (ExtendedRegisters[7*16]), + /* MXCSR untested */ + context_offset (ExtendedRegisters[8*16]) +#endif }; #undef context_offset @@ -210,7 +231,7 @@ else if (get_context < 0) th->suspend_count = -1; - th->context.ContextFlags = CONTEXT_DEBUGGER; + th->context.ContextFlags = CONTEXT_DEBUGGER_DR; GetThreadContext (th->h, &th->context); } return th; Index: config/i386/tm-cygwin.h =================================================================== RCS file: /cvs/src/src/gdb/config/i386/tm-cygwin.h,v retrieving revision 1.10 diff -u -r1.10 tm-cygwin.h --- tm-cygwin.h 2001/11/01 16:17:08 1.10 +++ tm-cygwin.h 2001/11/26 09:47:09 @@ -19,8 +19,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ - -#undef HAVE_SSE_REGS /* FIXME! win32-nat.c needs to support XMMi registers */ +/* Use SSE registers if winnt.h contains information about them. */ +#ifdef HAVE_CONTEXT_EXTENDED_REGISTERS +#define HAVE_SSE_REGS +#else +#undef HAVE_SSE_REGS +#endif /* CONTEXT_EXTENDED_REGISTERS */ #define HAVE_I387_REGS #include "i386/tm-i386.h" --=====================_241201679==_ Content-Type: text/plain; charset="us-ascii" Content-length: 176 Pierre Muller Institut Charles Sadron 6,rue Boussingault F 67083 STRASBOURG CEDEX (France) mailto:muller@ics.u-strasbg.fr Phone : (33)-3-88-41-40-07 Fax : (33)-3-88-41-40-99 --=====================_241201679==_--