aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite/ld-ia64/ia64.exp
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2003-01-16 21:31:18 +0000
committerJakub Jelinek <jakub@redhat.com>2003-01-16 21:31:18 +0000
commitb3dfd7fe24f18648d4cc8e044219a734c9a82fc1 (patch)
tree08c43a53da426285393a789b044d9e65577ab41b /ld/testsuite/ld-ia64/ia64.exp
parent837fd61c26f79a84459b9d12ad1e8838c048cd33 (diff)
downloadbinutils-b3dfd7fe24f18648d4cc8e044219a734c9a82fc1.zip
binutils-b3dfd7fe24f18648d4cc8e044219a734c9a82fc1.tar.gz
binutils-b3dfd7fe24f18648d4cc8e044219a734c9a82fc1.tar.bz2
* elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add
self_dtpmod_done and self_dtpmod_offset. (allocate_global_data_got): Only use one got entry for all dtpmod relocs against local symbols. (allocate_dynrel_entries): Only need .rela.got entry for dtpmod against global symbol. (elfNN_ia64_size_dynamic_sections): Initialize self_dtpmod_offset. Reserve space in .rela.got for the local dtpmod entry. (set_got_entry): Initialize the common local dtpmod .got entry. (elfNN_ia64_relocate_section): Handle R_IA_64_DTPREL64LSB and R_IA_64_DTPREL64MSB. * config/tc-ia64.c (ia64_cons_fix_new): Handle @dtprel() in data. * ld-ia64/ia64.exp: New. * ld-ia64/tlsbin.dd: New test. * ld-ia64/tlsbinpic.s: New test. * ld-ia64/tlsbin.rd: New test. * ld-ia64/tlsbin.s: New test. * ld-ia64/tlsbin.sd: New test. * ld-ia64/tlsbin.td: New test. * ld-ia64/tlsg.s: New test. * ld-ia64/tlsg.sd: New test. * ld-ia64/tlslib.s: New test. * ld-ia64/tlspic1.s: New test. * ld-ia64/tlspic2.s: New test. * ld-ia64/tlspic.dd: New test. * ld-ia64/tlspic.rd: New test. * ld-ia64/tlspic.sd: New test. * ld-ia64/tlspic.td: New test.
Diffstat (limited to 'ld/testsuite/ld-ia64/ia64.exp')
-rw-r--r--ld/testsuite/ld-ia64/ia64.exp54
1 files changed, 54 insertions, 0 deletions
diff --git a/ld/testsuite/ld-ia64/ia64.exp b/ld/testsuite/ld-ia64/ia64.exp
new file mode 100644
index 0000000..be96171
--- /dev/null
+++ b/ld/testsuite/ld-ia64/ia64.exp
@@ -0,0 +1,54 @@
+# Expect script for ld-ia64 tests
+# Copyright (C) 2002, 2003 Free Software Foundation
+#
+# This file is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+
+# Test ia64 linking; all types of relocs. This tests the assembler and
+# tools like objdump as well as the linker.
+
+if { !([istarget "ia64-*-elf*"]
+ || [istarget "ia64-*-linux*"]) } {
+ return
+}
+
+# List contains test-items with 3 items followed by 2 lists:
+# 0:name 1:ld options 2:assembler options
+# 3:filenames of assembler files 4: action and options. 5: name of output file
+
+# Actions:
+# objdump: Apply objdump options on result. Compare with regex (last arg).
+# nm: Apply nm options on result. Compare with regex (last arg).
+# readelf: Apply readelf options on result. Compare with regex (last arg).
+
+set ia64tests {
+ {"TLS -fpic -shared" "-shared -melf64_ia64"
+ "" {tlspic1.s tlspic2.s}
+ {{readelf -WSsrl tlspic.rd} {objdump -drj.text tlspic.dd}
+ {objdump -sj.got tlspic.sd} {objdump -sj.tdata tlspic.td}}
+ "libtlspic.so"}
+ {"Helper shared library" "-shared -melf64_ia64"
+ "" {tlslib.s} {} "libtlslib.so"}
+ {"TLS -fpic and -fno-pic exec"
+ "-melf64_ia64 tmpdir/libtlslib.so" "" {tlsbinpic.s tlsbin.s}
+ {{readelf -WSsrl tlsbin.rd} {objdump -drj.text tlsbin.dd}
+ {objdump -sj.got tlsbin.sd} {objdump -sj.tdata tlsbin.td}}
+ "tlsbin"}
+ {"TLS in debug sections" "-melf64_ia64"
+ "" {tlsg.s}
+ {{objdump -sj.debug_foobar tlsg.sd}} "tlsg"}
+}
+
+run_ld_link_tests $ia64tests