From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6085 invoked by alias); 7 Apr 2002 18:54:19 -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 6053 invoked from network); 7 Apr 2002 18:54:18 -0000 Received: from unknown (HELO localhost.redhat.com) (24.112.240.27) by sources.redhat.com with SMTP; 7 Apr 2002 18:54:18 -0000 Received: from cygnus.com (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id E1C693CBF; Sun, 7 Apr 2002 14:54:02 -0400 (EDT) Message-ID: <3CB095CA.6090405@cygnus.com> Date: Sun, 07 Apr 2002 11:54:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:0.9.9) Gecko/20020328 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Daniel Jacobowitz Cc: gdb-patches@sources.redhat.com Subject: Re: [patch] Add PS_REGNUM. References: <3CAF59CA.1060304@cygnus.com> <20020407143417.A26612@nevyn.them.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2002-04/txt/msg00257.txt.bz2 > On Sat, Apr 06, 2002 at 03:25:46PM -0500, Andrew Cagney wrote: > >> Hello, >> >> This patch just fills in a gap in the current *_REGNUMs by adding >> PS_REGNUM. Unlike the others. This one really does allow -1 as the >> default value. >> >> (FP_REGNUM et.al. require real values as there is code around that, >> unfortunatly, depends on there being a real FP register et.al. ulgh). >> >> committed, >> Andrew > > > What benefit does this have? PC_REGNUM I can understand. Even > SP_REGNUM. But it's not like PS_REGNUM has any meaning to common > code... I think it is the other way round. PS_REGNUM is the only one being used correctly - when >=0, std-regs.c (new file) maps $ps onto a hardware/pseudo register. Cf the GDB manual. On the other hand FP_REGNUM, PC_REGNUM and SP_REGNUM that are being used ``incorrectly''(1). They have no meaning outside of std-regs.c yet are used throughout GDB. enjoy, Andrew (1) I'm rewriting history here. There was a time when the FP_REGNUM was both a hardware register and the frame-base.