From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8093 invoked by alias); 15 Nov 2007 13:48:59 -0000 Received: (qmail 8082 invoked by uid 22791); 15 Nov 2007 13:48:58 -0000 X-Spam-Check-By: sourceware.org Received: from bluesmobile.specifix.com (HELO bluesmobile.specifix.com) (216.129.118.140) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 15 Nov 2007 13:48:53 +0000 Received: from [127.0.0.1] (bluesmobile.specifix.com [216.129.118.140]) by bluesmobile.specifix.com (Postfix) with ESMTP id D9B643BD8D; Thu, 15 Nov 2007 05:29:52 -0800 (PST) Subject: Re: 'g/G' GDB commands From: Michael Snyder To: Guillaume MENANT Cc: gdb@sourceware.org In-Reply-To: <473C1753.1090409@geensys.com> References: <473C1753.1090409@geensys.com> Content-Type: text/plain Date: Thu, 15 Nov 2007 13:48:00 -0000 Message-Id: <1195133953.12695.119.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.10.3 (2.10.3-4.fc7) Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2007-11/txt/msg00160.txt.bz2 On Thu, 2007-11-15 at 10:54 +0100, Guillaume MENANT wrote: > Hello, > > I'm trying to make a stub for GDB but i've a question about the 'g/G' > commands. I don't really understand the following paragraph : > > "The following |g|/|G| packets have previously been defined. In the > below, some thirty-two bit registers are transferred as sixty-four bits. > Those registers should be zero/sign extended (which?) to fill the space > allocated. Register bytes are transferred in target byte order. The two > nibbles within a register byte are transferred most-significant - > least-significant. Starting from here... > MIPS32 : All registers are transferred as thirty-two bit quantities in > the order: 32 general-purpose; sr; lo; hi; bad; cause; pc; 32 > floating-point registers; fsr; fir; fp. > MIPS64 : All registers are transferred as sixty-four bit quantities > (including thirty-two bit registers such as |sr|). The ordering is the > same as |MIPS32|." The text is about MIPS processors. > The chip I want to debug is the Atmel AT697E and I don't really know > which register of the AT697E corresponds to "32 general-purpose", "sr", > "lo", "hi", "bad", "cause", "fsr", "fir"... How can I have more > information about that Atmel is a Sparc processor. Its register set doesn't resemble the MIPS at all. MIPS was just chosen as an example in the text above. If you configure gdb for a generic sparc target, you can get an idea of the register set gdb will be looking for from a sparc variant.