aboutsummaryrefslogtreecommitdiffstats
path: root/test/Object
diff options
context:
space:
mode:
authorMichael J. Spencer <bigcheesegs@gmail.com>2011-09-27 19:37:18 +0000
committerMichael J. Spencer <bigcheesegs@gmail.com>2011-09-27 19:37:18 +0000
commit9142ae2cf802dbcd1c622154ac9b5305fb26c38f (patch)
treec085b7a921c53777b0bac88a594cc44a930a6425 /test/Object
parenta51d7d97b0b8187ed68d4cbad2374f514d2cd168 (diff)
downloadexternal_llvm-9142ae2cf802dbcd1c622154ac9b5305fb26c38f.zip
external_llvm-9142ae2cf802dbcd1c622154ac9b5305fb26c38f.tar.gz
external_llvm-9142ae2cf802dbcd1c622154ac9b5305fb26c38f.tar.bz2
Add binary archive support to llvm-nm.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140627 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Object')
-rw-r--r--test/Object/TestObjectFiles/archive-test.a-bitcodebin0 -> 790 bytes
-rw-r--r--test/Object/TestObjectFiles/archive-test.a-coff-i386bin0 -> 658 bytes
-rw-r--r--test/Object/nm-archive.test17
3 files changed, 17 insertions, 0 deletions
diff --git a/test/Object/TestObjectFiles/archive-test.a-bitcode b/test/Object/TestObjectFiles/archive-test.a-bitcode
new file mode 100644
index 0000000..3aeb34f
--- /dev/null
+++ b/test/Object/TestObjectFiles/archive-test.a-bitcode
Binary files differ
diff --git a/test/Object/TestObjectFiles/archive-test.a-coff-i386 b/test/Object/TestObjectFiles/archive-test.a-coff-i386
new file mode 100644
index 0000000..846cd63
--- /dev/null
+++ b/test/Object/TestObjectFiles/archive-test.a-coff-i386
Binary files differ
diff --git a/test/Object/nm-archive.test b/test/Object/nm-archive.test
new file mode 100644
index 0000000..da6144e
--- /dev/null
+++ b/test/Object/nm-archive.test
@@ -0,0 +1,17 @@
+RUN: llvm-nm %p/TestObjectFiles/archive-test.a-coff-i386 \
+RUN: | FileCheck %s -check-prefix COFF
+RUN: llvm-nm %p/TestObjectFiles/archive-test.a-bitcode \
+RUN: | FileCheck %s -check-prefix BITCODE
+
+
+COFF: trivial-object-test.coff-i386:
+COFF-NEXT: 00000000 d .data
+COFF-NEXT: 00000000 t .text
+COFF-NEXT: 00000000 d L_.str
+COFF-NEXT: U _SomeOtherFunction
+COFF-NEXT: 00000000 T _main
+COFF-NEXT: U _puts
+
+BITCODE: U SomeOtherFunction
+BITCODE-NEXT: T main
+BITCODE-NEXT: U puts