Corrected limiting the data vector size in test_reduce and test_transform.
MODIFY
test/test_reduce.cpp
test/test_reduce.cpp
@@ -233,7 +233,8 @@ TYPED_TEST(ReducePrimitiveTests, TestReduceCountingIterator)
const std::vector<size_t> sizes = get_sizes();
for(auto size : sizes)
{
- size_t n = thrust::min<size_t>(size, std::numeric_limits<T>::max());
+ size_t n = std::is_integral<T>::value ?
+ thrust::min<size_t>(size, std::numeric_limits<T>::max()) : size;
thrust::counting_iterator<T, thrust::host_system_tag> h_first
= thrust::make_counting_iterator<T>(0);

MODIFY
test/test_transform.cpp
test/test_transform.cpp
@@ -1123,7 +1123,9 @@ TYPED_TEST(TransformTests, TestTransformUnaryCountingIterator)
for(auto size : get_sizes())
{
+ if (std::is_integral<T>::value) {
size = thrust::min<size_t>(size, std::numeric_limits<T>::max());
+ }
thrust::counting_iterator<T, thrust::host_system_tag> h_first
= thrust::make_counting_iterator<T>(0);
@@ -1149,7 +1151,9 @@ TYPED_TEST(TransformTests, TestTransformBinaryCountingIterators)
for(auto size : get_sizes())
{
+ if (std::is_integral<T>::value) {
size = thrust::min<size_t>(size, std::numeric_limits<T>::max());
+ }
thrust::counting_iterator<T, thrust::host_system_tag> h_first
= thrust::make_counting_iterator<T>(0);

Corrected limiting the data vector size in test_reduce and test_transform. (#216)

Co-authored-by: kpyzhov <konstantin.pyzhov@amd.com>