cheshirekow
v0.1.0
|
partial specialization for key-only sort More...
#include <mpblocks/cuda/bitonic/Sorter.h>
Public Types | |
typedef unsigned int | uint_t |
Public Member Functions | |
void | config () |
configures the sorter for the current cuda device More... | |
void | config (int dev) |
configures the sorter for the specified cuda device More... | |
uint_t | sort (KeyType *d_DstKey, KeyType *d_SrcKey, uint_t arrayLength, Direction dir=Ascending) |
actually perform the sort More... | |
Sorter (KeyType min, KeyType max) | |
the constructor queries the current device and calculates relevent parameters to decide how to size the kernels when they're called More... | |
Private Member Functions | |
void | prepare (KeyType *d_SrcKey, uint_t arrayLength, Direction dir) |
used when arrayLength is not a power-of-two, fills the remaining elements with either the min key value of the max key value More... | |
Private Attributes | |
KeyType | m_max |
KeyType | m_min |
uint_t | m_nSM |
number of SMs of the current device More... | |
uint_t | m_sharedLength |
the size (in elements) of shared memory buffers in all the kernels (also, 2x the number of threads in a block) More... | |
uint_t | m_threadsMerge |
number of threads per block to use in the global merge kernel More... | |
uint_t | m_threadsPrepare |
number of threads per block to use in the prepare kernel More... | |
partial specialization for key-only sort
typedef unsigned int mpblocks::cuda::bitonic::Sorter< KeyType, void >::uint_t |
mpblocks::cuda::bitonic::Sorter< KeyType, void >::Sorter | ( | KeyType | min, |
KeyType | max | ||
) |
the constructor queries the current device and calculates relevent parameters to decide how to size the kernels when they're called
Definition at line 285 of file Sorter.cu.hpp.
void mpblocks::cuda::bitonic::Sorter< KeyType, void >::config | ( | ) |
configures the sorter for the current cuda device
Definition at line 295 of file Sorter.cu.hpp.
void mpblocks::cuda::bitonic::Sorter< KeyType, void >::config | ( | int | dev | ) |
configures the sorter for the specified cuda device
Definition at line 302 of file Sorter.cu.hpp.
|
private |
used when arrayLength is not a power-of-two, fills the remaining elements with either the min key value of the max key value
Definition at line 419 of file Sorter.cu.hpp.
uint_t mpblocks::cuda::bitonic::Sorter< KeyType, void >::sort | ( | KeyType * | d_DstKey, |
KeyType * | d_SrcKey, | ||
uint_t | arrayLength, | ||
Direction | dir = Ascending |
||
) |
actually perform the sort
[out] | *d_DstKey | the output array for sorted keys |
[out] | *d_DstVal | the output array for sorted values |
[in] | *d_SrcKey | pointer to start of intput array for keys |
[in] | *d_SrcVal | pointer to start of input array for values |
[in] | arrayLength | the size of the array to sort |
[in] | dir | whether to sort ascending or descending) |
Definition at line 382 of file Sorter.cu.hpp.
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |