summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Carlier <devnexen@gmail.com>2018-10-31 09:04:15 +0000
committerDavid Carlier <devnexen@gmail.com>2018-10-31 09:04:15 +0000
commit13727da72f96add0d56ff62ca3420eecacdd7994 (patch)
treec75ad3efa40260e08e7e78d4734eee6be2515f74
parent59f18f1b72941a347aaf7d8eef61f8e7dd9f241a (diff)
downloadbcm5719-llvm-13727da72f96add0d56ff62ca3420eecacdd7994.tar.gz
bcm5719-llvm-13727da72f96add0d56ff62ca3420eecacdd7994.zip
[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 llvm-svn: 345700
-rw-r--r--clang-tools-extra/clangd/Threading.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang-tools-extra/clangd/Threading.cpp b/clang-tools-extra/clangd/Threading.cpp
index 9f1cbef95c0..af9c179d871 100644
--- a/clang-tools-extra/clangd/Threading.cpp
+++ b/clang-tools-extra/clangd/Threading.cpp
@@ -102,7 +102,7 @@ void wait(std::unique_lock<std::mutex> &Lock, std::condition_variable &CV,
}
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(
OpenPOWER on IntegriCloud