linux-mips
[Top] [All Lists]

Re: .reginfo and .mdebug section

To: Long Li <long21st@yahoo.com>
Subject: Re: .reginfo and .mdebug section
From: Ralf Baechle <ralf@linux-mips.org>
Date: Tue, 17 Dec 2002 14:39:59 +0100
Cc: linux-mips@linux-mips.org
In-reply-to: <20021217084303.20121.qmail@web40407.mail.yahoo.com>; from long21st@yahoo.com on Tue, Dec 17, 2002 at 12:43:03AM -0800
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <20021217084303.20121.qmail@web40407.mail.yahoo.com>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.2.5.1i
On Tue, Dec 17, 2002 at 12:43:03AM -0800, Long Li wrote:

> 1. I tried to compile some c code targetting mips4k,
> which is 32-bit ISA. However, the map file tells me
> that the compiled code are 64-bit, since the address
> are 64-bit.
> 
> 2. When I compiled the c code, I found in the mapfile
> that there are some sections called .reginfo and
> .mdebug. What are those sections? I would like to get
> rid of them. However, they still exists even if I
> deleted the '-g' option for gcc. Is there a way I can
> avoid the .reginfo and .mdebug sections?

.reginfo is MIPS ABI mandated brain damage described the register usage of
a given object or shared object.  I know of nothing that actually is using
these sections.  It's always just 24 bytes so not really worth alot of fuzz
though.  With some binutils versions you can remove this section with
objcopy --remove-section=.reginfo.  Some binutils version however will just
create a new .reginfo section during objcopy so with those this won't work.

.mdebug is the MIPS ABI mdebug stuff, debug information.  You should be
able to get rid of those with -g, at least my tools here don't create it
by default.

  Ralf

<Prev in Thread] Current Thread [Next in Thread>