25#include "core/DataTypes.h"
26#include "core/logging/Logging.h"
28#include "domain_decomposition/BlockDataID.h"
29#include "domain_decomposition/IBlock.h"
30#include "domain_decomposition/StructuredBlockStorage.h"
31#include "field/GhostLayerField.h"
32#include "field/SwapableCompare.h"
35#include <unordered_map>
38#define RESTRICT __restrict__
40#define RESTRICT __restrict
45#if (defined WALBERLA_CXX_COMPILER_IS_GNU) || \
46 (defined WALBERLA_CXX_COMPILER_IS_CLANG)
47#pragma GCC diagnostic push
48#pragma GCC diagnostic ignored "-Wunused-parameter"
49#pragma GCC diagnostic ignored "-Wreorder"
62 : forceID(forceID_), pdfsID(pdfsID_), grid_size_(grid_size),
63 omega_shear_(omega_shear), v_s_(v_s) {}
66 for (
auto p : cache_pdfs_) {
74 const CellInterval &globalCellInterval,
75 cell_idx_t ghostLayers, IBlock *
block);
79 static std::function<void(IBlock *)>
80 getSweep(
const shared_ptr<StreamCollideSweepLeesEdwardsDoublePrecisionAVX>
82 return [kernel](IBlock *b) { kernel->run(b); };
86 const shared_ptr<StreamCollideSweepLeesEdwardsDoublePrecisionAVX> &kernel,
87 const shared_ptr<StructuredBlockStorage> &blocks,
88 const CellInterval &globalCellInterval, cell_idx_t ghostLayers = 1) {
89 return [kernel, blocks, globalCellInterval, ghostLayers](IBlock *b) {
90 kernel->runOnCellInterval(blocks, globalCellInterval, ghostLayers, b);
95 return [
this](IBlock *b) { this->
run(b); };
98 std::function<void(IBlock *)>
100 const CellInterval &globalCellInterval,
101 cell_idx_t ghostLayers = 1) {
102 return [
this, blocks, globalCellInterval, ghostLayers](IBlock *b) {
107 void configure(
const shared_ptr<StructuredBlockStorage> & ,
112 inline double getV_s()
const {
return v_s_; }
115 inline void setV_s(
const double value) { v_s_ = value; }
123 std::unordered_map<IBlock *, field::GhostLayerField<double, 19> *>
130#if (defined WALBERLA_CXX_COMPILER_IS_GNU) || \
131 (defined WALBERLA_CXX_COMPILER_IS_CLANG)
132#pragma GCC diagnostic pop
StreamCollideSweepLeesEdwardsDoublePrecisionAVX(BlockDataID forceID_, BlockDataID pdfsID_, double grid_size, double omega_shear, double v_s)
static std::function< void(IBlock *)> getSweepOnCellInterval(const shared_ptr< StreamCollideSweepLeesEdwardsDoublePrecisionAVX > &kernel, const shared_ptr< StructuredBlockStorage > &blocks, const CellInterval &globalCellInterval, cell_idx_t ghostLayers=1)
~StreamCollideSweepLeesEdwardsDoublePrecisionAVX()
std::function< void(IBlock *)> getSweep()
static std::function< void(IBlock *)> getSweep(const shared_ptr< StreamCollideSweepLeesEdwardsDoublePrecisionAVX > &kernel)
void configure(const shared_ptr< StructuredBlockStorage > &, IBlock *)
void operator()(IBlock *block)
double getGrid_size() const
double getOmega_shear() const
void setV_s(const double value)
void runOnCellInterval(const shared_ptr< StructuredBlockStorage > &blocks, const CellInterval &globalCellInterval, cell_idx_t ghostLayers, IBlock *block)
void setOmega_shear(const double value)
void setGrid_size(const double value)
std::function< void(IBlock *)> getSweepOnCellInterval(const shared_ptr< StructuredBlockStorage > &blocks, const CellInterval &globalCellInterval, cell_idx_t ghostLayers=1)
static double * block(double *p, std::size_t index, std::size_t size)
\file PackInfoPdfDoublePrecision.cpp \author pystencils