[clang-tools-extra] r345700 - [clangd] fix non linux build
David Carlier via cfe-commits
cfe-commits at lists.llvm.org
Wed Oct 31 02:04:15 PDT 2018
Author: devnexen
Date: Wed Oct 31 02:04:15 2018
New Revision: 345700
URL: http://llvm.org/viewvc/llvm-project?rev=345700&view=rev
Log:
[clangd] fix non linux build
There is no SCHED_IDLE semantic equivalent in BSD systems.
Reviewers: kadircet, sammccall
Revieweed By: sammccall
Differential Revision: https://reviews.llvm.org/D53922
Modified:
clang-tools-extra/trunk/clangd/Threading.cpp
Modified: clang-tools-extra/trunk/clangd/Threading.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clangd/Threading.cpp?rev=345700&r1=345699&r2=345700&view=diff
==============================================================================
--- clang-tools-extra/trunk/clangd/Threading.cpp (original)
+++ clang-tools-extra/trunk/clangd/Threading.cpp Wed Oct 31 02:04:15 2018
@@ -102,7 +102,7 @@ void wait(std::unique_lock<std::mutex> &
}
void setThreadPriority(std::thread &T, ThreadPriority Priority) {
-#ifdef HAVE_PTHREAD_H
+#if defined(HAVE_PTHREAD_H) && defined(__linux__)
sched_param priority;
priority.sched_priority = 0;
pthread_setschedparam(
More information about the cfe-commits
mailing list