From 7a818ede0d471365083ba275a6383380b80c3215 Mon Sep 17 00:00:00 2001 From: Anna Wellmann <a.wellmann@tu-braunschweig.de> Date: Mon, 11 Oct 2021 19:59:10 +0200 Subject: [PATCH] Remove unused code from FileWriter --- .../VirtualFluids_GPU/Output/FileWriter.cpp | 18 ++++++------------ src/gpu/VirtualFluids_GPU/Output/FileWriter.h | 1 - 2 files changed, 6 insertions(+), 13 deletions(-) diff --git a/src/gpu/VirtualFluids_GPU/Output/FileWriter.cpp b/src/gpu/VirtualFluids_GPU/Output/FileWriter.cpp index 807230354..0fa9add46 100644 --- a/src/gpu/VirtualFluids_GPU/Output/FileWriter.cpp +++ b/src/gpu/VirtualFluids_GPU/Output/FileWriter.cpp @@ -181,8 +181,8 @@ void FileWriter::writeUnstrucuredGridLT(std::shared_ptr<Parameter> para, int lev nodedatanames.push_back("vx2"); nodedatanames.push_back("vx3"); nodedatanames.push_back("geo"); - nodedatanames.push_back("sendNodes"); - nodedatanames.push_back("sparseIndex"); + //nodedatanames.push_back("sendNodes"); + //nodedatanames.push_back("sparseIndex"); unsigned int number1, number2, number3, number4, number5, number6, number7, number8; uint dn1, dn2, dn3, dn4, dn5, dn6, dn7, dn8; bool neighborsAreFluid; @@ -229,10 +229,10 @@ void FileWriter::writeUnstrucuredGridLT(std::shared_ptr<Parameter> para, int lev nodedata[4][dn1] = (double)para->getParH(level)->vz_SP[pos] * (double)para->getVelocityRatio(); nodedata[5][dn1] = (double)para->getParH(level)->geoSP[pos]; - int sendNode = 0; // 0 - not a sendNode; 1 - sendNode; 2 - sendNode in communication after fine to coarse - testForSendNodeY(para, level, pos, sendNode); // slow, doesn't need to be done multiple times --> use for debugging only! - nodedata[6][dn1] = (double) sendNode; - nodedata[7][dn1] = (double) pos; + //int sendNode = 0; // 0 - not a sendNode; 1 - sendNode; 2 - sendNode in communication after fine to coarse + // testForSendNodeY(para, level, pos, sendNode); // slow and should not be done multiple times --> use for debugging only! + //nodedata[6][dn1] = (double) sendNode; + // nodedata[7][dn1] = (double) pos; ////////////////////////////////////////////////////////////////////////// number2 = para->getParH(level)->neighborX_SP[number1]; number3 = para->getParH(level)->neighborY_SP[number2]; @@ -283,12 +283,6 @@ void FileWriter::testForSendNodeY(std::shared_ptr<Parameter> ¶, int level, u ¶->getParH(level)->sendProcessNeighborsAfterFtoCY); } -void FileWriter::testForRecvNodeY(std::shared_ptr<Parameter> ¶, int level, unsigned int pos, int &sendNode) -{ - testForCommunicationNode(para, level, pos, sendNode, ¶->getParH(level)->recvProcessNeighborY, - ¶->getParH(level)->recvProcessNeighborsAfterFtoCY); -} - void FileWriter::testForCommunicationNode(std::shared_ptr<Parameter> ¶, int level, unsigned int pos, int &sendNode, std::vector<PN27> *sendOrRecvProcessNeighbor, std::vector<PN27> *sendOrRecvProcessNeighborAfterFtoC) diff --git a/src/gpu/VirtualFluids_GPU/Output/FileWriter.h b/src/gpu/VirtualFluids_GPU/Output/FileWriter.h index 241e3b007..28286034a 100644 --- a/src/gpu/VirtualFluids_GPU/Output/FileWriter.h +++ b/src/gpu/VirtualFluids_GPU/Output/FileWriter.h @@ -27,7 +27,6 @@ private: void VIRTUALFLUIDS_GPU_EXPORT writeUnstrucuredGridLT(std::shared_ptr<Parameter> para, int level, std::vector<std::string> &fname); void testForSendNodeY(std::shared_ptr<Parameter> ¶, int level, unsigned int pos, int &sendNode); - void testForRecvNodeY(std::shared_ptr<Parameter> ¶, int level, unsigned int pos, int &sendNode); void testForCommunicationNode(std::shared_ptr<Parameter> ¶, int level, unsigned int pos, int &sendNode, std::vector<PN27> *sendOrRecvProcessNeighbor, std::vector<PN27> *sendOrRecvProcessNeighborAfterFtoC); -- GitLab