Skip to content

Commit

Permalink
set_thread_priority requires LLVM_ENABLE_THREADS and LLVM_VERSION_MAJ…
Browse files Browse the repository at this point in the history
…OR >= 9
  • Loading branch information
eklitzke committed Dec 3, 2019
1 parent 384dd1e commit d3bc255
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/messages/initialize.cc
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 255,9 @@ void *indexer(void *arg_) {
delete arg;
std::string name = "indexer" std::to_string(idx);
set_thread_name(name.c_str());
#if defined(LLVM_ENABLE_THREADS) && LLVM_VERSION_MAJOR >= 9
set_thread_priority(ThreadPriority::Background);
#endif
pipeline::indexer_Main(h->manager, h->vfs, h->project, h->wfiles);
pipeline::threadLeave();
return nullptr;
Expand Down

0 comments on commit d3bc255

Please sign in to comment.