You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
We adopted P2322R6 scheme in CUB (NVIDIA/cub#428), but Thrust still uses accumulator types that are surprising to users and do not follow general C++ rules like integer promotion.
Describe the solution you'd like
We should decide if we'd like to proceed with P2322R6 adoption in Thrust and follow CUB scheme of selecting accumulator types.
Tasks
Decide if the silent change of accumulator type is breaking
Prepare a list of standard algorithms that specify accumulator types
Consider preparing a paper to adopt P2322R6 to standard algorithms
EDIT: the thrust bug is a known issue. Tracked by NVIDIA/cccl#153
This PR fixes an issue in `remove_if`. Strangely, when calling `reduce_by_key` with iterator to integer,
and when using `thrust::plus<index_t>()`, even if by definition the argument type of the plus operator is strongly typed
with a higher bit width integer type, and I expected that the flags (`uint8_t`) were cast to the higher
bit depth before addition, the overflow still happens. I have filed a thread in the thrust channel to discuss if this
is a bug in thrust.
Meanwhile, a quick WAR is to explicitly use a transform iterator to cast the uchar in to `index_t` before adding.
This should give the correct result.
Fixes#1200
Depend on #1207
Authors:
- Michael Wang (https://github.com/isVoid)
- H. Thomson Comer (https://github.com/thomcom)
Approvers:
- Mark Harris (https://github.com/harrism)
- H. Thomson Comer (https://github.com/thomcom)
URL: #1209
Is this a duplicate?
Area
Thrust
Is your feature request related to a problem? Please describe.
We adopted P2322R6 scheme in CUB (NVIDIA/cub#428), but Thrust still uses accumulator types that are surprising to users and do not follow general C++ rules like integer promotion.
Describe the solution you'd like
We should decide if we'd like to proceed with P2322R6 adoption in Thrust and follow CUB scheme of selecting accumulator types.
Tasks
CC: @jrhemstad @dkolsen-pgi
Describe alternatives you've considered
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: