Re: Add some expected failures for bfin linker tests

After commit 7ade0f1582 I was seeing bfin-elf +XPASS: weak symbols,
and on looking into the bfin targets a little, discovered we have two
bfin-linux targets.  One, bfin-uclinux, is like bfin-elf in that
ld -m elf32bfin is the default, and the other, bfin-linux-uclibc where
ld -m elf32bfinfd is the default.  So putting bfin-*-*linux* in test
xfails or elsewhere is wrong.  We want bfin-*-linux* instead to just
select the fdpic bfin target.

This patch corrects wrong bfin target triples in the ld testsuite,
not just the recent change but others I'd added to xfails too.
It also fixes the bfin-linux-uclibc ld-elf/64ksec fail
This commit is contained in:
Alan Modra 2023-06-15 11:45:03 +09:30
parent 6a28a3c200
commit 0749c73cf8
16 changed files with 19 additions and 17 deletions

View File

@ -1,6 +1,6 @@
#source: comm-data5.s
#ld:
#readelf: -r
#xfail: bfin-*-*linux* frv-*-*linux* lm32-*-linux*
#xfail: bfin-*-linux* frv-*-*linux* lm32-*-linux*
There are no relocations in this file.

View File

@ -3,7 +3,7 @@
#source: pr23591c.s
#ld: -e _start
#readelf: -sW
#xfail: bfin-*-*linux* frv-*-linux* lm32-*-linux*
#xfail: bfin-*-linux* frv-*-linux* lm32-*-linux*
# bfin, frv, and lm32 fail with complaints about emitting dynamic
# relocations in read-only sections.

View File

@ -1,6 +1,6 @@
#ld: --gc-sections -T pr23648.t
#target: [check_gc_sections_available]
#xfail: bfin-*-*linux* frv-*-linux* lm32-*-linux*
#xfail: bfin-*-linux* frv-*-linux* lm32-*-linux*
#nm: -B
#failif

View File

@ -170,12 +170,13 @@ if [catch { set ofd [open "tmpdir/$test2.d" w] } x] {
# too big for avr, d10v and msp
# lack of fancy orphan section handling causes overlap on fr30 and iq2000
# lm32 complains about relocations in read-only sections
# bfin and lm32 complain about relocations in read-only sections
if { ![istarget "d10v-*-*"]
&& ![istarget "avr-*-*"]
&& ![istarget "msp*-*-*"]
&& ![istarget "fr30-*-*"]
&& ![istarget "iq2000-*-*"]
&& ![istarget "bfin-*-linux*"]
&& ![istarget "lm32-*-linux*"]
&& ![istarget "pru-*-*"] } {
foreach sfile $sfiles { puts $ofd "#source: $sfile" }

View File

@ -2,7 +2,7 @@
#source: pr19167b.s
#ld: --gc-sections -e _start
#objdump: -s -j _foo
#xfail: bfin-*-*linux* frv-*-*linux* lm32-*-*linux*
#xfail: bfin-*-linux* frv-*-*linux* lm32-*-*linux*
#...
Contents of section _foo:

View File

@ -1,7 +1,7 @@
#name: --gc-sections with __start_
#ld: --gc-sections -e _start
#nm: -n
#xfail: bfin-*-*linux* frv-*-*linux* lm32-*-*linux*
#xfail: bfin-*-linux* frv-*-*linux* lm32-*-*linux*
#...
[0-9a-f]+ D +_?__start__foo

View File

@ -2,7 +2,7 @@
#ld: --gc-sections -e _start -z start-stop-gc
#nm: -n
#notarget: [uses_genelf]
#xfail: bfin-*-*linux* frv-*-*linux*
#xfail: bfin-*-linux* frv-*-*linux*
#failif
#...

View File

@ -2,7 +2,7 @@
#ld: --gc-sections -e _start
#nm: -n
#notarget: [is_generic]
#xfail: bfin-*-*linux* frv-*-*linux* lm32-*-*linux*
#xfail: bfin-*-linux* frv-*-*linux* lm32-*-*linux*
#...
[0-9a-f]+ T +bar

View File

@ -2,7 +2,7 @@
#ld: --gc-sections -e _start
#nm: -n
#target: [supports_gnu_unique]
#xfail: bfin-*-*linux* frv-*-*linux* lm32-*-*linux*
#xfail: bfin-*-linux* frv-*-*linux* lm32-*-*linux*
#...
[0-9a-f]+ R +bar_xx

View File

@ -1,7 +1,7 @@
#ld: -e 0 --defsym foo=1 tmpdir/start.o tmpdir/libfoo.a
#nm: -B
#source: dummy.s
#xfail: bfin-*-*linux* frv-*-linux*
#xfail: bfin-*-linux* frv-*-linux*
# Check that --defsym works on archive.
#failif

View File

@ -1,6 +1,6 @@
#ld: -T empty-address-1.t
#nm: -n
#xfail: bfin-*-*linux* frv-*-*linux*
#xfail: bfin-*-linux* frv-*-*linux*
#...
0+0 [AT] _start
#...

View File

@ -1,7 +1,7 @@
#source: empty-address-2.s
#ld: -Ttext 0x0000000 -Tdata 0x200 -T empty-address-2a.t
#nm: -n
#xfail: bfin-*-*linux* frv-*-*linux* riscv64*-*-* tic54x-*-*
#xfail: bfin-*-linux* frv-*-*linux* riscv64*-*-* tic54x-*-*
#...
0+0 T _start
#...

View File

@ -1,7 +1,7 @@
#source: empty-address-2.s
#ld: -Ttext 0x0000000 -Tdata 0x200 -T empty-address-2b.t
#nm: -n
#xfail: bfin-*-*linux* frv-*-*linux* riscv64*-*-* tic54x-*-*
#xfail: bfin-*-linux* frv-*-*linux* riscv64*-*-* tic54x-*-*
#...
0+0 T _start
#...

View File

@ -1,7 +1,7 @@
#ld: -T pr14962-2.t
#source: pr14962a.s
#nm: -n
#xfail: bfin-*-*linux* frv-*-*linux*
#xfail: bfin-*-linux* frv-*-*linux*
#...
0+2000 [AT] _start

View File

@ -5,8 +5,8 @@
#xfail: mmix-knuth-mmixware
# The reference to x would normally generate a cross-reference error
# but the linker script converts x to absolute to avoid the error.
#xfail: bfin-*-*linux*
# The bfin backend complains about attempting to put a fixup into a read-only section.
#xfail: bfin-*-linux*
# The bfinfd backend complains about fixups in read-only sections.
#...
0+2000 A x

View File

@ -26,7 +26,8 @@ set testname "weak symbols"
if { [is_elf_format] } {
# hppa64 is incredibly broken
setup_xfail hppa64-*-*
setup_xfail bfin-*-*
# elf32bfinfd target complains about fixups in read-only sections
setup_xfail bfin-*-linux*
} elseif { [is_pecoff_format] } {
# Weak symbols are broken for most PE targets.
if { ![istarget aarch64-*-*]