Skip to content

Commit b7ad1f2

Browse files
authored
Merge pull request acts-project#819 from stephenswat/refactor/replace_more_thrust_tuple
Remove Thrust pair type from prefix sum code
2 parents ef23946 + 583abd4 commit b7ad1f2

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

device/common/include/traccc/device/fill_prefix_sum.hpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,16 @@
1010
// Project include(s).
1111
#include "traccc/definitions/qualifiers.hpp"
1212
#include "traccc/edm/container.hpp"
13+
#include "traccc/utils/pair.hpp"
1314

1415
// VecMem include(s).
1516
#include <vecmem/memory/memory_resource.hpp>
1617
#include <vecmem/utils/copy.hpp>
1718

18-
// Thrust include(s).
19-
#include <thrust/pair.h>
20-
2119
namespace traccc::device {
2220

2321
/// Type for the individual elements in the prefix sum vector
24-
typedef thrust::pair<unsigned int, unsigned int> prefix_sum_element_t;
22+
typedef traccc::pair<unsigned int, unsigned int> prefix_sum_element_t;
2523

2624
/// Convenience type definition for the return value of the helper function
2725
typedef vecmem::vector<prefix_sum_element_t> prefix_sum_t;

device/common/include/traccc/device/impl/fill_prefix_sum.ipp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ inline void fill_prefix_sum(
2828
const prefix_sum_size_t current =
2929
sizes[static_cast<unsigned int>(globalIndex)];
3030
for (prefix_sum_size_t i = 0; i < current - previous; ++i) {
31-
result.at(previous + i) = {globalIndex, i};
31+
result.at(previous + i) = {static_cast<unsigned int>(globalIndex), i};
3232
}
3333
}
3434

0 commit comments

Comments
 (0)