| 1 |
// @HEADER |
| 2 |
// ***************************************************************************** |
| 3 |
// ShyLU: Scalable Hybrid LU Preconditioner and Solver |
| 4 |
// |
| 5 |
// Copyright 2011 NTESS and the ShyLU contributors. |
| 6 |
// SPDX-License-Identifier: BSD-3-Clause |
| 7 |
// ***************************************************************************** |
| 8 |
// @HEADER |
| 9 |
|
| 10 |
#include <ShyLU_DDFROSch_config.h> |
| 11 |
|
| 12 |
#include <mpi.h> |
| 13 |
|
| 14 |
#include <Teuchos_GlobalMPISession.hpp> |
| 15 |
#include <Teuchos_CommandLineProcessor.hpp> |
| 16 |
#include <Teuchos_XMLParameterListCoreHelpers.hpp> |
| 17 |
#include <Teuchos_StackedTimer.hpp> |
| 18 |
|
| 19 |
// Galeri::Xpetra |
| 20 |
#include "Galeri_XpetraProblemFactory.hpp" |
| 21 |
#include "Galeri_XpetraMatrixTypes.hpp" |
| 22 |
#include "Galeri_XpetraParameters.hpp" |
| 23 |
#include "Galeri_XpetraUtils.hpp" |
| 24 |
#include "Galeri_XpetraMaps.hpp" |
| 25 |
|
| 26 |
// Thyra includes |
| 27 |
#include <Thyra_LinearOpWithSolveBase.hpp> |
| 28 |
#include <Thyra_VectorBase.hpp> |
| 29 |
#include <Thyra_SolveSupportTypes.hpp> |
| 30 |
#include <Thyra_LinearOpWithSolveBase.hpp> |
| 31 |
#include <Thyra_LinearOpWithSolveFactoryHelpers.hpp> |
| 32 |
#include <Thyra_TpetraLinearOp.hpp> |
| 33 |
#include <Thyra_TpetraMultiVector.hpp> |
| 34 |
#include <Thyra_TpetraVector.hpp> |
| 35 |
#include <Thyra_TpetraThyraWrappers.hpp> |
| 36 |
#include <Thyra_VectorBase.hpp> |
| 37 |
#include <Thyra_VectorStdOps.hpp> |
| 38 |
#ifdef HAVE_SHYLU_DDFROSCH_EPETRA |
| 39 |
#include <Thyra_EpetraLinearOp.hpp> |
| 40 |
#endif |
| 41 |
#include <Thyra_VectorSpaceBase_def.hpp> |
| 42 |
#include <Thyra_VectorSpaceBase_decl.hpp> |
| 43 |
|
| 44 |
// Stratimikos includes |
| 45 |
#include <Stratimikos_FROSch_def.hpp> |
| 46 |
|
| 47 |
#include <Tpetra_Core.hpp> |
| 48 |
|
| 49 |
// Xpetra include |
| 50 |
#include <Xpetra_CrsMatrixWrap.hpp> |
| 51 |
#include <Xpetra_DefaultPlatform.hpp> |
| 52 |
#ifdef HAVE_SHYLU_DDFROSCH_EPETRA |
| 53 |
#include <Xpetra_EpetraCrsMatrix.hpp> |
| 54 |
#endif |
| 55 |
#include <Xpetra_Parameters.hpp> |
| 56 |
|
| 57 |
// FROSCH thyra includes |
| 58 |
#include "Thyra_FROSchLinearOp_def.hpp" |
| 59 |
#include "Thyra_FROSchFactory_def.hpp" |
| 60 |
#include <FROSch_Tools_def.hpp> |
| 61 |
|
| 62 |
|
| 63 |
using UN = unsigned; |
| 64 |
using SC = double; |
| 65 |
using LO = int; |
| 66 |
using GO = FROSch::DefaultGlobalOrdinal; |
| 67 |
using NO = Tpetra::KokkosClassic::DefaultNode::DefaultNodeType; |
| 68 |
|
| 69 |
using namespace std; |
| 70 |
using namespace Teuchos; |
| 71 |
using namespace Xpetra; |
| 72 |
using namespace FROSch; |
| 73 |
using namespace Thyra; |
| 74 |
|
| 75 |
int main(int argc, char *argv[]) |
| 76 |
{ |
| 77 |
oblackholestream blackhole; |
| 78 |
GlobalMPISession mpiSession(&argc,&argv,&blackhole); |
| 79 |
|
| 80 |
RCP<const Comm<int> > CommWorld = DefaultPlatform::getDefaultPlatform().getComm(); |
| 81 |
|
| 82 |
CommandLineProcessor My_CLP; |
| 83 |
|
| 84 |
RCP<FancyOStream> out = VerboseObjectBase::getDefaultOStream(); |
| 85 |
|
| 86 |
int M = 3; |
| 87 |
My_CLP.setOption("M",&M,"H / h."); |
| 88 |
int Dimension = 2; |
| 89 |
My_CLP.setOption("DIM",&Dimension,"Dimension."); |
| 90 |
int Overlap = 0; |
| 91 |
My_CLP.setOption("O",&Overlap,"Overlap."); |
| 92 |
int NumberOfBlocks = 1; |
| 93 |
My_CLP.setOption("NB",&NumberOfBlocks,"Number of blocks."); |
| 94 |
int DofsPerNode = 1; |
| 95 |
My_CLP.setOption("DPN",&DofsPerNode,"Dofs per node."); |
| 96 |
int DOFOrdering = 0; |
| 97 |
My_CLP.setOption("ORD",&DOFOrdering,"Dofs ordering (NodeWise=0, DimensionWise=1, Custom=2)."); |
| 98 |
string xmlFile = "ParameterList.xml"; |
| 99 |
My_CLP.setOption("PLIST",&xmlFile,"File name of the parameter list."); |
| 100 |
bool useepetra = false; |
| 101 |
My_CLP.setOption("USEEPETRA","USETPETRA",&useepetra,"Use Epetra infrastructure for the linear algebra."); |
| 102 |
|
| 103 |
My_CLP.recogniseAllOptions(true); |
| 104 |
My_CLP.throwExceptions(false); |
| 105 |
CommandLineProcessor::EParseCommandLineReturn parseReturn = My_CLP.parse(argc,argv); |
| 106 |
if (parseReturn == CommandLineProcessor::PARSE_HELP_PRINTED) { |
| 107 |
return(EXIT_SUCCESS); |
| 108 |
} |
| 109 |
|
| 110 |
CommWorld->barrier(); |
| 111 |
RCP<StackedTimer> stackedTimer = rcp(new StackedTimer("Overlap Test")); |
| 112 |
TimeMonitor::setStackedTimer(stackedTimer); |
| 113 |
|
| 114 |
int N = 0; |
| 115 |
int color=1; |
| 116 |
if (Dimension == 2) { |
| 117 |
N = (int) (pow(CommWorld->getSize(),1/2.) + 100*numeric_limits<double>::epsilon()); // 1/H |
| 118 |
if (CommWorld->getRank()<N*N) { |
| 119 |
color=0; |
| 120 |
} |
| 121 |
} else if (Dimension == 3) { |
| 122 |
N = (int) (pow(CommWorld->getSize(),1/3.) + 100*numeric_limits<double>::epsilon()); // 1/H |
| 123 |
if (CommWorld->getRank()<N*N*N) { |
| 124 |
color=0; |
| 125 |
} |
| 126 |
} else { |
| 127 |
assert(false); |
| 128 |
} |
| 129 |
|
| 130 |
UnderlyingLib xpetraLib = UseTpetra; |
| 131 |
if (useepetra) { |
| 132 |
xpetraLib = UseEpetra; |
| 133 |
} else { |
| 134 |
xpetraLib = UseTpetra; |
| 135 |
} |
| 136 |
|
| 137 |
RCP<const Comm<int> > Comm = CommWorld->split(color,CommWorld->getRank()); |
| 138 |
|
| 139 |
if (color==0) { |
| 140 |
|
| 141 |
RCP<ParameterList> parameterList = getParametersFromXmlFile(xmlFile); |
| 142 |
|
| 143 |
ArrayRCP<RCP<Matrix<SC,LO,GO,NO> > > K(NumberOfBlocks); |
| 144 |
ArrayRCP<RCP<Map<LO,GO,NO> > > RepeatedMaps(NumberOfBlocks); |
| 145 |
ArrayRCP<RCP<MultiVector<SC,LO,GO,NO> > > Coordinates(NumberOfBlocks); |
| 146 |
ArrayRCP<UN> dofsPerNodeVector(NumberOfBlocks); |
| 147 |
|
| 148 |
const GO INVALID = Teuchos::OrdinalTraits<GO>::invalid(); |
| 149 |
for (UN block=0; block<(UN) NumberOfBlocks; block++) { |
| 150 |
Comm->barrier(); if (Comm->getRank()==0) cout << "###################\n# Assembly Block " << block << " #\n###################\n" << endl; |
| 151 |
|
| 152 |
dofsPerNodeVector[block] = (UN) max(int(DofsPerNode-block),1); |
| 153 |
|
| 154 |
ParameterList GaleriList; |
| 155 |
GaleriList.set("nx", GO(N*(M+block))); |
| 156 |
GaleriList.set("ny", GO(N*(M+block))); |
| 157 |
GaleriList.set("nz", GO(N*(M+block))); |
| 158 |
GaleriList.set("mx", GO(N)); |
| 159 |
GaleriList.set("my", GO(N)); |
| 160 |
GaleriList.set("mz", GO(N)); |
| 161 |
|
| 162 |
RCP<const Map<LO,GO,NO> > UniqueMapTmp; |
| 163 |
RCP<MultiVector<SC,LO,GO,NO> > CoordinatesTmp; |
| 164 |
RCP<Matrix<SC,LO,GO,NO> > KTmp; |
| 165 |
if (Dimension==2) { |
| 166 |
UniqueMapTmp = Galeri::Xpetra::CreateMap<LO,GO,NO>(xpetraLib,"Cartesian2D",Comm,GaleriList); // RCP<FancyOStream> fancy = fancyOStream(rcpFromRef(cout)); nodeMap->describe(*fancy,VERB_EXTREME); |
| 167 |
CoordinatesTmp = Galeri::Xpetra::Utils::CreateCartesianCoordinates<SC,LO,GO,Map<LO,GO,NO>,MultiVector<SC,LO,GO,NO> >("2D",UniqueMapTmp,GaleriList); |
| 168 |
RCP<Galeri::Xpetra::Problem<Map<LO,GO,NO>,CrsMatrixWrap<SC,LO,GO,NO>,MultiVector<SC,LO,GO,NO> > > Problem = Galeri::Xpetra::BuildProblem<SC,LO,GO,Map<LO,GO,NO>,CrsMatrixWrap<SC,LO,GO,NO>,MultiVector<SC,LO,GO,NO> >("Laplace2D",UniqueMapTmp,GaleriList); |
| 169 |
KTmp = Problem->BuildMatrix(); |
| 170 |
} else if (Dimension==3) { |
| 171 |
UniqueMapTmp = Galeri::Xpetra::CreateMap<LO,GO,NO>(xpetraLib,"Cartesian3D",Comm,GaleriList); // RCP<FancyOStream> fancy = fancyOStream(rcpFromRef(cout)); nodeMap->describe(*fancy,VERB_EXTREME); |
| 172 |
CoordinatesTmp = Galeri::Xpetra::Utils::CreateCartesianCoordinates<SC,LO,GO,Map<LO,GO,NO>,MultiVector<SC,LO,GO,NO> >("3D",UniqueMapTmp,GaleriList); |
| 173 |
RCP<Galeri::Xpetra::Problem<Map<LO,GO,NO>,CrsMatrixWrap<SC,LO,GO,NO>,MultiVector<SC,LO,GO,NO> > > Problem = Galeri::Xpetra::BuildProblem<SC,LO,GO,Map<LO,GO,NO>,CrsMatrixWrap<SC,LO,GO,NO>,MultiVector<SC,LO,GO,NO> >("Laplace3D",UniqueMapTmp,GaleriList); |
| 174 |
KTmp = Problem->BuildMatrix(); |
| 175 |
} |
| 176 |
|
| 177 |
RCP<Map<LO,GO,NO> > UniqueMap; |
| 178 |
|
| 179 |
if (DOFOrdering == 0) { |
| 180 |
Array<GO> uniqueMapArray(dofsPerNodeVector[block]*UniqueMapTmp->getLocalNumElements()); |
| 181 |
for (LO i=0; i<(LO) UniqueMapTmp->getLocalNumElements(); i++) { |
| 182 |
for (UN j=0; j<dofsPerNodeVector[block]; j++) { |
| 183 |
uniqueMapArray[dofsPerNodeVector[block]*i+j] = dofsPerNodeVector[block]*UniqueMapTmp->getGlobalElement(i)+j; |
| 184 |
} |
| 185 |
} |
| 186 |
|
| 187 |
UniqueMap = MapFactory<LO,GO,NO>::Build(xpetraLib,INVALID,uniqueMapArray(),0,Comm); |
| 188 |
K[block] = MatrixFactory<SC,LO,GO,NO>::Build(UniqueMap,KTmp->getGlobalMaxNumRowEntries()); |
| 189 |
for (LO i=0; i<(LO) UniqueMapTmp->getLocalNumElements(); i++) { |
| 190 |
ArrayView<const LO> indices; |
| 191 |
ArrayView<const SC> values; |
| 192 |
KTmp->getLocalRowView(i,indices,values); |
| 193 |
|
| 194 |
for (UN j=0; j<dofsPerNodeVector[block]; j++) { |
| 195 |
Array<GO> indicesArray(indices.size()); |
| 196 |
for (LO k=0; k<indices.size(); k++) { |
| 197 |
indicesArray[k] = dofsPerNodeVector[block]*KTmp->getColMap()->getGlobalElement(indices[k])+j; |
| 198 |
} |
| 199 |
K[block]->insertGlobalValues(dofsPerNodeVector[block]*KTmp->getRowMap()->getGlobalElement(i)+j,indicesArray(),values); |
| 200 |
} |
| 201 |
} |
| 202 |
K[block]->fillComplete(); |
| 203 |
} else if (DOFOrdering == 1) { |
| 204 |
Array<GO> uniqueMapArray(dofsPerNodeVector[block]*UniqueMapTmp->getLocalNumElements()); |
| 205 |
for (LO i=0; i<(LO) UniqueMapTmp->getLocalNumElements(); i++) { |
| 206 |
for (UN j=0; j<dofsPerNodeVector[block]; j++) { |
| 207 |
uniqueMapArray[i+UniqueMapTmp->getLocalNumElements()*j] = UniqueMapTmp->getGlobalElement(i)+(UniqueMapTmp->getMaxAllGlobalIndex()+1)*j; |
| 208 |
} |
| 209 |
} |
| 210 |
|
| 211 |
UniqueMap = MapFactory<LO,GO,NO>::Build(xpetraLib,INVALID,uniqueMapArray(),0,Comm); |
| 212 |
K[block] = MatrixFactory<SC,LO,GO,NO>::Build(UniqueMap,KTmp->getGlobalMaxNumRowEntries()); |
| 213 |
for (LO i=0; i<(LO) UniqueMapTmp->getLocalNumElements(); i++) { |
| 214 |
ArrayView<const LO> indices; |
| 215 |
ArrayView<const SC> values; |
| 216 |
KTmp->getLocalRowView(i,indices,values); |
| 217 |
|
| 218 |
for (UN j=0; j<dofsPerNodeVector[block]; j++) { |
| 219 |
Array<GO> indicesArray(indices.size()); |
| 220 |
for (LO k=0; k<indices.size(); k++) { |
| 221 |
indicesArray[k] = KTmp->getColMap()->getGlobalElement(indices[k])+(KTmp->getColMap()->getMaxAllGlobalIndex()+1)*j; |
| 222 |
} |
| 223 |
K[block]->insertGlobalValues(UniqueMapTmp->getGlobalElement(i)+(UniqueMapTmp->getMaxAllGlobalIndex()+1)*j,indicesArray(),values); |
| 224 |
} |
| 225 |
} |
| 226 |
K[block]->fillComplete(); |
| 227 |
} else if (DOFOrdering == 2) { |
| 228 |
assert(false); // TODO: Andere Sortierung implementieren |
| 229 |
} else { |
| 230 |
assert(false); |
| 231 |
} |
| 232 |
|
| 233 |
RepeatedMaps[block] = BuildRepeatedMapNonConst<LO,GO,NO>(K[block]->getCrsGraph()); //RCP<FancyOStream> fancy = fancyOStream(rcpFromRef(cout)); RepeatedMaps[block]->describe(*fancy,VERB_EXTREME); |
| 234 |
} |
| 235 |
|
| 236 |
Comm->barrier(); if (Comm->getRank()==0) cout << "##############################\n# Assembly Monolithic System #\n##############################\n" << endl; |
| 237 |
|
| 238 |
RCP<Matrix<SC,LO,GO,NO> > KMonolithic; |
| 239 |
if (NumberOfBlocks>1) { |
| 240 |
|
| 241 |
Array<GO> uniqueMapArray(0); |
| 242 |
GO tmpOffset = 0; |
| 243 |
for (UN block=0; block<(UN) NumberOfBlocks; block++) { |
| 244 |
ArrayView<const GO> tmpgetGlobalElements = K[block]->getMap()->getLocalElementList(); |
| 245 |
for (LO i=0; i<tmpgetGlobalElements.size(); i++) { |
| 246 |
uniqueMapArray.push_back(tmpgetGlobalElements[i]+tmpOffset); |
| 247 |
} |
| 248 |
tmpOffset += K[block]->getMap()->getMaxAllGlobalIndex()+1; |
| 249 |
} |
| 250 |
RCP<Map<LO,GO,NO> > UniqueMapMonolithic = MapFactory<LO,GO,NO>::Build(xpetraLib,INVALID,uniqueMapArray(),0,Comm); |
| 251 |
|
| 252 |
tmpOffset = 0; |
| 253 |
KMonolithic = MatrixFactory<SC,LO,GO,NO>::Build(UniqueMapMonolithic,K[0]->getGlobalMaxNumRowEntries()); |
| 254 |
for (UN block=0; block<(UN) NumberOfBlocks; block++) { |
| 255 |
for (LO i=0; i<(LO) K[block]->getLocalNumRows(); i++) { |
| 256 |
ArrayView<const LO> indices; |
| 257 |
ArrayView<const SC> values; |
| 258 |
K[block]->getLocalRowView(i,indices,values); |
| 259 |
Array<GO> indicesGlobal(indices.size()); |
| 260 |
for (UN j=0; j<indices.size(); j++) { |
| 261 |
indicesGlobal[j] = K[block]->getColMap()->getGlobalElement(indices[j])+tmpOffset; |
| 262 |
} |
| 263 |
KMonolithic->insertGlobalValues(K[block]->getMap()->getGlobalElement(i)+tmpOffset,indicesGlobal(),values); |
| 264 |
} |
| 265 |
tmpOffset += K[block]->getMap()->getMaxAllGlobalIndex()+1; |
| 266 |
} |
| 267 |
KMonolithic->fillComplete(); |
| 268 |
} else if (NumberOfBlocks==1) { |
| 269 |
KMonolithic = K[0]; |
| 270 |
} else { |
| 271 |
assert(false); |
| 272 |
} |
| 273 |
|
| 274 |
RCP<MultiVector<SC,LO,GO,NO> > xSolution = MultiVectorFactory<SC,LO,GO,NO>::Build(KMonolithic->getMap(),1); |
| 275 |
RCP<MultiVector<SC,LO,GO,NO> > xRightHandSide = MultiVectorFactory<SC,LO,GO,NO>::Build(KMonolithic->getMap(),1); |
| 276 |
|
| 277 |
xSolution->putScalar(ScalarTraits<SC>::zero()); |
| 278 |
xRightHandSide->putScalar(ScalarTraits<SC>::one()); |
| 279 |
|
| 280 |
CrsMatrixWrap<SC,LO,GO,NO>& crsWrapK = dynamic_cast<CrsMatrixWrap<SC,LO,GO,NO>&>(*KMonolithic); |
| 281 |
RCP<const LinearOpBase<SC> > K_thyra = ThyraUtils<SC,LO,GO,NO>::toThyra(crsWrapK.getCrsMatrix()); |
| 282 |
RCP<MultiVectorBase<SC> >thyraX = rcp_const_cast<MultiVectorBase<SC> >(ThyraUtils<SC,LO,GO,NO>::toThyraMultiVector(xSolution)); |
| 283 |
RCP<const MultiVectorBase<SC> >thyraB = ThyraUtils<SC,LO,GO,NO>::toThyraMultiVector(xRightHandSide); |
| 284 |
|
| 285 |
//-----------Set Coordinates and RepMap in ParameterList-------------------------- |
| 286 |
RCP<ParameterList> plList = sublist(parameterList,"Preconditioner Types"); |
| 287 |
sublist(plList,"FROSch")->set("Dimension",Dimension); |
| 288 |
sublist(plList,"FROSch")->set("Overlap",Overlap); |
| 289 |
if (NumberOfBlocks>1) { |
| 290 |
sublist(plList,"FROSch")->set("Repeated Map Vector",RepeatedMaps); |
| 291 |
|
| 292 |
ArrayRCP<DofOrdering> dofOrderings(NumberOfBlocks); |
| 293 |
if (DOFOrdering == 0) { |
| 294 |
for (UN block=0; block<(UN) NumberOfBlocks; block++) { |
| 295 |
dofOrderings[block] = NodeWise; |
| 296 |
} |
| 297 |
} else if (DOFOrdering == 1) { |
| 298 |
for (UN block=0; block<(UN) NumberOfBlocks; block++) { |
| 299 |
dofOrderings[block] = DimensionWise; |
| 300 |
} |
| 301 |
} else { |
| 302 |
assert(false); |
| 303 |
} |
| 304 |
|
| 305 |
sublist(plList,"FROSch")->set("DofOrdering Vector",dofOrderings); |
| 306 |
sublist(plList,"FROSch")->set("DofsPerNode Vector",dofsPerNodeVector); |
| 307 |
} else if (NumberOfBlocks==1) { |
| 308 |
sublist(plList,"FROSch")->set("Repeated Map",RepeatedMaps[0]); |
| 309 |
// sublist(plList,"FROSch")->set("Coordinates List",Coordinates[0]); // Does not work yet... |
| 310 |
|
| 311 |
string DofOrderingString; |
| 312 |
if (DOFOrdering == 0) { |
| 313 |
DofOrderingString = "NodeWise"; |
| 314 |
} else if (DOFOrdering == 1) { |
| 315 |
DofOrderingString = "DimensionWise"; |
| 316 |
} else { |
| 317 |
assert(false); |
| 318 |
} |
| 319 |
sublist(plList,"FROSch")->set("DofOrdering",DofOrderingString); |
| 320 |
sublist(plList,"FROSch")->set("DofsPerNode",DofsPerNode); |
| 321 |
} else { |
| 322 |
assert(false); |
| 323 |
} |
| 324 |
|
| 325 |
Comm->barrier(); |
| 326 |
if (Comm->getRank()==0) { |
| 327 |
cout << "##################\n# Parameter List #\n##################" << endl; |
| 328 |
parameterList->print(cout); |
| 329 |
cout << endl; |
| 330 |
} |
| 331 |
|
| 332 |
Comm->barrier(); if (Comm->getRank()==0) cout << "###################################\n# Stratimikos LinearSolverBuilder #\n###################################\n" << endl; |
| 333 |
Stratimikos::LinearSolverBuilder<SC> linearSolverBuilder; |
| 334 |
Stratimikos::enableFROSch<SC,LO,GO,NO>(linearSolverBuilder); |
| 335 |
linearSolverBuilder.setParameterList(parameterList); |
| 336 |
|
| 337 |
Comm->barrier(); if (Comm->getRank()==0) cout << "######################\n# Thyra PrepForSolve #\n######################\n" << endl; |
| 338 |
|
| 339 |
RCP<LinearOpWithSolveFactoryBase<SC> > lowsFactory = |
| 340 |
linearSolverBuilder.createLinearSolveStrategy(""); |
| 341 |
|
| 342 |
lowsFactory->setOStream(out); |
| 343 |
lowsFactory->setVerbLevel(VERB_HIGH); |
| 344 |
|
| 345 |
Comm->barrier(); if (Comm->getRank()==0) cout << "###########################\n# Thyra LinearOpWithSolve #\n###########################" << endl; |
| 346 |
|
| 347 |
RCP<LinearOpWithSolveBase<SC> > lows = |
| 348 |
linearOpWithSolve(*lowsFactory, K_thyra); |
| 349 |
|
| 350 |
Comm->barrier(); if (Comm->getRank()==0) cout << "\n#########\n# Solve #\n#########" << endl; |
| 351 |
SolveStatus<SC> status = |
| 352 |
solve<SC>(*lows, Thyra::NOTRANS, *thyraB, thyraX.ptr()); |
| 353 |
|
| 354 |
Comm->barrier(); if (Comm->getRank()==0) cout << "\n#############\n# Finished! #\n#############" << endl; |
| 355 |
} |
| 356 |
|
| 357 |
CommWorld->barrier(); |
| 358 |
stackedTimer->stop("Overlap Test"); |
| 359 |
StackedTimer::OutputOptions options; |
| 360 |
options.output_fraction = options.output_histogram = options.output_minmax = true; |
| 361 |
stackedTimer->report(*out,CommWorld,options); |
| 362 |
|
| 363 |
return(EXIT_SUCCESS); |
| 364 |
|
| 365 |
} |