aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf32-arm.c
diff options
context:
space:
mode:
authorPaul Brook <paul@codesourcery.com>2007-04-17 20:09:52 +0000
committerPaul Brook <paul@codesourcery.com>2007-04-17 20:09:52 +0000
commitfcb93ecfc25d0337944090414ed53da4dcdd6864 (patch)
treeb5c44efa1f04197add1b10c2520b78cfb190553f /bfd/elf32-arm.c
parent06f9a1af70ed2722e575203073271ae39c071def (diff)
downloadgdb-fcb93ecfc25d0337944090414ed53da4dcdd6864.zip
gdb-fcb93ecfc25d0337944090414ed53da4dcdd6864.tar.gz
gdb-fcb93ecfc25d0337944090414ed53da4dcdd6864.tar.bz2
2007-04-17 Paul Brook <paul@codesourcery.com>
bfd/ * elf.c (_bfd_elf_is_function_type): New function. * elflink.c (_bfd_elf_merge_symbol): Use bed->is_function_type. (_bfd_elf_dynamic_symbol_p, _bfd_elf_symbol_refs_local_p, is_global_data_symbol_definition, elf_link_add_object_symbols): Ditto. * elf-bfd.h (elf_backend_data): Add is_function_type. (_bfd_elf_is_function_type): Add prototype. * elfxx-target.h (elf_backend_is_function_type): Add default definition. (elfNN_bed): Add elf_backend_is_function_type. * elf32-arm.c (elf32_arm_is_function_type): New function. (elf_backend_is_function_type): Define. ld/testsuite/ * ld-arm/preempt-app.s: New test. * ld-arm/preempt-app.sym: New. * ld-arm/arm-elf.exp: Add preempt-app.
Diffstat (limited to 'bfd/elf32-arm.c')
-rw-r--r--bfd/elf32-arm.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/bfd/elf32-arm.c b/bfd/elf32-arm.c
index e8be0d5..10a6408 100644
--- a/bfd/elf32-arm.c
+++ b/bfd/elf32-arm.c
@@ -10557,6 +10557,13 @@ elf32_arm_additional_program_headers (bfd *abfd,
return 0;
}
+/* We have two function types: STT_FUNC and STT_ARM_TFUNC. */
+static bfd_boolean
+elf32_arm_is_function_type (unsigned int type)
+{
+ return (type == STT_FUNC) || (type == STT_ARM_TFUNC);
+}
+
/* We use this to override swap_symbol_in and swap_symbol_out. */
const struct elf_size_info elf32_arm_size_info = {
sizeof (Elf32_External_Ehdr),
@@ -10643,6 +10650,7 @@ const struct elf_size_info elf32_arm_size_info = {
elf32_arm_output_arch_local_syms
#define elf_backend_begin_write_processing \
elf32_arm_begin_write_processing
+#define elf_backend_is_function_type elf32_arm_is_function_type
#define elf_backend_can_refcount 1
#define elf_backend_can_gc_sections 1