Skip to content

Commit

Permalink
Conditional compilation.
Browse files Browse the repository at this point in the history
  • Loading branch information
trivialfis committed Oct 11, 2020
1 parent 32bfc7d commit 543f8a6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/cpp/common/test_threading_utils.cc
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ TEST(ParallelFor2dNonUniform, Test) {

omp_set_num_threads(old);
}

#if defined(_OPENMP)
TEST(OmpSetNumThreads, Basic) {
auto nthreads = 2;
auto orgi = OmpSetNumThreads(&nthreads);
Expand All @@ -104,5 +104,6 @@ TEST(OmpSetNumThreads, Basic) {

omp_set_num_threads(orgi);
}
#endif // defined(_OPENMP)
} // namespace common
} // namespace xgboost

0 comments on commit 543f8a6

Please sign in to comment.