Skip to content
Snippets Groups Projects
Commit 1c07e0af authored by Jakub Klinkovský's avatar Jakub Klinkovský
Browse files

Fixed const-qualification of dataFetcher in CUDA reduction

parent 0cd31577
No related branches found
No related tags found
No related merge requests found
......@@ -140,7 +140,7 @@ template< int blockSize,
__global__ void
__launch_bounds__( Reduction_maxThreadsPerBlock, Reduction_minBlocksPerMultiprocessor )
CudaReductionWithArgumentKernel( const Result zero,
const DataFetcher dataFetcher,
DataFetcher dataFetcher,
const Reduction reduction,
const Index size,
Result* output,
......@@ -294,7 +294,7 @@ struct CudaReductionKernelLauncher
template< typename DataFetcher,
typename Reduction >
int start( const Reduction& reduction,
const DataFetcher& dataFetcher,
DataFetcher& dataFetcher,
const Result& zero,
Result*& output )
{
......@@ -311,7 +311,7 @@ struct CudaReductionKernelLauncher
template< typename DataFetcher,
typename Reduction >
int startWithArgument( const Reduction& reduction,
const DataFetcher& dataFetcher,
DataFetcher& dataFetcher,
const Result& zero,
Result*& output,
Index*& idxOutput )
......@@ -395,7 +395,7 @@ struct CudaReductionKernelLauncher
typename Reduction >
int launch( const Index size,
const Reduction& reduction,
const DataFetcher& dataFetcher,
DataFetcher& dataFetcher,
const Result& zero,
Result* output )
{
......@@ -498,7 +498,7 @@ struct CudaReductionKernelLauncher
typename Reduction >
int launchWithArgument( const Index size,
const Reduction& reduction,
const DataFetcher& dataFetcher,
DataFetcher& dataFetcher,
const Result& zero,
Result* output,
Index* idxOutput,
......
......@@ -160,13 +160,13 @@ template< typename Real,
typename Index >
__global__ void
cudaSecondPhaseBlockScan( Reduction reduction,
const Index size,
const int elementsInBlock,
const Index gridIdx,
const Index maxGridSize,
const Real* auxArray,
Real* data,
Real shift )
const Index size,
const int elementsInBlock,
const Index gridIdx,
const Index maxGridSize,
const Real* auxArray,
Real* data,
Real shift )
{
if( gridIdx > 0 || blockIdx.x > 0 )
shift = reduction( shift, auxArray[ gridIdx * maxGridSize + blockIdx.x - 1 ] );
......
/***************************************************************************
Scan.h - description
DistributedScan.h - description
-------------------
begin : Aug 16, 2019
copyright : (C) 2019 by Tomas Oberhuber et al.
......
......@@ -50,7 +50,7 @@ enum class ScanType {
* See \ref Scan< Devices::Host, Type > and \ref Scan< Devices::Cuda, Type >.
*/
template< typename Device,
ScanType Type = ScanType::Inclusive >
ScanType Type = ScanType::Inclusive >
struct Scan;
/**
......@@ -93,7 +93,7 @@ struct Scan;
* **Note: Segmented scan is not implemented for CUDA yet.**
*/
template< typename Device,
ScanType Type = ScanType::Inclusive >
ScanType Type = ScanType::Inclusive >
struct SegmentedScan;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment