aboutsummaryrefslogtreecommitdiff
path: root/ld
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2007-06-30 00:03:40 +0000
committerJoseph Myers <joseph@codesourcery.com>2007-06-30 00:03:40 +0000
commit34c8bcbae2e6ea0752c1ebe6e1282cc74a821957 (patch)
tree0681992a1200b9024ba536d903485f4157840067 /ld
parent89ebe6973393e6e0721c0c131c4abf2661fbe56c (diff)
downloadgdb-34c8bcbae2e6ea0752c1ebe6e1282cc74a821957.zip
gdb-34c8bcbae2e6ea0752c1ebe6e1282cc74a821957.tar.gz
gdb-34c8bcbae2e6ea0752c1ebe6e1282cc74a821957.tar.bz2
bfd:
* elf32-ppc.c (ppc_elf_merge_obj_attributes): New. (ppc_elf_merge_private_bfd_data): Call it. binutils: * readelf.c (display_power_gnu_attribute, process_power_specific): New. (process_arch_specific): Call process_power_specific. include/elf: * ppc.h (Tag_GNU_Power_ABI_FP): Define. ld/testsuite: * ld-powerpc/attr-gnu-4-0.s, ld-powerpc/attr-gnu-4-00.d, ld-powerpc/attr-gnu-4-01.d, ld-powerpc/attr-gnu-4-02.d, ld-powerpc/attr-gnu-4-1.s, ld-powerpc/attr-gnu-4-10.d, ld-powerpc/attr-gnu-4-11.d, ld-powerpc/attr-gnu-4-12.d, ld-powerpc/attr-gnu-4-13.d, ld-powerpc/attr-gnu-4-2.s, ld-powerpc/attr-gnu-4-20.d, ld-powerpc/attr-gnu-4-21.d, ld-powerpc/attr-gnu-4-22.d, ld-powerpc/attr-gnu-4-3.s, ld-powerpc/attr-gnu-4-31.d: New. * ld-powerpc/powerpc.exp: Run these new tests.
Diffstat (limited to 'ld')
-rw-r--r--ld/testsuite/ChangeLog12
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-0.s1
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-00.d7
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-01.d10
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-02.d10
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-1.s1
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-10.d10
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-11.d10
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-12.d6
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-13.d6
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-2.s1
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-20.d10
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-21.d6
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-22.d10
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-3.s1
-rw-r--r--ld/testsuite/ld-powerpc/attr-gnu-4-31.d6
-rw-r--r--ld/testsuite/ld-powerpc/powerpc.exp12
17 files changed, 119 insertions, 0 deletions
diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog
index 5271fcf..28099e9 100644
--- a/ld/testsuite/ChangeLog
+++ b/ld/testsuite/ChangeLog
@@ -1,5 +1,17 @@
2007-06-29 Joseph Myers <joseph@codesourcery.com>
+ * ld-powerpc/attr-gnu-4-0.s, ld-powerpc/attr-gnu-4-00.d,
+ ld-powerpc/attr-gnu-4-01.d, ld-powerpc/attr-gnu-4-02.d,
+ ld-powerpc/attr-gnu-4-1.s, ld-powerpc/attr-gnu-4-10.d,
+ ld-powerpc/attr-gnu-4-11.d, ld-powerpc/attr-gnu-4-12.d,
+ ld-powerpc/attr-gnu-4-13.d, ld-powerpc/attr-gnu-4-2.s,
+ ld-powerpc/attr-gnu-4-20.d, ld-powerpc/attr-gnu-4-21.d,
+ ld-powerpc/attr-gnu-4-22.d, ld-powerpc/attr-gnu-4-3.s,
+ ld-powerpc/attr-gnu-4-31.d: New.
+ * ld-powerpc/powerpc.exp: Run these new tests.
+
+2007-06-29 Joseph Myers <joseph@codesourcery.com>
+
* ld-mips-elf/attr-gnu-4-0.s, ld-mips-elf/attr-gnu-4-00.d,
ld-mips-elf/attr-gnu-4-01.d, ld-mips-elf/attr-gnu-4-02.d,
ld-mips-elf/attr-gnu-4-03.d, ld-mips-elf/attr-gnu-4-1.s,
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-0.s b/ld/testsuite/ld-powerpc/attr-gnu-4-0.s
new file mode 100644
index 0000000..a143746
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-0.s
@@ -0,0 +1 @@
+.gnu_attribute 4,0
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-00.d b/ld/testsuite/ld-powerpc/attr-gnu-4-00.d
new file mode 100644
index 0000000..a4751a1
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-00.d
@@ -0,0 +1,7 @@
+#source: attr-gnu-4-0.s
+#source: attr-gnu-4-0.s
+#as: -a32
+#ld: -r -melf32ppc
+#readelf: -A
+#target: powerpc*-*-*
+
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-01.d b/ld/testsuite/ld-powerpc/attr-gnu-4-01.d
new file mode 100644
index 0000000..212e0c4
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-01.d
@@ -0,0 +1,10 @@
+#source: attr-gnu-4-0.s
+#source: attr-gnu-4-1.s
+#as: -a32
+#ld: -r -melf32ppc
+#readelf: -A
+#target: powerpc*-*-*
+
+Attribute Section: gnu
+File Attributes
+ Tag_GNU_Power_ABI_FP: Hard float
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-02.d b/ld/testsuite/ld-powerpc/attr-gnu-4-02.d
new file mode 100644
index 0000000..9bd42b5
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-02.d
@@ -0,0 +1,10 @@
+#source: attr-gnu-4-0.s
+#source: attr-gnu-4-2.s
+#as: -a32
+#ld: -r -melf32ppc
+#readelf: -A
+#target: powerpc*-*-*
+
+Attribute Section: gnu
+File Attributes
+ Tag_GNU_Power_ABI_FP: Soft float
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-1.s b/ld/testsuite/ld-powerpc/attr-gnu-4-1.s
new file mode 100644
index 0000000..e985a56
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-1.s
@@ -0,0 +1 @@
+.gnu_attribute 4,1
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-10.d b/ld/testsuite/ld-powerpc/attr-gnu-4-10.d
new file mode 100644
index 0000000..93297c2
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-10.d
@@ -0,0 +1,10 @@
+#source: attr-gnu-4-1.s
+#source: attr-gnu-4-0.s
+#as: -a32
+#ld: -r -melf32ppc
+#readelf: -A
+#target: powerpc*-*-*
+
+Attribute Section: gnu
+File Attributes
+ Tag_GNU_Power_ABI_FP: Hard float
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-11.d b/ld/testsuite/ld-powerpc/attr-gnu-4-11.d
new file mode 100644
index 0000000..fb2b76e
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-11.d
@@ -0,0 +1,10 @@
+#source: attr-gnu-4-1.s
+#source: attr-gnu-4-1.s
+#as: -a32
+#ld: -r -melf32ppc
+#readelf: -A
+#target: powerpc*-*-*
+
+Attribute Section: gnu
+File Attributes
+ Tag_GNU_Power_ABI_FP: Hard float
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-12.d b/ld/testsuite/ld-powerpc/attr-gnu-4-12.d
new file mode 100644
index 0000000..b7ffba0
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-12.d
@@ -0,0 +1,6 @@
+#source: attr-gnu-4-1.s
+#source: attr-gnu-4-2.s
+#as: -a32
+#ld: -r -melf32ppc
+#warning: Warning: .* uses hard float, .* uses soft float
+#target: powerpc*-*-*
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-13.d b/ld/testsuite/ld-powerpc/attr-gnu-4-13.d
new file mode 100644
index 0000000..be1290e
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-13.d
@@ -0,0 +1,6 @@
+#source: attr-gnu-4-1.s
+#source: attr-gnu-4-3.s
+#as: -a32
+#ld: -r -melf32ppc
+#warning: Warning: .* uses unknown floating point ABI 3
+#target: powerpc*-*-*
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-2.s b/ld/testsuite/ld-powerpc/attr-gnu-4-2.s
new file mode 100644
index 0000000..54ebf4e
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-2.s
@@ -0,0 +1 @@
+.gnu_attribute 4,2
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-20.d b/ld/testsuite/ld-powerpc/attr-gnu-4-20.d
new file mode 100644
index 0000000..3d83893
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-20.d
@@ -0,0 +1,10 @@
+#source: attr-gnu-4-2.s
+#source: attr-gnu-4-0.s
+#as: -a32
+#ld: -r -melf32ppc
+#readelf: -A
+#target: powerpc*-*-*
+
+Attribute Section: gnu
+File Attributes
+ Tag_GNU_Power_ABI_FP: Soft float
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-21.d b/ld/testsuite/ld-powerpc/attr-gnu-4-21.d
new file mode 100644
index 0000000..b38f248
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-21.d
@@ -0,0 +1,6 @@
+#source: attr-gnu-4-2.s
+#source: attr-gnu-4-1.s
+#as: -a32
+#ld: -r -melf32ppc
+#warning: Warning: .* uses hard float, .* uses soft float
+#target: powerpc*-*-*
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-22.d b/ld/testsuite/ld-powerpc/attr-gnu-4-22.d
new file mode 100644
index 0000000..f6bd198
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-22.d
@@ -0,0 +1,10 @@
+#source: attr-gnu-4-2.s
+#source: attr-gnu-4-2.s
+#as: -a32
+#ld: -r -melf32ppc
+#readelf: -A
+#target: powerpc*-*-*
+
+Attribute Section: gnu
+File Attributes
+ Tag_GNU_Power_ABI_FP: Soft float
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-3.s b/ld/testsuite/ld-powerpc/attr-gnu-4-3.s
new file mode 100644
index 0000000..32e5f5d
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-3.s
@@ -0,0 +1 @@
+.gnu_attribute 4,3
diff --git a/ld/testsuite/ld-powerpc/attr-gnu-4-31.d b/ld/testsuite/ld-powerpc/attr-gnu-4-31.d
new file mode 100644
index 0000000..9cf8f4f
--- /dev/null
+++ b/ld/testsuite/ld-powerpc/attr-gnu-4-31.d
@@ -0,0 +1,6 @@
+#source: attr-gnu-4-3.s
+#source: attr-gnu-4-1.s
+#as: -a32
+#ld: -r -melf32ppc
+#warning: Warning: .* uses unknown floating point ABI 3
+#target: powerpc*-*-*
diff --git a/ld/testsuite/ld-powerpc/powerpc.exp b/ld/testsuite/ld-powerpc/powerpc.exp
index 927c4b8..ad224b0 100644
--- a/ld/testsuite/ld-powerpc/powerpc.exp
+++ b/ld/testsuite/ld-powerpc/powerpc.exp
@@ -147,3 +147,15 @@ if [ supports_ppc64 ] then {
}
run_dump_test "plt1"
+
+run_dump_test "attr-gnu-4-00"
+run_dump_test "attr-gnu-4-01"
+run_dump_test "attr-gnu-4-02"
+run_dump_test "attr-gnu-4-10"
+run_dump_test "attr-gnu-4-11"
+run_dump_test "attr-gnu-4-12"
+run_dump_test "attr-gnu-4-13"
+run_dump_test "attr-gnu-4-20"
+run_dump_test "attr-gnu-4-21"
+run_dump_test "attr-gnu-4-22"
+run_dump_test "attr-gnu-4-31"