()
| 240 | |
| 241 | #[inline(always)] |
| 242 | pub fn index_3d() -> Vec3<u32> { |
| 243 | let i = thread_idx_x() + block_idx_x() * block_dim_x(); |
| 244 | let j = thread_idx_y() + block_idx_y() * block_dim_y(); |
| 245 | let k = thread_idx_z() + block_idx_z() * block_dim_z(); |
| 246 | Vec3::new(i, j, k) |
| 247 | } |
| 248 | |
| 249 | /// Whether this is the first thread (not the first thread to be executing). This function is guaranteed |
| 250 | /// to only return true in a single thread that is invoking it. This is useful for only doing something |
nothing calls this directly
no test coverage detected