summaryrefslogtreecommitdiffstats
path: root/clang/unittests/Basic/FileManagerTest.cpp
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2012-12-11 07:48:23 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2012-12-11 07:48:23 +0000
commit3b7793797f773ee0132b38767b104ad80af75229 (patch)
treecf23e1f1775f3baa245e66f82fece41cd860b09c /clang/unittests/Basic/FileManagerTest.cpp
parent53c3877f94635ed77ccb35cd1dffc3b44e42dff4 (diff)
downloadbcm5719-llvm-3b7793797f773ee0132b38767b104ad80af75229.tar.gz
bcm5719-llvm-3b7793797f773ee0132b38767b104ad80af75229.zip
Extend stat query APIs to explicitly specify if the query is for
a file or directory, allowing just a stat call if a file descriptor is not needed. Doing just 'stat' is faster than 'open/fstat/close'. This has the effect of cutting down system time for validating the input files of a PCH. llvm-svn: 169831
Diffstat (limited to 'clang/unittests/Basic/FileManagerTest.cpp')
-rw-r--r--clang/unittests/Basic/FileManagerTest.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/unittests/Basic/FileManagerTest.cpp b/clang/unittests/Basic/FileManagerTest.cpp
index 0a83a3aeb73..a55fcbf76cf 100644
--- a/clang/unittests/Basic/FileManagerTest.cpp
+++ b/clang/unittests/Basic/FileManagerTest.cpp
@@ -51,7 +51,7 @@ public:
// Implement FileSystemStatCache::getStat().
virtual LookupResult getStat(const char *Path, struct stat &StatBuf,
- int *FileDescriptor) {
+ bool isFile, int *FileDescriptor) {
if (StatCalls.count(Path) != 0) {
StatBuf = StatCalls[Path];
return CacheExists;
OpenPOWER on IntegriCloud