NVIDIA / NVIDIA/cccl

Support different value types in `cub::DeviceMerge`

Open
#2,074 0 comments 1 reaction 0 assignees View on GitHub
cub
Dominant language
C++
Stars
2.5k
Forks
486
Avg merge
2d 6h
Merged PRs (30d)
295

Description

`cub::DeviceMerge` does not officially (as documented) support merging sequences with different key or value types. Historically, `thrust::merge_by_key` before merging #1817 did support this in a limited fashion. We should dedicate some effort to make `cub::DeviceMerge` properly support mixing input types.

E.g., merging a key-value sequence of (int, short) with a sequence of (unsigned, long) into a sequence of (long, int). This requires us to avoid over- and underflow when comparing key types and possibly different register storage arrays for the input sequences, since a common key type between the two input key types may not be comparable by the comparison predicate.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.