[PATCH] D64990: [clangd] Disable background-index on lit-tests by default
Kadir Cetinkaya via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Jul 19 06:29:47 PDT 2019
kadircet created this revision.
kadircet added a reviewer: sammccall.
Herald added subscribers: cfe-commits, arphaman, jkorous, MaskRay, ilya-biryukov.
Herald added a project: clang.
Since background-index can perform disk writes, we don't want to turn
it on tests that won't clear it.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D64990
Files:
clang-tools-extra/clangd/tool/ClangdMain.cpp
Index: clang-tools-extra/clangd/tool/ClangdMain.cpp
===================================================================
--- clang-tools-extra/clangd/tool/ClangdMain.cpp
+++ clang-tools-extra/clangd/tool/ClangdMain.cpp
@@ -355,6 +355,9 @@
InputStyle = JSONStreamStyle::Delimited;
LogLevel = Logger::Verbose;
PrettyPrint = true;
+ // Disable background index on lit tests by default to prevent disk writes.
+ if (!EnableBackgroundIndex.getNumOccurrences())
+ EnableBackgroundIndex = false;
// Ensure background index makes progress.
BackgroundQueue::preventThreadStarvationInTests();
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D64990.210820.patch
Type: text/x-patch
Size: 623 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190719/a1810593/attachment-0001.bin>
More information about the cfe-commits
mailing list