[PATCH] D42174: [clangd] Refactored threading in ClangdServer

Sam McCall via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 30 03:35:30 PST 2018


sammccall added a comment.

As discussed offline, basically the only thing to do for testing ThreadPool is to bash it with a workload, and some sort of whole-program stress test seems ideal for this and will also give some coverage to other components (and we should run under tsan!).

TUScheduler on the other hand is a big important class with a clear interface and contract, and is about to get a new implementation - testcases verifying the contracts will be extremely valuable.
These tests don't really need to be concurrency-heavy I think.



================
Comment at: clangd/TUScheduler.h:10
+
+#ifndef LLVM_CLANG_TOOLS_EXTRA_CLANGD_THREADING_SCHEDULER_H
+#define LLVM_CLANG_TOOLS_EXTRA_CLANGD_THREADING_SCHEDULER_H
----------------
header guards are stale, sorry!


================
Comment at: clangd/Threading.h:10
+
+#ifndef LLVM_CLANG_TOOLS_EXTRA_CLANGD_THREADING_THREADPOOL_H
+#define LLVM_CLANG_TOOLS_EXTRA_CLANGD_THREADING_THREADPOOL_H
----------------
this one also stale


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D42174





More information about the cfe-commits mailing list