From 05aec72887e622eea3acbce69fdd71d530fbbc1e Mon Sep 17 00:00:00 2001 From: Antonin Portelli Date: Tue, 27 Nov 2018 18:46:43 +0000 Subject: [PATCH] Hadrons: application parameter for resilient I/O --- Hadrons/Application.cc | 3 +++ Hadrons/Application.hpp | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Hadrons/Application.cc b/Hadrons/Application.cc index 44579646..d04c9a50 100644 --- a/Hadrons/Application.cc +++ b/Hadrons/Application.cc @@ -108,6 +108,9 @@ void Application::run(void) HADRONS_ERROR(Definition, "run id is empty"); } LOG(Message) << "RUN ID '" << getPar().runId << "'" << std::endl; + BinaryIO::latticeWriteMaxRetry = getPar().parallelWriteMaxRetry; + LOG(Message) << "Attempt(s) for resilient parallel I/O: " + << BinaryIO::latticeWriteMaxRetry << std::endl; vm().setRunId(getPar().runId); vm().printContent(); env().printContent(); diff --git a/Hadrons/Application.hpp b/Hadrons/Application.hpp index 432fe757..3578c919 100644 --- a/Hadrons/Application.hpp +++ b/Hadrons/Application.hpp @@ -56,7 +56,9 @@ public: TrajRange, trajCounter, VirtualMachine::GeneticPar, genetic, std::string, runId, - std::string, graphFile); + std::string, graphFile, + int, parallelWriteMaxRetry); + GlobalPar(void): parallelWriteMaxRetry{-1} {} }; public: // constructors