41std::function<
void(UpdateGrid27 *updateGrid, Parameter *para,
int level,
unsigned int t)>
43 const bool kernelNeedsFluidNodeIndicesToRun)
45 VF_LOG_INFO(
"Function used for collisionAndExchange: ");
51 }
else if (useStreams && !kernelNeedsFluidNodeIndicesToRun) {
52 VF_LOG_INFO(
"Cuda Streams can only be used with kernels which run using fluidNodesIndices.");
55 VF_LOG_INFO(
"Cuda Streams can only be used with multiple MPI processes.");
57 }
else if (!useStreams && kernelNeedsFluidNodeIndicesToRun) {
58 VF_LOG_INFO(
"CollisionAndExchange_noStreams_indexKernel()");
61 }
else if (!useStreams && !kernelNeedsFluidNodeIndicesToRun) {
62 VF_LOG_INFO(
"CollisionAndExchange_noStreams_oldKernel()");
66 throw std::runtime_error(
"Invalid Configuration for collision and exchange");
78 updateGrid->collisionUsingIndices( level,
t,
79 para->
getParD(level)->taggedFluidNodeIndices[tag],
80 para->
getParD(level)->numberOfTaggedFluidNodes[tag],
86 updateGrid->exchangeMultiGPU_noStreams_withPrepare(level,
false);
96 updateGrid->collisionAllNodes(level,
t);
99 updateGrid->exchangeMultiGPU_noStreams_withPrepare(level,
false);
108 updateGrid->collisionUsingIndices( level,
t,
127 updateGrid->collisionUsingIndices( level,
t,
128 para->
getParD(level)->taggedFluidNodeIndices[tag],
129 para->
getParD(level)->numberOfTaggedFluidNodes[tag],
Version of collision: for multi-gpu simulations, without communication hiding ("streams"),...
void operator()(UpdateGrid27 *updateGrid, Parameter *para, int level, unsigned int t)
Version of collision: for multi-gpu simulations, without communication hiding ("streams"),...
void operator()(UpdateGrid27 *updateGrid, Parameter *para, int level, unsigned int t)
Version of collision: for multi-gpu simulations, with communication hiding ("streams"),...
void operator()(UpdateGrid27 *updateGrid, Parameter *para, int level, unsigned int t)
Class for LBM-parameter management.
std::shared_ptr< LBMSimulationParameter > getParH(int level) const
Pointer to instance of LBMSimulationParameter - stored on Host System.
std::unique_ptr< CudaStreamManager > & getStreamManager()
std::shared_ptr< LBMSimulationParameter > getParD(int level)
Pointer to instance of LBMSimulationParameter - stored on Device (GPU)
std::shared_ptr< T > SPtr
std::function< void(UpdateGrid27 *updateGrid, Parameter *para, int level, unsigned int t)> getFunctionForCollisionAndExchange(const bool useStreams, const int numberOfMpiProcesses, const bool kernelNeedsFluidNodeIndicesToRun)
get a function which performs the collision operator and performs the communication between gpus/ pro...
CollisionTemplate
An enumeration for selecting a template of the collision kernel (CumulantK17)