ld testsuite fixes for alpha

Message ID 20200619024859.GB21885@bubble.grove.modra.org
State New
Headers show
Series
  • ld testsuite fixes for alpha
Related show

Commit Message

David Faust via Binutils June 19, 2020, 2:48 a.m.
Some tests failed just due to st_other info, eg. [NOPV], being
emitted by readelf or objdump.  Fix that.  Also since alpha doesn't
support ifunc, don't run the ifunc tests for alpha.

	* testsuite/ld-elf/dynamic-1.rd: Accept st_other notations.
	* testsuite/ld-elf/rdynamic-1.rd: Likewise.
	* testsuite/ld-elf/pr9676.rd: Likewise.
	* testsuite/ld-elf/pr9679.rd: Likewise.
	* testsuite/ld-elfvers/vers30.dsym: Likewise.
	* testsuite/ld-elfvers/vers31.dsym: Likewise.
	* testsuite/ld-plugin/pr22983.3.d: Likewise.
	* testsuite/ld-ifunc/ifunc.exp: Exclude alpha.


-- 
Alan Modra
Australia Development Lab, IBM

Comments

David Faust via Binutils June 19, 2020, 3:30 a.m. | #1
I missed some.

	* testsuite/ld-plugin/pr22983.1.d: Accept st_other notations.
	* testsuite/ld-plugin/pr22983.2.d: Likewise.
	* testsuite/ld-plugin/pr22983.4.d: Likewise.

diff --git a/ld/testsuite/ld-plugin/pr22983.1.d b/ld/testsuite/ld-plugin/pr22983.1.d
index 1ab19f8145..a351e8848f 100644
--- a/ld/testsuite/ld-plugin/pr22983.1.d
+++ b/ld/testsuite/ld-plugin/pr22983.1.d
@@ -1,6 +1,6 @@
 Symbol table '\.dynsym' contains [0-9]+ entries:
  +Num: +Value +Size Type +Bind +Vis +Ndx Name
 #...
- +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +OBJECT +GLOBAL +DEFAULT +[0-9]+ +_?var_attr_used_enabled
+ +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +OBJECT +GLOBAL +DEFAULT .*[0-9]+ _?var_attr_used_enabled
 #pass
 
diff --git a/ld/testsuite/ld-plugin/pr22983.2.d b/ld/testsuite/ld-plugin/pr22983.2.d
index 0f1e6c88e6..10589169b8 100644
--- a/ld/testsuite/ld-plugin/pr22983.2.d
+++ b/ld/testsuite/ld-plugin/pr22983.2.d
@@ -1,6 +1,6 @@
 Symbol table '\.dynsym' contains [0-9]+ entries:
  +Num: +Value +Size Type +Bind +Vis +Ndx Name
 #...
- +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +OBJECT +GLOBAL +DEFAULT +[0-9]+ +_?var_attr_used_disabled
+ +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +OBJECT +GLOBAL +DEFAULT .*[0-9]+ _?var_attr_used_disabled
 #pass
 
diff --git a/ld/testsuite/ld-plugin/pr22983.4.d b/ld/testsuite/ld-plugin/pr22983.4.d
index 655f824db7..6dade05740 100644
--- a/ld/testsuite/ld-plugin/pr22983.4.d
+++ b/ld/testsuite/ld-plugin/pr22983.4.d
@@ -1,5 +1,5 @@
 Symbol table '\.dynsym' contains [0-9]+ entries:
  +Num: +Value +Size Type +Bind +Vis +Ndx Name
 #...
- +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +GLOBAL +DEFAULT +[0-9]+ +_?func_attr_used_disabled
+ +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +GLOBAL +DEFAULT .*[0-9]+ _?func_attr_used_disabled
 #pass

-- 
Alan Modra
Australia Development Lab, IBM

Patch

diff --git a/ld/testsuite/ld-elf/dynamic-1.rd b/ld/testsuite/ld-elf/dynamic-1.rd
index 2c2f23b06a..4dafd15a3f 100644
--- a/ld/testsuite/ld-elf/dynamic-1.rd
+++ b/ld/testsuite/ld-elf/dynamic-1.rd
@@ -1,5 +1,5 @@ 
 Symbol table '\.dynsym' contains [0-9]+ entries:
  +Num: +Value +Size Type +Bind +Vis +Ndx Name
 #...
- +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +GLOBAL +DEFAULT +[0-9]+ +_?dynamic
+ +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +GLOBAL +DEFAULT .*[0-9]+ _?dynamic
 #...
diff --git a/ld/testsuite/ld-elf/pr9676.rd b/ld/testsuite/ld-elf/pr9676.rd
index 2d832dbe1e..f97e088cd0 100644
--- a/ld/testsuite/ld-elf/pr9676.rd
+++ b/ld/testsuite/ld-elf/pr9676.rd
@@ -1,5 +1,5 @@ 
 Symbol table '\.dynsym' contains [0-9]+ entries:
  +Num: +Value +Size Type +Bind +Vis +Ndx Name
 #...
- +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +LOCAL +DEFAULT +[0-9]+ +_?foo
+ +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +LOCAL +DEFAULT .*[0-9]+ _?foo
 #...
