From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27655 invoked by alias); 15 May 2002 18:45:04 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 27646 invoked from network); 15 May 2002 18:45:02 -0000 Received: from unknown (HELO cygnus.com) (205.180.83.203) by sources.redhat.com with SMTP; 15 May 2002 18:45:02 -0000 Received: from localhost.redhat.com (remus.sfbay.redhat.com [172.16.27.252]) by runyon.cygnus.com (8.8.7-cygnus/8.8.7) with ESMTP id LAA08556; Wed, 15 May 2002 11:44:55 -0700 (PDT) Received: by localhost.redhat.com (Postfix, from userid 469) id 379D710FC9; Wed, 15 May 2002 14:44:17 -0400 (EDT) From: Elena Zannoni MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15586.44161.56803.886450@localhost.redhat.com> Date: Wed, 15 May 2002 11:45:00 -0000 To: Richard.Earnshaw@arm.com Cc: Elena Zannoni , Andrew Cagney , gdb@sources.redhat.com Subject: Re: REGISTER_BYTE() and pseudos In-Reply-To: <200205151807.TAA18580@cam-mail2.cambridge.arm.com> References: <15586.40018.722458.418880@localhost.redhat.com> <200205151807.TAA18580@cam-mail2.cambridge.arm.com> X-SW-Source: 2002-05/txt/msg00178.txt.bz2 Richard Earnshaw writes: > OK, I see what you are doing. Basically, if a pseudo maps onto a real > register somewhere in the regcache, you return the address of that. > > However, what should be done if the pseudo doesn't exist as a single > entry, or if it is a manipulation of a real register? For example, on the > ARM, the CPSR may be just a few bits retrieved from the PC. > > Also, what would you do if you needed to address two non-adjacent > registers? > > R. Look at sh64_pseudo_register_read() and how FPSCR is treated. FPSCR is built as a collection of non-adjacent bits in various architectural registers. In theory sh64_pseudo_register_read shouldn't even be there. All that code should just be part of sh64_register_read. Basically sh64_register_read just does what it wants with the registers, almost like if there was no difference between pseudos and real registers. Same with sh64_register_write and sh64_pseudo_register_write. Elena