summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2019-07-24 08:15:56 -0700
committerH.J. Lu <hjl.tools@gmail.com>2019-07-24 08:17:33 -0700
commit8f79c1075e8f258ac5a909b39704009ebc440e76 (patch)
tree8016d8f2023111d210dbf38de6142f9ce0fed2d1
parent4625b4d081eb0a243c6c7370f9a12c97bf6bcf65 (diff)
downloadbinutils-8f79c1075e8f258ac5a909b39704009ebc440e76.tar.gz
binutils-8f79c1075e8f258ac5a909b39704009ebc440e76.tar.xz
binutils-8f79c1075e8f258ac5a909b39704009ebc440e76.zip
Revert "Remove tests that test __gnu_lto_v1 symbol."
Revert commit 8c728a9d93e2342c57039fcdd6e4a502875b9e09 Author: Martin Liska <mliska@suse.cz> Date: Mon Jul 22 14:23:32 2019 +0200 Remove tests that test __gnu_lto_v1 symbol. since outputs of these tests are used by later tests. Check the normal symbol, foo, instead of __gnu_lto_v.*, which GCC stopped emitting after r273662. * testsuite/ld-plugin/lto-3r.d: Restored. Check foo instead of __gnu_lto_v.*. * testsuite/ld-plugin/lto-5r.d: Likewise. * testsuite/ld-plugin/lto.exp: Run lto-3r and lto-5r tests.
-rw-r--r--ld/ChangeLog7
-rw-r--r--ld/testsuite/ld-plugin/lto-3r.d7
-rw-r--r--ld/testsuite/ld-plugin/lto-5r.d7
-rw-r--r--ld/testsuite/ld-plugin/lto.exp6
4 files changed, 27 insertions, 0 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog
index b42f4a7ecb..9017eb0734 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,3 +1,10 @@
+2019-07-24 H.J. Lu <hongjiu.lu@intel.com>
+
+ * testsuite/ld-plugin/lto-3r.d: Restored. Check foo instead
+ of __gnu_lto_v.*.
+ * testsuite/ld-plugin/lto-5r.d: Likewise.
+ * testsuite/ld-plugin/lto.exp: Run lto-3r and lto-5r tests.
+
2019-07-24 Claudiu Zissulescu <claziss@synopsys.com>
* ld-arc/relax-local-pic.d: New test.
diff --git a/ld/testsuite/ld-plugin/lto-3r.d b/ld/testsuite/ld-plugin/lto-3r.d
new file mode 100644
index 0000000000..8ce4482d15
--- /dev/null
+++ b/ld/testsuite/ld-plugin/lto-3r.d
@@ -0,0 +1,7 @@
+#ld: -r tmpdir/lto-3b.o
+#source: dummy.s
+#nm: -p
+
+#...
+[0-9a-f]+ T _?foo
+#pass
diff --git a/ld/testsuite/ld-plugin/lto-5r.d b/ld/testsuite/ld-plugin/lto-5r.d
new file mode 100644
index 0000000000..57d41781c2
--- /dev/null
+++ b/ld/testsuite/ld-plugin/lto-5r.d
@@ -0,0 +1,7 @@
+#ld: -r tmpdir/lto-5a.o tmpdir/lto-5b.o
+#source: dummy.s
+#nm: -p
+
+#...
+[0-9a-f]+ T _?foo
+#pass
diff --git a/ld/testsuite/ld-plugin/lto.exp b/ld/testsuite/ld-plugin/lto.exp
index b80de4902c..e913c6f203 100644
--- a/ld/testsuite/ld-plugin/lto.exp
+++ b/ld/testsuite/ld-plugin/lto.exp
@@ -630,6 +630,12 @@ if { [at_least_gcc_version 4 7] } {
}
}
+# Run "ld -r" to generate inputs for complex LTO tests.
+run_dump_test "lto-3r"
+remote_exec host "mv" "tmpdir/dump tmpdir/lto-3.o"
+run_dump_test "lto-5r"
+remote_exec host "mv" "tmpdir/dump tmpdir/lto-5.o"
+
run_cc_link_tests $lto_link_symbol_tests
run_ld_link_tests [list \