From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8118 invoked by alias); 19 May 2002 15:10:08 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 8103 invoked from network); 19 May 2002 15:10:07 -0000 Received: from unknown (HELO localhost.redhat.com) (24.112.240.27) by sources.redhat.com with SMTP; 19 May 2002 15:10:07 -0000 Received: from cygnus.com (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id 5CED93C2B; Sun, 19 May 2002 11:10:17 -0400 (EDT) Message-ID: <3CE7C059.90603@cygnus.com> Date: Sun, 19 May 2002 08:10:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:1.0rc2) Gecko/20020518 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Richard.Earnshaw@arm.com Cc: gdb-patches@sources.redhat.com Subject: Re: [wip/cagney_regbuf-20020515-branch] Introduce regcache_move() References: <200205191447.PAA25151@cam-mail2.cambridge.arm.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2002-05/txt/msg00802.txt.bz2 > Hmm, so each pseudo would allocate a unique address even though there was > no real regbuf space for it; something like > > 0 4 4*(n-1) 4*n 4*(n+1) ... > +---------+---------+ +---------+---------+---------+ > | Phys r0 | Phys r1 | ... | Phys rn | Pseu r0 | Pseu r1 | > +---------+---------+ +---------+---------+---------+ > | REGBUF ... | > +-------------------- ----------+ > > Then each reg would have a unique address. Provided we always call > through the correct interfaces, and never use > > memcpy (grub_around...registers() + REGISTER_BYTE(PseudoN), ...) > > then this would work. Yes (saving diagram for doco). (Just renaming grub_ to legacy_grub_ ....) >> Rock warning: GDB uses the above to handle (with limited success) values >> that cross two registers. For instance a long long in two adjacent long >> registers. See value_from_register(). > > > I've been told ARM's own C compiler can put long longs in non-adjacent > register pairs. At some point I will need to support that... it will > probably mean being able to read from some ordered list of registers, or > some such. Yep, for GCC, dwarf2 location expressions let you scatter a value across memory and registers. I think GDB's `struct value' will need an upgrade - somebody elses problem. Andrew