Skip to content

Commit

Permalink
revert to threadpool (clang 10 compatibility issue)
Browse files Browse the repository at this point in the history
  • Loading branch information
fradav committed Sep 23, 2020
1 parent c337ae0 commit ee70b14
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions test/readreftable-test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#include <vector>
#include <algorithm>
#include <numeric>
#include <execution>
// #include <execution>

#define H5_USE_EIGEN
#include <highfive/H5Easy.hpp>
Expand All @@ -21,7 +21,7 @@
#include "readreftable.hpp"
#include "statobsTest.hpp"
#include "readstatobs.hpp"
// #include "threadpool.hpp"
#include "threadpool.hpp"

#include "H5Cpp.h"

Expand Down Expand Up @@ -90,7 +90,8 @@ void test_random_lines(HighFive::File &file, const string &dataname, const Matri
std::shuffle(std::begin(indices), std::end(indices), g);

auto loopvec = views::ints((size_t)0u,nloop) | to<std::vector>();
std::for_each(std::execution::par,loopvec.begin(),loopvec.end(), [&](size_t j) {
// std::for_each(std::execution::par,loopvec.begin(),loopvec.end(), [&](size_t j) {
ThreadPool::ParallelFor((size_t)0u, nloop, [&](size_t j) {
auto i = indices[j];
auto row = p.row(i);
const auto &expected = Catch::Matchers::ApproxRng<std::vector<double>>(row);
Expand Down

0 comments on commit ee70b14

Please sign in to comment.