From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27810 invoked by alias); 21 Aug 2002 22:58:00 -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 27799 invoked from network); 21 Aug 2002 22:57:59 -0000 Received: from unknown (HELO localhost.redhat.com) (66.30.197.194) by sources.redhat.com with SMTP; 21 Aug 2002 22:57:59 -0000 Received: by localhost.redhat.com (Postfix, from userid 469) id 7B5F610DCC; Wed, 21 Aug 2002 18:56:06 -0400 (EDT) From: Elena Zannoni MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15716.6790.251258.282269@localhost.redhat.com> Date: Wed, 21 Aug 2002 15:58:00 -0000 To: Kevin Buettner Cc: Elena Zannoni , gdb-patches@sources.redhat.com Subject: Re: [RFA] rs6000-tdep.c: figure out e500 machine from bfd. In-Reply-To: <1020820233145.ZM15650@localhost.localdomain> References: <15714.50288.526139.379896@localhost.redhat.com> <1020820233145.ZM15650@localhost.localdomain> X-SW-Source: 2002-08/txt/msg00673.txt.bz2 Kevin Buettner writes: > On Aug 20, 6:36pm, Elena Zannoni wrote: > > > + /* For e500 executables, the apuinfo section is of help here. */ > > + if (info.abfd) > > + { > > + sect = bfd_get_section_by_name (info.abfd, ".PPC.EMB.apuinfo"); > > + if (sect) > > What is the apuinfo section? If you know what it's about (I sure > don't), consider expanding the comment somewhat. > Yes, sorry (I have been playing around with this code for too long, obviously). It is a section that contains the version numbers of the various Application Processing Units that the processor contains. So that one can detect what version/type of processor you need to run the code on. For instance if the APU info says you need version 3 you know that the code won't run on version 2. Because there may be new instructions, etc. I think this info could in theory be used by the linker, but I am not sure it is used right now. Gas keeps track of the rev number associated with each instruction, and then outputs (in the apuinfo section) the highest it has found. Right now, though, it doesn't do that. It just spews out a 1. > Is there any chance that this section could appear in non-e500 > executables? If so, make a note of this gotcha in the comment too. > No. Only e500. > Otherwise, fine. Go ahead and commit it after expanding the comment > as necessary. > OK. Done. > Kevin