23#include "core/DataTypes.h"
24#include "core/Macros.h"
34#pragma GCC diagnostic push
35#pragma GCC diagnostic ignored "-Wstrict-aliasing"
36#pragma GCC diagnostic ignored "-Wunused-variable"
37#pragma GCC diagnostic ignored "-Wconversion"
42#ifdef __NVCC_DIAG_PRAGMA_SUPPORT__
43#pragma nv_diag_suppress 177
45#pragma diag_suppress 177
49namespace internal_8dfd6fd44211225f575bfd4fd9f8b4cc {
51 for (int64_t ctr_0 = 0; ctr_0 < indexVectorSize; ctr_0 += 1) {
52 const int32_t x = *((int32_t *)(&_data_indexVector[12 * ctr_0]));
53 const int32_t y = *((int32_t *)(&_data_indexVector[12 * ctr_0 + 4]));
54 const int32_t z = *((int32_t *)(&_data_indexVector[12 * ctr_0 + 8]));
56 const double local_rho_0 = _data_rho_0[_stride_rho_0_0 * x + _stride_rho_0_1 * y + _stride_rho_0_2 * z];
57 const double rate_factor = pow(local_rho_0, order_0) * rate_coefficient;
58 _data_rho_0[_stride_rho_0_0 * x + _stride_rho_0_1 * y + _stride_rho_0_2 * z] = local_rho_0 + rate_factor * stoech_0;
65#pragma GCC diagnostic pop
72void ReactionKernelIndexed_1_double_precision::run_impl(IBlock *
block, IndexVectors::Type type) {
73 auto *indexVectors =
block->uncheckedFastGetData<IndexVectors>(indexVectorID);
74 int32_t indexVectorSize = int32_c(indexVectors->indexVector(type).size());
75 if (indexVectorSize == 0)
78 auto pointer = indexVectors->pointerCpu(type);
80 uint8_t *_data_indexVector =
reinterpret_cast<uint8_t *
>(pointer);
82 auto rho_0 =
block->getData<field::GhostLayerField<double, 1>>(
rho_0ID);
87 WALBERLA_ASSERT_GREATER_EQUAL(0, -int_c(rho_0->nrOfGhostLayers()))
88 double *
RESTRICT _data_rho_0 = rho_0->dataAt(0, 0, 0, 0);
89 const int64_t _stride_rho_0_0 = int64_t(rho_0->xStride());
90 const int64_t _stride_rho_0_1 = int64_t(rho_0->yStride());
91 const int64_t _stride_rho_0_2 = int64_t(rho_0->zStride());
92 internal_8dfd6fd44211225f575bfd4fd9f8b4cc::reactionkernelindexed_1_double_precision_boundary_ReactionKernelIndexed_1_double_precision(_data_indexVector, _data_rho_0, _stride_rho_0_0, _stride_rho_0_1, _stride_rho_0_2, indexVectorSize, order_0, rate_coefficient, stoech_0);
#define FUNC_PREFIX
\file AdvectiveFluxKernel_double_precision.cpp \author pystencils
#define RESTRICT
\file AdvectiveFluxKernel_double_precision.h \author pystencils
void outer(IBlock *block)
void inner(IBlock *block)
static double * block(double *p, std::size_t index, std::size_t size)
static FUNC_PREFIX void reactionkernelindexed_1_double_precision_boundary_ReactionKernelIndexed_1_double_precision(uint8_t *RESTRICT const _data_indexVector, double *RESTRICT _data_rho_0, int64_t const _stride_rho_0_0, int64_t const _stride_rho_0_1, int64_t const _stride_rho_0_2, int32_t indexVectorSize, double order_0, double rate_coefficient, double stoech_0)
\file PackInfoPdfDoublePrecision.cpp \author pystencils