Skip to content

[BUG] we should not use the __ldcg, __ldcv, etc intrinsics? #569

Open
@teju85

Description

@teju85

I have put in a question mark in the issue as I wasn't sure what's the right approach here! Let me describe the current issue.

There are a couple of places where we are using these intrinsics in RAFT:

  1. Usage of __ldcv in linewise_op.cuh
  2. Usage of __ldcg in reduce_rows_by_key.cuh

Unfortunately, clang doesn't support(?) these intrinsics, unlike our CTK. Because of this, clang-tidy fails to compile such source files, thereby causing trouble in enabling tidy checks in our repo's. Thus, we currently have an explicit definition of these functions in a separate header file which our run-clang-tidy.py refers to.

There are a few possible ways to solve this issue:

  1. Send a PR to clang to add these intrinsics support.
  2. Continue to maintain the above mentioned intrinsics header file just for clang-tidy purposes. We'll have to continue to maintain and keep this updated and depending on how other RAPIDS projects adapt clang-tidy checks, they too might have to copy this around!
  3. Do not use these intrinsics in our source files and instead implement explicit definitions of such in our device_loads_stores.cuh.

I honestly don't know what's the right approach, and hence would like thoughts from others in this regard. This is NOT a priority item as atleast for now, there's a workaround.

Cc += @MatthiasKohl, @dantegd and @cjnolet

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions