diff --git a/testing/stdrel_criterion.cu b/testing/stdrel_criterion.cu index 326196a..f0affea 100644 --- a/testing/stdrel_criterion.cu +++ b/testing/stdrel_criterion.cu @@ -41,8 +41,8 @@ void test_const() std::vector generate(double mean, double rel_std_dev, int size) { - std::random_device rd; - std::mt19937 gen(rd()); + static std::mt19937::result_type seed = 0; + std::mt19937 gen(seed++); std::vector v(static_cast(size)); std::normal_distribution dist(mean, mean * rel_std_dev); std::generate(v.begin(), v.end(), [&]{ return dist(gen); });