diff --git a/ld/testsuite/ld-elf/pr9679.rd b/ld/testsuite/ld-elf/pr9679.rd
index 2d832dbe1e..f97e088cd0 100644
--- a/ld/testsuite/ld-elf/pr9679.rd
+++ b/ld/testsuite/ld-elf/pr9679.rd
@@ -1,5 +1,5 @@ 
 Symbol table '\.dynsym' contains [0-9]+ entries:
  +Num: +Value +Size Type +Bind +Vis +Ndx Name
 #...
- +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +LOCAL +DEFAULT +[0-9]+ +_?foo
+ +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +LOCAL +DEFAULT .*[0-9]+ _?foo
 #...
diff --git a/ld/testsuite/ld-elf/rdynamic-1.rd b/ld/testsuite/ld-elf/rdynamic-1.rd
index dbf36021d1..1daf3b2eb1 100644
--- a/ld/testsuite/ld-elf/rdynamic-1.rd
+++ b/ld/testsuite/ld-elf/rdynamic-1.rd
@@ -1,5 +1,5 @@ 
 Symbol table '\.dynsym' contains [0-9]+ entries:
  +Num: +Value +Size Type +Bind +Vis +Ndx Name
 #...
- +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +GLOBAL +DEFAULT +[0-9]+ +_?rdynamic
+ +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +GLOBAL +DEFAULT .*[0-9]+ _?rdynamic
 #...
diff --git a/ld/testsuite/ld-elfvers/vers30.dsym b/ld/testsuite/ld-elfvers/vers30.dsym
index 5762f01843..d80d7f3393 100644
--- a/ld/testsuite/ld-elfvers/vers30.dsym
+++ b/ld/testsuite/ld-elfvers/vers30.dsym
@@ -1,5 +1,5 @@ 
 0+ g    DO \*ABS\*	0+  VERS_30\.0   VERS_30\.0
-[0-9a-f]+ g    DF (\.text|\.opd|\*ABS\*)	[0-9a-f]+  VERS_30\.0   _?global
-[0-9a-f]+ g    DF (\.text|\.opd|\*ABS\*)	[0-9a-f]+  VERS_30\.0   _?foo
-[0-9a-f]+ g    DF (\.text|\.opd|\*ABS\*)	[0-9a-f]+  VERS_30\.0   _?info
-[0-9a-f]+ g    DF (\.text|\.opd|\*ABS\*)	[0-9a-f]+  VERS_30\.0   _?extern
+[0-9a-f]+ g    DF (\.text|\.opd|\*ABS\*)	[0-9a-f]+  VERS_30\.0 .* _?global
+[0-9a-f]+ g    DF (\.text|\.opd|\*ABS\*)	[0-9a-f]+  VERS_30\.0 .* _?foo
+[0-9a-f]+ g    DF (\.text|\.opd|\*ABS\*)	[0-9a-f]+  VERS_30\.0 .* _?info
+[0-9a-f]+ g    DF (\.text|\.opd|\*ABS\*)	[0-9a-f]+  VERS_30\.0 .* _?extern
diff --git a/ld/testsuite/ld-elfvers/vers31.dsym b/ld/testsuite/ld-elfvers/vers31.dsym
index fb22f5b87c..b9ab2d104d 100644
--- a/ld/testsuite/ld-elfvers/vers31.dsym
+++ b/ld/testsuite/ld-elfvers/vers31.dsym
@@ -1,2 +1,2 @@ 
 0+ g +DO \*ABS\*	0+ +VERS_31\.0 +VERS_31\.0
-[0-9a-f]+ g +DF (\.text|\.opd|\*ABS\*)	[0-9a-f]+ +VERS_31\.0 +_?_Z1fIA3_icEvPT_T0
+[0-9a-f]+ g +DF (\.text|\.opd|\*ABS\*)	[0-9a-f]+ +VERS_31\.0 .* _?_Z1fIA3_icEvPT_T0
diff --git a/ld/testsuite/ld-ifunc/ifunc.exp b/ld/testsuite/ld-ifunc/ifunc.exp
index ce3434b30f..08cc87875c 100644
--- a/ld/testsuite/ld-ifunc/ifunc.exp
+++ b/ld/testsuite/ld-ifunc/ifunc.exp
@@ -24,6 +24,7 @@ 
 
 
 if { ![is_elf_format] || ![supports_gnu_osabi]
+     || [istarget alpha-*-*]
      || [istarget arc*-*-*]
      || [istarget am33*-*-*]
      || [istarget bfin-*-*]
diff --git a/ld/testsuite/ld-plugin/pr22983.3.d b/ld/testsuite/ld-plugin/pr22983.3.d
index 1bb4f2a4f2..396a317eb2 100644
--- a/ld/testsuite/ld-plugin/pr22983.3.d
+++ b/ld/testsuite/ld-plugin/pr22983.3.d
@@ -1,6 +1,5 @@ 
 Symbol table '\.dynsym' contains [0-9]+ entries:
  +Num: +Value +Size Type +Bind +Vis +Ndx Name
 #...
- +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +GLOBAL +DEFAULT +[0-9]+ +_?func_attr_used_enabled
+ +[0-9]+: +[0-9a-f]+ +[0-9a-f]+ +FUNC +GLOBAL +DEFAULT .*[0-9]+ _?func_attr_used_enabled
 #pass
-