diff options
Diffstat (limited to 'lib/Lex/HeaderSearch.cpp')
-rw-r--r-- | lib/Lex/HeaderSearch.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Lex/HeaderSearch.cpp b/lib/Lex/HeaderSearch.cpp index 789c93f231..11cb1ecd8c 100644 --- a/lib/Lex/HeaderSearch.cpp +++ b/lib/Lex/HeaderSearch.cpp @@ -18,6 +18,7 @@ #include "llvm/Support/FileSystem.h" #include "llvm/Support/Path.h" #include "llvm/ADT/SmallString.h" +#include "llvm/Support/Capacity.h" #include <cstdio> using namespace clang; @@ -544,8 +545,8 @@ bool HeaderSearch::ShouldEnterIncludeFile(const FileEntry *File, bool isImport){ size_t HeaderSearch::getTotalMemory() const { return SearchDirs.capacity() - + FileInfo.capacity() - + HeaderMaps.capacity() + + llvm::capacity_in_bytes(FileInfo) + + llvm::capacity_in_bytes(HeaderMaps) + LookupFileCache.getAllocator().getTotalMemory() + FrameworkMap.getAllocator().getTotalMemory(); } |