[lld] r296740 - [ELF] - Fix version-script-extern-exact.s testcase
George Rimar via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 2 03:03:58 PST 2017
Author: grimar
Date: Thu Mar 2 05:03:58 2017
New Revision: 296740
URL: http://llvm.org/viewvc/llvm-project?rev=296740&view=rev
Log:
[ELF] - Fix version-script-extern-exact.s testcase
Previously it would not catch if exact symbol name
matching would change behavior to pattern matching.
Modified:
lld/trunk/test/ELF/version-script-extern-exact.s
Modified: lld/trunk/test/ELF/version-script-extern-exact.s
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/test/ELF/version-script-extern-exact.s?rev=296740&r1=296739&r2=296740&view=diff
==============================================================================
--- lld/trunk/test/ELF/version-script-extern-exact.s (original)
+++ lld/trunk/test/ELF/version-script-extern-exact.s Thu Mar 2 05:03:58 2017
@@ -3,12 +3,20 @@
# RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o
# RUN: echo "FOO { global: extern \"C++\" { \"aaa*\"; }; };" > %t.script
# RUN: ld.lld --version-script %t.script -shared %t.o -o %t.so
-# RUN: llvm-readobj -V -dyn-symbols %t.so | FileCheck %s
+# RUN: llvm-readobj -dyn-symbols %t.so | FileCheck %s --check-prefix=NOMATCH
-# CHECK: Symbol {
-# CHECK: Name: _Z3aaaPf@
-# CHECK: Symbol {
-# CHECK: Name: _Z3aaaPi@
+# NOMATCH: DynamicSymbols [
+# NOMATCH-NOT: _Z3aaaPf@@FOO
+# NOMATCH-NOT: _Z3aaaPi@@FOO
+# NOMATCH: ]
+
+# RUN: echo "FOO { global: extern \"C++\" { \"aaa*\"; aaa*; }; };" > %t2.script
+# RUN: ld.lld --version-script %t2.script -shared %t.o -o %t2.so
+# RUN: llvm-readobj -dyn-symbols %t2.so | FileCheck %s --check-prefix=MATCH
+# MATCH: DynamicSymbols [
+# MATCH: _Z3aaaPf@@FOO
+# MATCH: _Z3aaaPi@@FOO
+# MATCH: ]
.text
.globl _Z3aaaPi
More information about the llvm-commits
mailing list