From f5a427a55bd562c0c0add8491289d2d1b022cee7 Mon Sep 17 00:00:00 2001 From: hnil Date: Wed, 15 Feb 2023 09:40:17 +0100 Subject: [PATCH] added timing block to most important parts --- opm/models/blackoil/blackoilintensivequantities.hh | 2 +- opm/models/discretization/common/tpfalinearizer.hh | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/opm/models/blackoil/blackoilintensivequantities.hh b/opm/models/blackoil/blackoilintensivequantities.hh index 1b46289ac..cd5ffc8c3 100644 --- a/opm/models/blackoil/blackoilintensivequantities.hh +++ b/opm/models/blackoil/blackoilintensivequantities.hh @@ -168,7 +168,7 @@ public: void update(const ElementContext& elemCtx, unsigned dofIdx, unsigned timeIdx) { ParentType::update(elemCtx, dofIdx, timeIdx); - + OPM_TIMEBLOCK_LOCAL(blackoilIntensiveQuanititiesUpdate); const auto& problem = elemCtx.problem(); const auto& priVars = elemCtx.primaryVars(dofIdx, timeIdx); const auto& linearizationType = problem.model().linearizer().getLinearizationType(); diff --git a/opm/models/discretization/common/tpfalinearizer.hh b/opm/models/discretization/common/tpfalinearizer.hh index be9f72eb7..aec616522 100644 --- a/opm/models/discretization/common/tpfalinearizer.hh +++ b/opm/models/discretization/common/tpfalinearizer.hh @@ -175,6 +175,7 @@ public: */ void linearizeDomain() { + OPM_TIMEBLOCK(linearizeDomain); // we defer the initialization of the Jacobian matrix until here because the // auxiliary modules usually assume the problem, model and grid to be fully // initialized... @@ -215,6 +216,7 @@ public: */ void linearizeAuxiliaryEquations() { + OPM_TIMEBLOCK(linearizeAuxilaryEquations); // flush possible local caches into matrix structure jacobian_->commit(); @@ -334,6 +336,7 @@ private: // Construct the BCRS matrix for the Jacobian of the residual function void createMatrix_() { + OPM_TIMEBLOCK(createMatrix); if (!neighborInfo_.empty()) { // It is ok to call this function multiple times, but it // should not do anything if already called. @@ -431,6 +434,7 @@ private: // Initialize the flows and flores sparse tables void createFlows_() { + OPM_TIMEBLOCK(createFlows); // If FLOWS/FLORES is set in any RPTRST in the schedule, then we initializate the sparse tables const bool anyFlows = simulator_().problem().eclWriter()->eclOutputModule().anyFlows(); const bool anyFlores = simulator_().problem().eclWriter()->eclOutputModule().anyFlores(); @@ -515,6 +519,7 @@ public: private: void linearize_() { + OPM_TIMEBLOCK(linearize); const bool well_local = true; resetSystem_(); unsigned numCells = model_().numTotalDof();