cuda-api-wrappers
Thin C++-flavored wrappers for the CUDA Runtime API
cuda::grid::composite_dimensions_t Struct Reference

Composite dimensions for a grid - in terms of blocks, then also down into the block dimensions completing the information to the thread level. More...

#include <types.hpp>

Collaboration diagram for cuda::grid::composite_dimensions_t:

Public Member Functions

constexpr overall_dimensions_t flatten () const noexcept
 
constexpr size_t volume () const noexcept
 
constexpr size_t dimensionality () const noexcept
 

Static Public Member Functions

static constexpr composite_dimensions_t point () noexcept
 A named constructor idiom for the composite dimensions of a single-block grid with a single-thread block.
 

Public Attributes

grid::dimensions_t grid
 
grid::block_dimensions_t block
 

Detailed Description

Composite dimensions for a grid - in terms of blocks, then also down into the block dimensions completing the information to the thread level.

Member Function Documentation

◆ dimensionality()

constexpr size_t cuda::grid::composite_dimensions_t::dimensionality ( ) const
inlinenoexcept
Returns
the number of axes in which the grid overall has non-trivial dimension

◆ flatten()

constexpr overall_dimensions_t cuda::grid::composite_dimensions_t::flatten ( ) const
inlinenoexcept
Returns
The overall dimensions of the entire grid as a single 3D entity

◆ volume()

constexpr size_t cuda::grid::composite_dimensions_t::volume ( ) const
inlinenoexcept
Returns
The total number of threads over all blocks of the grid

The documentation for this struct was generated from the following file: