43 for (int64_t ctr_2 = 0; ctr_2 < _size_field_2; ctr_2 += 1) {
44 for (int64_t ctr_1 = 0; ctr_1 < _size_field_1; ctr_1 += 1) {
45 for (int64_t ctr_0 = 0; ctr_0 < _size_field_0; ctr_0 += 1) {
46 _data_buffer[3 * _size_field_0 * _size_field_1 * ctr_2 + 3 * _size_field_0 * ctr_1 + 3 * ctr_0] = _data_field[_stride_field_0 * ctr_0 + _stride_field_1 * ctr_1 + _stride_field_2 * ctr_2];
47 _data_buffer[3 * _size_field_0 * _size_field_1 * ctr_2 + 3 * _size_field_0 * ctr_1 + 3 * ctr_0 + 1] = _data_field[_stride_field_0 * ctr_0 + _stride_field_1 * ctr_1 + _stride_field_2 * ctr_2 + _stride_field_3];
48 _data_buffer[3 * _size_field_0 * _size_field_1 * ctr_2 + 3 * _size_field_0 * ctr_1 + 3 * ctr_0 + 2] = _data_field[_stride_field_0 * ctr_0 + _stride_field_1 * ctr_1 + _stride_field_2 * ctr_2 + 2 * _stride_field_3];
57 for (int64_t ctr_2 = 0; ctr_2 < _size_field_2; ctr_2 += 1) {
58 for (int64_t ctr_1 = 0; ctr_1 < _size_field_1; ctr_1 += 1) {
59 for (int64_t ctr_0 = 0; ctr_0 < _size_field_0; ctr_0 += 1) {
60 _data_field[_stride_field_0 * ctr_0 + _stride_field_1 * ctr_1 + _stride_field_2 * ctr_2] = _data_buffer[3 * _size_field_0 * _size_field_1 * ctr_2 + 3 * _size_field_0 * ctr_1 + 3 * ctr_0];
61 _data_field[_stride_field_0 * ctr_0 + _stride_field_1 * ctr_1 + _stride_field_2 * ctr_2 + _stride_field_3] = _data_buffer[3 * _size_field_0 * _size_field_1 * ctr_2 + 3 * _size_field_0 * ctr_1 + 3 * ctr_0 + 1];
62 _data_field[_stride_field_0 * ctr_0 + _stride_field_1 * ctr_1 + _stride_field_2 * ctr_2 + 2 * _stride_field_3] = _data_buffer[3 * _size_field_0 * _size_field_1 * ctr_2 + 3 * _size_field_0 * ctr_1 + 3 * ctr_0 + 2];
70 float *buffer =
reinterpret_cast<float *
>(byte_buffer);
72 auto field =
block->getData<field::GhostLayerField<float, 3>>(fieldID);
75 field->getSliceBeforeGhostLayer(dir, ci, 1,
false);
97 float *
RESTRICT _data_buffer = buffer;
98 WALBERLA_ASSERT_GREATER_EQUAL(ci.xMin(), -int_c(field->nrOfGhostLayers()))
99 WALBERLA_ASSERT_GREATER_EQUAL(ci.yMin(), -int_c(field->nrOfGhostLayers()))
100 WALBERLA_ASSERT_GREATER_EQUAL(ci.zMin(), -int_c(field->nrOfGhostLayers()))
101 float *
RESTRICT const _data_field = field->dataAt(ci.xMin(), ci.yMin(), ci.zMin(), 0);
102 WALBERLA_ASSERT_GREATER_EQUAL(field->xSizeWithGhostLayer(), int64_t(int64_c(ci.xSize()) + 0))
103 const int64_t _size_field_0 = int64_t(int64_c(ci.xSize()) + 0);
104 WALBERLA_ASSERT_GREATER_EQUAL(field->ySizeWithGhostLayer(), int64_t(int64_c(ci.ySize()) + 0))
105 const int64_t _size_field_1 = int64_t(int64_c(ci.ySize()) + 0);
106 WALBERLA_ASSERT_GREATER_EQUAL(field->zSizeWithGhostLayer(), int64_t(int64_c(ci.zSize()) + 0))
107 const int64_t _size_field_2 = int64_t(int64_c(ci.zSize()) + 0);
108 const int64_t _stride_field_0 = int64_t(field->xStride());
109 const int64_t _stride_field_1 = int64_t(field->yStride());
110 const int64_t _stride_field_2 = int64_t(field->zStride());
111 const int64_t _stride_field_3 = int64_t(1 * int64_t(field->fStride()));
117 WALBERLA_ASSERT(
false);
122 float *buffer =
reinterpret_cast<float *
>(byte_buffer);
124 auto field =
block->getData<field::GhostLayerField<float, 3>>(fieldID);
127 field->getGhostRegion(dir, ci, 1,
false);
128 auto communciationDirection = stencil::inverseDir[dir];
130 switch (communciationDirection) {
150 float *
RESTRICT const _data_buffer = buffer;
151 WALBERLA_ASSERT_GREATER_EQUAL(ci.xMin(), -int_c(field->nrOfGhostLayers()))
152 WALBERLA_ASSERT_GREATER_EQUAL(ci.yMin(), -int_c(field->nrOfGhostLayers()))
153 WALBERLA_ASSERT_GREATER_EQUAL(ci.zMin(), -int_c(field->nrOfGhostLayers()))
154 float *
RESTRICT _data_field = field->dataAt(ci.xMin(), ci.yMin(), ci.zMin(), 0);
155 WALBERLA_ASSERT_GREATER_EQUAL(field->xSizeWithGhostLayer(), int64_t(int64_c(ci.xSize()) + 0))
156 const int64_t _size_field_0 = int64_t(int64_c(ci.xSize()) + 0);
157 WALBERLA_ASSERT_GREATER_EQUAL(field->ySizeWithGhostLayer(), int64_t(int64_c(ci.ySize()) + 0))
158 const int64_t _size_field_1 = int64_t(int64_c(ci.ySize()) + 0);
159 WALBERLA_ASSERT_GREATER_EQUAL(field->zSizeWithGhostLayer(), int64_t(int64_c(ci.zSize()) + 0))
160 const int64_t _size_field_2 = int64_t(int64_c(ci.zSize()) + 0);
161 const int64_t _stride_field_0 = int64_t(field->xStride());
162 const int64_t _stride_field_1 = int64_t(field->yStride());
163 const int64_t _stride_field_2 = int64_t(field->zStride());
164 const int64_t _stride_field_3 = int64_t(1 * int64_t(field->fStride()));
170 WALBERLA_ASSERT(
false);
175 auto field =
block->getData<field::GhostLayerField<float, 3>>(fieldID);
178 field->getGhostRegion(dir, ci, 1,
false);
180 uint_t elementsPerCell = uint_t{0u};
202 elementsPerCell = uint_t{3u};
206 elementsPerCell = uint_t{0u};
208 return ci.numCells() * elementsPerCell *
sizeof(float);
static FUNC_PREFIX void pack_SW_BW_W_TW_NW_BS_S_TS_B_C_T_BN_N_TN_SE_BE_E_TE_NE(double *RESTRICT _data_buffer, double *RESTRICT const _data_field, int64_t const _size_field_0, int64_t const _size_field_1, int64_t const _size_field_2, int64_t const _stride_field_0, int64_t const _stride_field_1, int64_t const _stride_field_2, int64_t const _stride_field_3)
static FUNC_PREFIX void unpack_SW_BW_W_TW_NW_BS_S_TS_B_C_T_BN_N_TN_SE_BE_E_TE_NE(double *RESTRICT const _data_buffer, double *RESTRICT _data_field, int64_t const _size_field_0, int64_t const _size_field_1, int64_t const _size_field_2, int64_t const _stride_field_0, int64_t const _stride_field_1, int64_t const _stride_field_2, int64_t const _stride_field_3)