ARM stub sizing fix
Alan Modra
amodra@gmail.com
Fri Feb 5 05:32:00 GMT 2010
On Thu, Feb 04, 2010 at 04:26:38PM +0000, Matthew Gretton-Dann wrote:
> tmpdir/farcall-mixed-app.o: In function `app_tfunc':
> (.far_thumb+0x2): relocation truncated to fit: R_ARM_THM_CALL against symbol `lib_func2' defined in .plt section in tmpdir/mixed-lib.so
>
> This seems to be because after applying the patch the call to
> elf32_arm_get_stub_entry() at about line 7510 of elf32-arm.c returns
> NULL for this relocation. Before the patch was applied it returned
> non-NULL.
This is because the arm_type_of_stub call in elf32_arm_size_stubs
returns arm_stub_long_branch_v4t_thumb_arm but when called in
elf32_arm_final_link_relocate you get
arm_stub_long_branch_v4t_thumb_thumb. st_type differs in the two
calls. I think the changes to sym_flags for plt calls in
elf32_arm_final_link_relocate should be moved into arm_type_of_stub,
but I don't understand the arm back end well enough to fix this
without spending quite some time on it. I don't have the time to
continue with this patch. Sorry.
--
Alan Modra
Australia Development Lab, IBM
More information about the Binutils
mailing list