diff --git a/src/gpu/GridGenerator/grid/GridBuilder/MultipleGridBuilder.cpp b/src/gpu/GridGenerator/grid/GridBuilder/MultipleGridBuilder.cpp index 21570f15d8adb01f18449f788e7a11288aa9c460..fb9f2624dac8ef88662ae631eaa04344915eb587 100644 --- a/src/gpu/GridGenerator/grid/GridBuilder/MultipleGridBuilder.cpp +++ b/src/gpu/GridGenerator/grid/GridBuilder/MultipleGridBuilder.cpp @@ -600,11 +600,11 @@ void MultipleGridBuilder::findCommunicationIndices(int direction, LbmOrGks lbmOr *logging::out << logging::Logger::INFO_HIGH << "Done with findCommunicationIndices()\n"; } -void MultipleGridBuilder::findFluidNodes(bool onlyBulk) +void MultipleGridBuilder::findFluidNodes(bool splitDomain) { *logging::out << logging::Logger::INFO_HIGH << "Start findFluidNodes()\n"; for (uint i = 0; i < grids.size(); i++) - grids[i]->findFluidNodeIndices(onlyBulk); + grids[i]->findFluidNodeIndices(splitDomain); *logging::out << logging::Logger::INFO_HIGH << "Done with findFluidNodes()\n"; } diff --git a/src/gpu/GridGenerator/grid/GridBuilder/MultipleGridBuilder.h b/src/gpu/GridGenerator/grid/GridBuilder/MultipleGridBuilder.h index ad72e1adb1125f00a4240c3828a869f36059a8ba..499f8542e915e0bab8d5e7ae1f753f16babded59 100644 --- a/src/gpu/GridGenerator/grid/GridBuilder/MultipleGridBuilder.h +++ b/src/gpu/GridGenerator/grid/GridBuilder/MultipleGridBuilder.h @@ -86,7 +86,7 @@ public: GRIDGENERATOR_EXPORT void findCommunicationIndices( int direction, LbmOrGks lbmOrGks ); // needed for CUDA Streams MultiGPU - void findFluidNodes(bool onlyBulk); + void findFluidNodes(bool splitDomain); }; #endif diff --git a/src/gpu/GridGenerator/grid/GridImp.cu b/src/gpu/GridGenerator/grid/GridImp.cu index 991ebc722b950e3922a6fc91ae2cbb8ea5d5265d..ee54a8b0298a8b01fd923f70e98e47ed0d25eea8 100644 --- a/src/gpu/GridGenerator/grid/GridImp.cu +++ b/src/gpu/GridGenerator/grid/GridImp.cu @@ -858,7 +858,7 @@ CUDA_HOST void GridImp::updateSparseIndices() sparseSize = size - removedNodes; } -CUDA_HOST void GridImp::findFluidNodeIndices(bool onlyBulk) +CUDA_HOST void GridImp::findFluidNodeIndices(bool splitDomain) { this->fluidNodeIndices.clear(); for (uint index = 0; index < this->size; index++) { @@ -867,10 +867,10 @@ CUDA_HOST void GridImp::findFluidNodeIndices(bool onlyBulk) continue; // + 1 for numbering shift between GridGenerator and VF_GPU - // When onlyBulk: push indices of fluid nodes in bulk to "fluidNodeIndices" and push indices of special fluid nodes (not in bulk) to fluidNodeIndicesBorder - // When not onlyBulk: push indices of all fluid nodes to "fluidNodeIndices" + // When splitDomain: push indices of fluid nodes in bulk to "fluidNodeIndices" and push indices of special fluid nodes (not in bulk) to fluidNodeIndicesBorder + // When not splitDomain: push indices of all fluid nodes to "fluidNodeIndices" if (this->field.isFluid(index)) { - if (onlyBulk) + if (splitDomain) if (this->field.isFluidNodeOfSpecialInterest(index)) this->fluidNodeIndicesBorder.push_back((uint)sparseIndex + 1); else diff --git a/src/gpu/GridGenerator/grid/GridImp.h b/src/gpu/GridGenerator/grid/GridImp.h index ffdb606659a27d2f5491f978cf122019ceefea01..fb7ab02a0e59a2677265732f5653f9b1fd1a52c3 100644 --- a/src/gpu/GridGenerator/grid/GridImp.h +++ b/src/gpu/GridGenerator/grid/GridImp.h @@ -316,7 +316,7 @@ public: void repairCommunicationInices(int direction) override; - void findFluidNodeIndices(bool onlyBulk) override; + void findFluidNodeIndices(bool splitDomain) override; uint getNumberOfFluidNodes() const override; CUDA_HOST void getFluidNodeIndices(uint *fluidNodeIndices) const override; diff --git a/src/gpu/VirtualFluids_GPU/LBM/Simulation.cpp b/src/gpu/VirtualFluids_GPU/LBM/Simulation.cpp index 0f91ad9605f25f7d34653ea30c116f7e2a52c6fd..34c45493d7ce7e8606c1e96a97e770ba57d1e152 100644 --- a/src/gpu/VirtualFluids_GPU/LBM/Simulation.cpp +++ b/src/gpu/VirtualFluids_GPU/LBM/Simulation.cpp @@ -1161,7 +1161,7 @@ void Simulation::free() para->terminateStreams(); //CudaFreeHostMemory - for (int lev = para->getCoarse(); lev <= para->getFine(); lev++) + for (int lev = para->getCoarse(); lev <= para->getFine(); lev++) { //para->cudaFreeFull(lev); cudaManager->cudaFreeCoord(lev);