summaryrefslogtreecommitdiffstats
path: root/llvm/test/Object
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2015-07-14 22:18:43 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2015-07-14 22:18:43 +0000
commit4b83cb5390c7c66a74bc39a9ec85d804695b14c3 (patch)
treec4cd019d82af12d73a38b475e76cb40a5056280e /llvm/test/Object
parent4154ad467b177729ffbbc90ab0799cfc08b9b04d (diff)
downloadbcm5719-llvm-4b83cb5390c7c66a74bc39a9ec85d804695b14c3.tar.gz
bcm5719-llvm-4b83cb5390c7c66a74bc39a9ec85d804695b14c3.zip
Add support for reading members out of thin archives.
For now the Archive owns the buffers of the thin archive members. This makes for a simple API, but all the buffers are destructed only when the archive is destructed. This should be fine since we close the files after mmap so we should not hit an open file limit. llvm-svn: 242215
Diffstat (limited to 'llvm/test/Object')
-rw-r--r--llvm/test/Object/archive-extract.test6
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/test/Object/archive-extract.test b/llvm/test/Object/archive-extract.test
index c1ddcf71725..a77adf2cabb 100644
--- a/llvm/test/Object/archive-extract.test
+++ b/llvm/test/Object/archive-extract.test
@@ -48,3 +48,9 @@ NOTFOUND: foo.o was not found
RUN: not llvm-ar x %p/Inputs/thin.a foo.o 2>&1 | FileCheck %s --check-prefix=THINEXTRACT
THINEXTRACT: extracting from a thin archive is not supported
+
+RUN: llvm-ar p %p/Inputs/thin.a evenlen | FileCheck %s --check-prefix=EVENLEN
+EVENLEN: evenlen
+
+RUN: not llvm-ar p %p/Inputs/thin-path.a t/test2.o | FileCheck %s --check-prefix=MISSING
+MISSING: No such file or directory.
OpenPOWER on IntegriCloud