Re-add support for lbarx, lharx, stbcx. and sthcx. insns back to the E6500 cpu.
[binutils-gdb.git] / ld / testsuite / ld-pe / pe.exp
bloba31f6e7fd74e1e622d019a33b3e5f82000cc212d
1 # Expect script for simple PE tests that require the just-built binutils only.
2 # Copyright (C) 2004-2016 Free Software Foundation, Inc.
4 # This file is part of the GNU Binutils.
6 # This program is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 3 of the License, or
9 # (at your option) any later version.
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, write to the Free Software
18 # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
19 # MA 02110-1301, USA.
22 # These tests can only be run on PE/COFF platforms.
23 if {![is_pecoff_format]} {
24 return
27 # This test can only be run on PE/COFF platforms that support .secrel32.
28 if {[istarget i*86-*-cygwin*]
29 || [istarget i*86-*-pe]
30 || [istarget i*86-*-mingw*]
31 || [istarget x86_64-*-mingw*]
32 || [istarget arm-wince-pe] } {
34 if {[istarget x86_64-*-mingw*] } {
35 set pe_tests {
36 {".secrel32" "" "" "" {secrel1.s secrel2.s}
37 {{objdump -s secrel_64.d}} "secrel.x"}
38 {"Empty export table" "" "" "" "exports.s"
39 {{objdump -p exports64.d}} "exports.dll"}
40 {"TLS directory entry" "" "" "" "tlssec.s"
41 {{objdump -p tlssec64.d}} "tlssec.dll"}
43 } elseif {[istarget i*86-*-cygwin*] } {
44 set pe_tests {
45 {".secrel32" "--disable-auto-import" "" "" {secrel1.s secrel2.s}
46 {{objdump -s secrel.d}} "secrel.x"}
47 {"Empty export table" "" "" "" "exports.s"
48 {{objdump -p exports.d}} "exports.dll"}
49 {"TLS directory entry" "" "" "" "tlssec.s"
50 {{objdump -p tlssec32.d}} "tlssec.dll"}
52 } else {
53 set pe_tests {
54 {".secrel32" "" "" "" {secrel1.s secrel2.s}
55 {{objdump -s secrel.d}} "secrel.x"}
56 {"Empty export table" "" "" "" "exports.s"
57 {{objdump -p exports.d}} "exports.dll"}
58 {"TLS directory entry" "" "" "" "tlssec.s"
59 {{objdump -p tlssec32.d}} "tlssec.dll"}
63 run_ld_link_tests $pe_tests
66 run_dump_test "image_size"
67 run_dump_test "export_dynamic_warning"
69 run_dump_test "longsecn"
70 run_dump_test "longsecn-1"
71 run_dump_test "longsecn-2"
72 run_dump_test "longsecn-3"
73 run_dump_test "longsecn-4"
74 run_dump_test "longsecn-5"
76 run_dump_test "orphan"
77 run_dump_test "orphan_nu"
79 run_dump_test "pr19803"
80 set pr19803_dll {
81 { "PR 19803: not exporting swept symbols"
82 "-shared --out-implib dx.dll --gc-sections"
83 "" "" {pr19803.s}
84 {{objdump "--syms dx.dll" pr19803.e}}
85 "a.exe"}
87 # This test is *supposed* to fail. If the symbol defined in pr19803.e is
88 # found then it was not stripped from the export dll, despite the fact that
89 # it (should have been) garbage collected from the executable.
90 setup_xfail *-*-*
91 run_ld_link_tests $pr19803_dll
93 if {[istarget x86_64-*-mingw*] } {
94 run_dump_test "cfi"
95 } elseif {[istarget i*86-*-cygwin*] || [istarget i*86-*-mingw*] } {
96 run_dump_test "cfi32"
99 set foreign_sym_test {
100 {"non-C aligned common" "" "" "" {non-c-lang-syms.s}
101 {{nm -C non-c-lang-syms.d}} "non-c-lang-syms.x"}
104 run_ld_link_tests $foreign_sym_test