OpenFPM_pdata  4.1.0
Project that contain the implementation of distributed structures
BlockMapGpu_ker< AggregateBlockT, indexT, layout_base > Class Template Reference

Detailed Description

template<typename AggregateBlockT = aggregate<DataBlock<float, 64>>, typename indexT = int, template< typename > class layout_base = memory_traits_inte>
class BlockMapGpu_ker< AggregateBlockT, indexT, layout_base >

Definition at line 71 of file BlockMapGpu_ker.cuh.

+ Inheritance diagram for BlockMapGpu_ker< AggregateBlockT, indexT, layout_base >:

Public Types

typedef AggregateBlockT AggregateType
 
typedef InsertBlockWrapper< AggregateBlockT, pMask > InsertBlockWrapperType
 

Public Member Functions

 BlockMapGpu_ker (openfpm::vector_sparse_gpu_ker< AggregateBlockT, indexT, layout_base > blockMap)
 
template<unsigned int p>
__device__ auto get (unsigned int linId) const -> ScalarTypeOf< AggregateBlockT, p >
 
template<unsigned int p>
__device__ auto get (unsigned int blockId, unsigned int offset) const -> ScalarTypeOf< AggregateBlockT, p >
 
__device__ auto getBlock (unsigned int blockId) -> decltype(blockMap.get(0))
 
template<unsigned int p>
__device__ ScalarTypeOf< AggregateBlockT, p > & getReference (unsigned int linId)
 
template<unsigned int p>
__device__ ScalarTypeOf< AggregateBlockT, p > & getReference (unsigned int blockId, unsigned int offset)
 
template<unsigned int p>
__device__ auto insert (unsigned int linId) -> ScalarTypeOf< AggregateBlockT, p > &
 
template<unsigned int p>
__device__ auto insert (unsigned int blockId, unsigned int offset) -> ScalarTypeOf< AggregateBlockT, p > &
 
template<unsigned int nChunksPerBlocks = 1>
__device__ auto insertBlock (indexT blockId, unsigned int stride=8192) -> decltype(blockMap.insert(0))
 
__device__ openfpm::vector_sparse_gpu_ker< AggregateBlockT, indexT, layout_base > & getblockMap ()
 
__device__ void get_sparse (unsigned int linId, unsigned int &dataBlockPos, unsigned int &offset) const
 
__device__ void init ()
 
__device__ void flush_block_insert ()
 
__device__ ScalarTypeOf< AggregateBlockT, pMask > getMask (unsigned int linId) const
 
__device__ void remove (unsigned int linId)
 
__device__ void remove (unsigned int blockId, unsigned int offset)
 
__device__ auto getIndexBuffer () -> decltype(blockMap.getIndexBuffer())
 Return the index buffer for the sparse vector. More...
 
__device__ auto getDataBuffer () -> decltype(blockMap.getDataBuffer())
 Return the data buffer for the sparse vector. More...
 

Static Public Member Functions

template<typename BitMaskT >
static __device__ __host__ bool getBit (const BitMaskT &bitMask, unsigned char pos)
 
template<typename BitMaskT >
static __device__ __host__ void setBit (BitMaskT &bitMask, unsigned char pos)
 
template<typename BitMaskT >
static __device__ __host__ void unsetBit (BitMaskT &bitMask, unsigned char pos)
 
static __device__ unsigned int getBlockId (unsigned int linId)
 
static __device__ unsigned int getOffset (unsigned int linId)
 
template<typename BitMaskT >
static __device__ bool exist (const BitMaskT &bitMask)
 
template<typename BitMaskT >
static __device__ void setExist (BitMaskT &bitMask)
 
template<typename BitMaskT >
static __device__ void unsetExist (BitMaskT &bitMask)
 

Static Public Attributes

static const unsigned int pMask = AggregateBlockT::max_prop_real - 1
 

Protected Attributes

openfpm::vector_sparse_gpu_ker< AggregateBlockT, indexT, layout_base > blockMap
 

Static Protected Attributes

static const unsigned char EXIST_BIT = 0
 

Member Function Documentation

◆ getDataBuffer()

template<typename AggregateBlockT = aggregate<DataBlock<float, 64>>, typename indexT = int, template< typename > class layout_base = memory_traits_inte>
__device__ auto BlockMapGpu_ker< AggregateBlockT, indexT, layout_base >::getDataBuffer ( ) -> decltype(blockMap.getDataBuffer())
inline

Return the data buffer for the sparse vector.

Definition at line 349 of file BlockMapGpu_ker.cuh.

◆ getIndexBuffer()

template<typename AggregateBlockT = aggregate<DataBlock<float, 64>>, typename indexT = int, template< typename > class layout_base = memory_traits_inte>
__device__ auto BlockMapGpu_ker< AggregateBlockT, indexT, layout_base >::getIndexBuffer ( ) -> decltype(blockMap.getIndexBuffer())
inline

Return the index buffer for the sparse vector.

Definition at line 339 of file BlockMapGpu_ker.cuh.


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