From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32024 invoked by alias); 5 Feb 2008 19:32:09 -0000 Received: (qmail 32012 invoked by uid 22791); 5 Feb 2008 19:32:08 -0000 X-Spam-Check-By: sourceware.org Received: from fk-out-0910.google.com (HELO fk-out-0910.google.com) (209.85.128.185) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 05 Feb 2008 19:31:51 +0000 Received: by fk-out-0910.google.com with SMTP id 26so2773943fkx.8 for ; Tue, 05 Feb 2008 11:31:49 -0800 (PST) Received: by 10.82.152.16 with SMTP id z16mr16124389bud.17.1202239908461; Tue, 05 Feb 2008 11:31:48 -0800 (PST) Received: by 10.82.165.12 with HTTP; Tue, 5 Feb 2008 11:31:48 -0800 (PST) Message-ID: <8f2776cb0802051131s2d8e866cu3c06984a4dba9743@mail.gmail.com> Date: Tue, 05 Feb 2008 19:32:00 -0000 From: "Jim Blandy" To: rahul_dev_agg@yahoo.co.in Subject: Re: elf core file format for powerpc Cc: gdb@sourceware.org In-Reply-To: <739828.73007.qm@web94612.mail.in2.yahoo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20080205133047.GA11692@caradoc.them.org> <739828.73007.qm@web94612.mail.in2.yahoo.com> X-Google-Sender-Auth: fedf1c87179a76c9 X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2008-02/txt/msg00030.txt.bz2 On Feb 5, 2008 5:42 AM, rahul dev wrote: > Can you please provide some information on the note section and how to > add register values in the note section. I searched a lot on the net > but failed to get any useful information. One source of confusion is that the code in GDB that operates on BFD sections is actually accessing ELF notes, in a PT_NOTE program header. When BFD opens a core file and sees a PT_NOTE program header, it turns each note into a "section" with a known name. See bfd/elfcore.h:elf_core_file_p, and uses of _bfd_elfcore_make_pseudosection. So if you want to produce .reg "sections" that GDB can see, you need to produce PT_NOTE program headers in your core that BFD will recognize.