From: Richard Earnshaw <rearnsha@gcc.gnu.org>
To: Julian Brown <julian@codesourcery.com>
Cc: binutils@sources.redhat.com
Subject: Re: [PATCH] Fix type and alignment of ARM/Thumb EABI mapping symbols
Date: Wed, 30 Mar 2005 17:05:00 -0000 [thread overview]
Message-ID: <1112175967.12337.36.camel@pc960.cambridge.arm.com> (raw)
In-Reply-To: <4249C7E9.8000100@codesourcery.com>
On Tue, 2005-03-29 at 22:26, Julian Brown wrote:
> OK, this is a simpler version of the patch which alters the expected
> test output instead (only ARM-specific code is now touched).
>
> Tested with cross to arm-none-eabi and arm-none-symbianelf, and with all
> targets on i686-pc-linux-gnu. OK to apply?
>
> ChangeLog:
>
> * bfd/elf32-arm.c (arm_elf_find_function): Include STT_NOTYPE in test
> for mapping symbols.
> * gas/config/tc-arm.c (mapping_state): Update documentation in
> function comment. Change type of mapping symbols to BSF_NO_TYPE.
> (is_arm_mapping_symbol_name): New function.
> (arm_adjust_symtab): Don't change type of mapping symbols here.
> * gas/testsuite/gas/arm/mapping.d: Update expected output.
> * ld/testsuite/ld-arm/arm-app-abs32.d: Likewise.
> * ld/testsuite/ld-arm/arm-app.d: Likewise.
> * ld/testsuite/ld-arm/mixed-app.d: Likewise.
>
> ______________________________________________________________________
> Index: gas/config/tc-arm.c
> ===================================================================
> RCS file: /cvs/src/src/gas/config/tc-arm.c,v
> retrieving revision 1.199
> diff -c -p -r1.199 tc-arm.c
> *** gas/config/tc-arm.c 29 Mar 2005 16:54:21 -0000 1.199
> --- gas/config/tc-arm.c 29 Mar 2005 21:13:47 -0000
> *************** validate_offset_imm (unsigned int val, i
> *** 1243,1316 ****
> --- 1243,1308 ----
> \f
> #ifdef OBJ_ELF
> /* This code is to handle mapping symbols as defined in the ARM ELF spec.
> ! (This text is taken from version 0.62 RC 2 of the spec):
>
> ! 4.5.7 Mapping symbols
>
> ! A section of an ELF file can contain a mixture of ARM code, Thumb code
There's no need to quote the entirety of this section in the source
file. A cross reference is fine. The correct reference should be to
v1.0 of the spec, where the section number is 4.5.5.
> *************** arm_frob_label (symbolS * sym)
> *** 13678,13683 ****
> --- 13670,13685 ----
> }
> }
>
> + /* Recognize short-form or long-form mapping symbol names. */
> +
> + static bfd_boolean
> + is_arm_mapping_symbol_name (const char* name)
> + {
> + return name && name[0] == '$'
> + && (name[1] == 'a' || name[1] == 'd' || name[1] == 't')
> + && (name[2] == '\0' || name[2] == '.');
> + }
> +
> /* Adjust the symbol table. This marks Thumb symbols as distinct from
> ARM ones. */
>
It seems silly to duplicate this function here when it also exists in
libbfd (though also static). It would make more sense to make the bfd
implementation public and call that. I would suggest you move the code
to cpu-arm.c.
This is ok with the above changes.
R.
next prev parent reply other threads:[~2005-03-30 9:46 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-28 8:41 Julian Brown
2005-03-28 10:17 ` Daniel Jacobowitz
2005-03-28 10:36 ` Julian Brown
2005-03-29 16:54 ` Richard Earnshaw
2005-03-29 17:25 ` Daniel Jacobowitz
2005-03-30 15:31 ` Julian Brown
2005-03-30 17:05 ` Richard Earnshaw [this message]
2005-03-30 21:08 ` Paul Brook
2005-03-30 21:11 ` Julian Brown
2005-03-31 0:27 ` Richard Earnshaw
2005-03-31 0:34 ` Julian Brown
2005-03-31 0:58 ` Richard Earnshaw
2005-03-31 2:17 ` Julian Brown
2005-03-31 15:25 ` Richard Earnshaw
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1112175967.12337.36.camel@pc960.cambridge.arm.com \
--to=rearnsha@gcc.gnu.org \
--cc=binutils@sources.redhat.com \
--cc=julian@codesourcery.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).