Small doc updates

This commit is contained in:
Jacob Dufault 2017-12-23 15:42:54 -08:00
parent 64f094d347
commit 27b5816a7f
2 changed files with 5 additions and 5 deletions

View File

@ -3,6 +3,8 @@
#include <clang-c/Index.h>
// Simple RAII wrapper about CXIndex.
// Note: building a ClangIndex instance acquires a global lock, since libclang
// API does not appear to be thread-safe here.
class ClangIndex {
public:
ClangIndex();

View File

@ -505,14 +505,12 @@ WorkThread::Result IndexMain(Config* config,
QueueManager* queue) {
EmitProgress(config, queue);
// TODO: dispose of index after it is not used for a while.
// Build one index per-indexer, as building the index acquires a global lock.
ClangIndex index;
// TODO: process all off IndexMain_DoIndex before calling
// IndexMain_DoCreateIndexUpdate for
// better icache behavior. We need to have some threads spinning on
// both though
// otherwise memory usage will get bad.
// IndexMain_DoCreateIndexUpdate for better icache behavior. We need to have
// some threads spinning on both though otherwise memory usage will get bad.
// We need to make sure to run both IndexMain_DoParse and
// IndexMain_DoCreateIndexUpdate so we don't starve querydb from doing any