NVIDIA / NVIDIA/cccl

Explore argument framework metadata for multiples and alignment

Open
#9,438 0 comments 0 reactions 1 assignee Claimed by @pciolkosz View on GitHub
Dominant language
C++
Stars
2.5k
Forks
486
Avg merge
2d 6h
Merged PRs (30d)
295

Description

# Explore argument framework metadata for multiples and alignment

We would like to explore extending the `cuda::args` framework with compile-time information beyond static bounds.

One concrete case is representing that a scalar argument is known to be a multiple of a specific value. This could let downstream code specialize without needing the exact constant value.

For sequence arguments, we may also want a way to signal that the referenced memory has a specific alignment. It is not yet clear whether that belongs in the argument framework itself or should be represented by another layer such as pointer/span/mdspan/accessor metadata.

## Questions to answer

- What API should express that a scalar value is a multiple of `N`?
- How should that compose with `static_bounds`, `immediate`, `deferred`, and `constant` arguments?
- What should argument traits expose to consumers?
- Does sequence alignment belong in `cuda::args`, or is there a better abstraction boundary?

This issue tracks the design exploration and any prototype tests needed to decide the direction.

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.