From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29632 invoked by alias); 7 May 2003 20:46:10 -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 29605 invoked from network); 7 May 2003 20:46:09 -0000 Received: from unknown (HELO crack.them.org) (146.82.138.56) by sources.redhat.com with SMTP; 7 May 2003 20:46:09 -0000 Received: from nevyn.them.org ([66.93.61.169] ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 19DVo3-0000JW-00; Wed, 07 May 2003 15:46:27 -0500 Received: from drow by nevyn.them.org with local (Exim 3.36 #1 (Debian)) id 19DVnd-0006iC-00; Wed, 07 May 2003 16:46:01 -0400 Date: Wed, 07 May 2003 20:46:00 -0000 From: Daniel Jacobowitz To: Elena Zannoni Cc: Will Schmidt , gdb-patches@sources.redhat.com, will_schmidt@vnet.ibm.com Subject: Re: [PATCH] new support for PPC64 architecture Message-ID: <20030507204601.GA25740@nevyn.them.org> Mail-Followup-To: Elena Zannoni , Will Schmidt , gdb-patches@sources.redhat.com, will_schmidt@vnet.ibm.com References: <16057.28595.975866.87959@localhost.redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <16057.28595.975866.87959@localhost.redhat.com> User-Agent: Mutt/1.5.1i X-SW-Source: 2003-05/txt/msg00099.txt.bz2 On Wed, May 07, 2003 at 04:42:27PM -0400, Elena Zannoni wrote: > Will Schmidt writes: > > All, > > > > This patch contains code that provides support for GDB on the PPC64 > > architecture. This patch will apply clean on top of the RedHat > > gdb-5.3post-0.20021129.29.src.rpm. (A patch against CVS will > > happen, but not today.. ) > > > > > > (See attached file: gdb-5.3post-ppc64-support.patch) > > > > > > -Will > > > > > > Will Schmidt > > willschm@us.ibm.com will_schmidt@vnet.ibm.com > > Linux on PowerPC-64 Development > > IBM Rochester > > A few comments/questions. You need changelogs, and the proper > copyright verbiage in the new files you are adding. The code needs to > conform to gnu coding standards as fas as spaces, indentation, > etc. You can run the new files through gdb_indent.sh to get the right > format. Comments should start with a capital letter, be full > sentences, and end with a period followed by 2 spaces. > > see below..... > > diff -rupPN gdb-5.2.1/gdb/config/powerpc/ppc64linux.mh src.ppc64/gdb/config/powerpc/ppc64linux.mh > --- gdb-5.2.1/gdb/config/powerpc/ppc64linux.mh 1969-12-31 18:00:00.000000000 -0600 > +++ src.ppc64/gdb/config/powerpc/ppc64linux.mh 2003-03-05 13:00:33.000000000 -0600 > @@ -0,0 +1,14 @@ > +# Host: PowerPC, running Linux > + > +XM_FILE= xm-linux.h > +XM_CLIBS= > + > +NAT_FILE= nm-linux.h > +NATDEPFILES= infptrace.o inftarg.o fork-child.o corelow.o linux-proc.o \ > + core-regset.o ppc-linux-nat.o proc-service.o thread-db.o lin-lwp.o \ > + gcore.o ppc-sysv-tdep.o > + > > this is the host makefile fragment, the *tdep.o files should be > included in the target makefile fragment, the .mt file, not here. > Actually if you exclude the .o's that ashould really be in the mt > file, then this file becomes almost identical to the linux.mh > file. Which makes me wonder if we really need a new file. > > +LOADLIBES = -ldl -lthread_db > + > > Why include thread_db? I don't see any other config files doing that. > > +GDBSERVER_DEPFILES= low-linux.o > > it is linux-low.o > > +GDBSERVER_LIBS= -lnss_dns -lnss_files -lresolv Actually, those lines are obsolete. It's on my list to go through and remove them all so people don't keep copying them. > diff -rupPN gdb-5.2.1/gdb/elfread.c src.ppc64/gdb/elfread.c > --- gdb-5.2.1/gdb/elfread.c 2002-03-25 10:50:20.000000000 -0600 > +++ src.ppc64/gdb/elfread.c 2003-01-28 13:28:24.000000000 -0600 > @@ -154,6 +154,12 @@ record_minimal_symbol_and_info (char *na > if (ms_type == mst_text || ms_type == mst_file_text) > address = SMASH_TEXT_ADDRESS (address); > > +#ifdef DROP_TEXT_NAME_PREFIX_CHAR > + if ((ms_type == mst_text || ms_type == mst_file_text) > + && name[0] == DROP_TEXT_NAME_PREFIX_CHAR) > + ++name; > +#endif /* DROP_TEXT_NAME_PREFIX_CHAR */ > + > > > can you explain why this is needed? Do we really have names starting > with '.', using gcc? This is a peculiarity of the PPC64 ABI, also related to the OPD macros. Global functions have two symbols: 'foo' and '.foo'. One of them is an address and the other is a descriptor with the function's gp value, IIRC. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer