ESPResSo
Extensible Simulation Package for Research on Soft Matter Systems
Loading...
Searching...
No Matches
PackInfoVecSinglePrecisionCUDA.h
Go to the documentation of this file.
1//======================================================================================================================
2//
3// This file is part of waLBerla. waLBerla is free software: you can
4// redistribute it and/or modify it under the terms of the GNU General Public
5// License as published by the Free Software Foundation, either version 3 of
6// the License, or (at your option) any later version.
7//
8// waLBerla is distributed in the hope that it will be useful, but WITHOUT
9// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
10// FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
11// for more details.
12//
13// You should have received a copy of the GNU General Public License along
14// with waLBerla (see COPYING.txt). If not, see <http://www.gnu.org/licenses/>.
15//
16//! \\file PackInfoVecSinglePrecisionCUDA.h
17//! \\author pystencils
18//======================================================================================================================
19
20// kernel generated with pystencils v1.3.3, lbmpy v1.3.3,
21// lbmpy_walberla/pystencils_walberla from waLBerla commit
22// b0842e1a493ce19ef1bbb8d2cf382fc343970a7f
23
24#pragma once
25
26#include "core/DataTypes.h"
27#include "core/cell/CellInterval.h"
28
29#include "domain_decomposition/IBlock.h"
30
31#include "stencil/Directions.h"
32
33#include "gpu/GPUField.h"
34#include "gpu/GPUWrapper.h"
35#include "gpu/communication/GeneratedGPUPackInfo.h"
36
37namespace walberla {
38namespace pystencils {
39
41 : public ::walberla::gpu::GeneratedGPUPackInfo {
42public:
43 PackInfoVecSinglePrecisionCUDA(BlockDataID fieldID_) : fieldID(fieldID_){};
45
46 void pack(stencil::Direction dir, unsigned char *buffer, IBlock *block,
47 gpuStream_t stream) override;
48 void communicateLocal(stencil::Direction /*dir*/, const IBlock * /* sender */,
49 IBlock * /* receiver */,
50 gpuStream_t /* stream */) override {
51 WALBERLA_ABORT("Local Communication not implemented yet for standard "
52 "PackInfos. To run your application turn of local "
53 "communication in the Communication class")
54 }
55 void unpack(stencil::Direction dir, unsigned char *buffer, IBlock *block,
56 gpuStream_t stream) override;
57 uint_t size(stencil::Direction dir, IBlock *block) override;
58
59private:
60 BlockDataID fieldID;
61};
62
63} // namespace pystencils
64} // namespace walberla
void unpack(stencil::Direction dir, unsigned char *buffer, IBlock *block, gpuStream_t stream) override
void communicateLocal(stencil::Direction, const IBlock *, IBlock *, gpuStream_t) override
uint_t size(stencil::Direction dir, IBlock *block) override
void pack(stencil::Direction dir, unsigned char *buffer, IBlock *block, gpuStream_t stream) override
cudaStream_t stream[1]
CUDA streams for parallel computing on CPU and GPU.
static double * block(double *p, std::size_t index, std::size_t size)
Definition elc.cpp:172
\file PackInfoPdfDoublePrecision.cpp \author pystencils