This repository has been archived by the owner on Mar 21, 2024. It is now read-only.
Invalid result from DeviceSegmentedSort::SortPairs/SortKeys when keys are bool type #594
Labels
P0: must have
Absolutely necessary. Critical issue, major blocker, etc.
type: bug: functional
Does not work as intended.
Milestone
If the keys parameter is type
bool
thenDeviceSegmentedSort::SortPairs
andDeviceSegmentedSort::SortKeys
return invalid results. The following example reproduces the error consistently. The error occurs withSortKeys
as well but is easier to see withSortPairs
The error consistently occurs at position 33 in the indices/result vector. The value itself is random. The values after position 33 are also incorrect but appear to be just shifted --
result[34] should be in result[33], result[35] should be in result[34], etc
The error appears to be caused by the following line:
cub/cub/agent/agent_sub_warp_merge_sort.cuh
Line 239 in 5ae7439
The
oob_default
value isxFF
and is neithertrue
norfalse
and so the sort algorithm is unable process it.Note that
true
fails to consistently compare againstdef
in this example: https://godbolt.org/z/f8bcjaMhWThe text was updated successfully, but these errors were encountered: