aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite/ld-arm
diff options
context:
space:
mode:
authorDaniel Jacobowitz <drow@false.org>2009-12-09 21:42:00 +0000
committerDaniel Jacobowitz <drow@false.org>2009-12-09 21:42:00 +0000
commita747059210fbec5946a62431e8774190059d901d (patch)
treea29b7eed365990c34238b3e8bfbcd93979096453 /ld/testsuite/ld-arm
parent2f2de2488974549562ff0ebc3676daa78eb28d0f (diff)
downloadgdb-a747059210fbec5946a62431e8774190059d901d.zip
gdb-a747059210fbec5946a62431e8774190059d901d.tar.gz
gdb-a747059210fbec5946a62431e8774190059d901d.tar.bz2
bfd/
* elf32-arm.c (elf32_arm_next_input_section): Skip sections without SEC_CODE. ld/testsuite/ * ld-arm/arm-elf.exp (armeabitests): Add farcall-data. * ld-arm/farcall-data.d, ld-arm/farcall-data.s: New. * lib/ld-lib.exp (run_ld_link_tests, run_cc_link_tests): Correct regular expression for archives.
Diffstat (limited to 'ld/testsuite/ld-arm')
-rw-r--r--ld/testsuite/ld-arm/arm-elf.exp3
-rw-r--r--ld/testsuite/ld-arm/farcall-data.d19
-rw-r--r--ld/testsuite/ld-arm/farcall-data.s14
3 files changed, 36 insertions, 0 deletions
diff --git a/ld/testsuite/ld-arm/arm-elf.exp b/ld/testsuite/ld-arm/arm-elf.exp
index 8fbf8df..2372844 100644
--- a/ld/testsuite/ld-arm/arm-elf.exp
+++ b/ld/testsuite/ld-arm/arm-elf.exp
@@ -422,6 +422,9 @@ set armeabitests {
{{objdump -fdw farcall-mixed-lib.d}}
"farcall-mixed-lib.so"}
+ {"Long branch with mixed text and data" "-T arm.ld" "" {farcall-data.s}
+ {{objdump -dr farcall-data.d}}
+ "farcall-data"}
}
run_ld_link_tests $armeabitests
diff --git a/ld/testsuite/ld-arm/farcall-data.d b/ld/testsuite/ld-arm/farcall-data.d
new file mode 100644
index 0000000..a8b231c
--- /dev/null
+++ b/ld/testsuite/ld-arm/farcall-data.d
@@ -0,0 +1,19 @@
+.*: file format .*
+
+Disassembly of section .text:
+
+00008000 <_start>:
+ 8000: ea000000 b 8008 <__far_veneer>
+ 8004: 00000000 andeq r0, r0, r0
+
+00008008 <__far_veneer>:
+ 8008: e51ff004 ldr pc, \[pc, #-4\] ; 800c <__far_veneer\+0x4>
+ 800c: 12340000 \.word 0x12340000
+
+00008010 <after>:
+ 8010: 11111111 \.word 0x11111111
+
+Disassembly of section \.far:
+
+12340000 <far>:
+12340000: e12fff1e bx lr
diff --git a/ld/testsuite/ld-arm/farcall-data.s b/ld/testsuite/ld-arm/farcall-data.s
new file mode 100644
index 0000000..ed66199
--- /dev/null
+++ b/ld/testsuite/ld-arm/farcall-data.s
@@ -0,0 +1,14 @@
+ .syntax unified
+ .text
+ .global _start
+ .type _start, %function
+_start:
+ b far
+
+.section .after
+after:
+ .word 0x11111111
+
+ .section .far, "ax"
+ .type far, %function
+far: bx lr