This is the mail archive of the
mailing list for the binutils project.
Re: [arm] EABI annotation of thumb symbols.
- From: Richard Earnshaw <rearnsha at arm dot com>
- To: Paul Brook <paul at codesourcery dot com>
- Cc: binutils at sources dot redhat dot com
- Date: Tue, 02 Nov 2004 14:41:10 +0000
- Subject: Re: [arm] EABI annotation of thumb symbols.
- References: <firstname.lastname@example.org>
On Tue, 2004-11-02 at 14:22, Paul Brook wrote:
> The current Arm abi identifies thumb function symbols by giving them type
> The Arm EABI specifies that thumb function symbols should be identified by
> setting the least significant bit of the address, and type STT_FUNC.
> The patch below implements this. The main complication is that objdump -d
> breaks. I added a new bfd function to get the real address of a symbol. This
> seemed preferable to trying to mangle symbols while reading them in.
> I'm open to alternative suggestions if people think this is the wrong way to
> implement this.
Another alternative, which might be less invasive on other parts of the
tools is to have the ARM symbol slurp and write code translate the ABI
v4 format into the STT_ARM_TFUNC internally when the symbol table is
read and vice versa when it is written.
Then the internal value of the symbol would always be the correct
'address' rather than the mangled address.
Put another way, the LSB being set on the symbol in the object file is
just a different way of encoding the STT_ARM_TFUNC feature.