MCPcopy Create free account
hub / github.com/Rust-GPU/rust-cuda / index_1d

Function index_1d

crates/cuda_std/src/thread.rs:230–232  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

228
229#[inline(always)]
230pub fn index_1d() -> u32 {
231 thread_idx_x() as u32 + block_idx_x() as u32 * block_dim_x() as u32
232}
233
234#[inline(always)]
235pub fn index_2d() -> Vec2<u32> {

Callers 1

addFunction · 0.85

Calls 3

thread_idx_xFunction · 0.85
block_idx_xFunction · 0.85
block_dim_xFunction · 0.85

Tested by

no test coverage detected