Skip to content

[BUG]: Wrong mask type in cub/cub/block/block_radix_rank.cuh #6106

@miscco

Description

@miscco

Is this a duplicate?

Type of Bug

Something else

Component

CUB

Describe the bug

The implementation uses int for masks that go into intrinsics that expect unsigned types.

So far this has been fine because the intrinsics behave nicely there but we plan on dropping them in favor of internal functions that actually check whether we are using the right type. We should change the types of match_masks and other masks to uint32_t or uint64_t

How to Reproduce

Came up in #6099 when transitioning __clz to cuda::std::countl_zero

Expected behavior

We should use the right type for bitmasks

Reproduction link

No response

Operating System

No response

nvidia-smi output

No response

NVCC version

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working right.cubFor all items related to CUBgood first issueGood for newcomers.

    Type

    No type

    Projects

    Status

    In Review

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions