2
0
mirror of https://github.com/boostorg/compute.git synced 2026-02-17 13:42:17 +00:00

Fix gather algorithm

This commit is contained in:
Jakub Szuppe
2016-08-22 18:51:14 +02:00
parent 544242744c
commit 45ea54f704
2 changed files with 6 additions and 3 deletions

View File

@@ -34,6 +34,11 @@ BOOST_AUTO_TEST_CASE(gather_int)
indices.begin(), indices.end(), input.begin(), output.begin(), queue
);
CHECK_RANGE_EQUAL(int, 5, output, (1, 5, 2, 4, 3));
compute::gather(
indices.begin() + 1, indices.end(), input.begin(), output.begin(), queue
);
CHECK_RANGE_EQUAL(int, 5, output, (5, 2, 4, 3, 3));
}
BOOST_AUTO_TEST_CASE(copy_index_then_gather)