mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-12-27 04:52:05 +08:00
c542398150
2014-08-21 Tony Wang <tony.wang@arm.com> * elf32-arm.c (elf32_arm_final_link_relocate): Implement the veneer routine for R_ARM_THM_JUMP19. (arm_type_of_stub): Add conditional clause for R_ARM_THM_JUMP19 (elf32_arm_size_stub): Ditto. ld/testsuite/ChangeLog 2014-08-21 Tony Wang <tony.wang@arm.com> * ld-arm/jump-reloc-veneers-cond.s: New test. * ld-arm/farcall-cond-thumb-arm.s: Ditto. * ld-arm/jump-reloc-veneers-cond-short.d: Expected output for target without a veneer generation. * ld-arm/jump-reloc-veneers-cond-long.d: Expected output for target with a veneer generation. * ld-arm/farcall-cond-thumb-arm.d: Expected output for inter working veneer generation. * ld-arm/arm-elf.exp: Add tests for conditional branch veneer.
28 lines
510 B
ArmAsm
28 lines
510 B
ArmAsm
@ Test to ensure that a Thumb to ARM call exceeding 4Mb generates a stub.
|
|
@ Check that we can generate two types of stub in the same section.
|
|
|
|
.global _start
|
|
.syntax unified
|
|
|
|
@ We will place the section .text at 0x1c01010.
|
|
|
|
.text
|
|
.thumb_func
|
|
_start:
|
|
.global bar
|
|
bne bar
|
|
@ This call is close enough to generate a "short branch" stub
|
|
@ or no stub if blx is available.
|
|
.space 0x050000
|
|
bne bar
|
|
|
|
@ We will place the section .foo at 0x2001014.
|
|
|
|
.section .foo, "xa"
|
|
|
|
.arm
|
|
.type bar, %function
|
|
bar:
|
|
bx lr
|
|
|