#include "header.h"
#include "Shell.h"
#include "../scheduling/Clock.h"
#include "../scheduling/testScheduling.h"
#include "../builtins/Arith.h"
#include "SparseMatrix.h"
#include "SparseMsg.h"
#include "SingleMsg.h"
#include "OneToAllMsg.h"
#include "Wildcard.h"
Functions | |
void | testShellParserCreateDelete () |
void | testTreeTraversal () |
void | testDescendant () |
Test the Neutral::isDescendant. | |
void | verifyKids (Id f1, Id f2a, Id f2b, Id f3, Id f4a, Id f4b) |
Utility function to check a commonly used tree structure. | |
void | testChildren () |
Test the Neutral::children and buildTree. | |
void | testMove () |
void | testCopy () |
void | testCopyFieldElement () |
void | testObjIdToAndFromPath () |
void | testShellParserStart () |
void | testInterNodeOps () |
void | testShellSetGet () |
bool | checkArg1 (Id id, double v0, double v1, double v2, double v3, double v4) |
bool | checkOutput (Id e, double v0, double v1, double v2, double v3, double v4) |
void | testShellAddMsg () |
void | testCopyMsgOps () |
void | testShellParserQuit () |
bool | extractIndex (const string &s, unsigned int &index) |
void | testExtractIndices () |
void | testChopString () |
void | testChopPath () |
void | testFindModelParent () |
void | testSyncSynapseSize () |
void | testGetMsgs () |
void | testGetMsgSrcAndTarget () |
void | filterOffNodeTargets (unsigned int start, unsigned int end, bool isSrcGlobal, unsigned int myNode, vector< vector< Eref > > &erefs, vector< vector< bool > > &targetNodes) |
void | testFilterOffNodeTargets () |
void | testWildcard () |
void | testShell () |
void | testMpiShell () |
Variables | |
const bool | TEST_WARNING = false |
bool checkArg1 | ( | Id | id, | |
double | v0, | |||
double | v1, | |||
double | v2, | |||
double | v3, | |||
double | v4 | |||
) |
bool checkOutput | ( | Id | e, | |
double | v0, | |||
double | v1, | |||
double | v2, | |||
double | v3, | |||
double | v4 | |||
) |
References doubleEq(), and Field< A >::get().
Referenced by testCopyMsgOps(), and testShellAddMsg().
bool extractIndex | ( | const string & | s, | |
unsigned int & | index | |||
) |
Referenced by testExtractIndices().
void filterOffNodeTargets | ( | unsigned int | start, | |
unsigned int | end, | |||
bool | isSrcGlobal, | |||
unsigned int | myNode, | |||
vector< vector< Eref > > & | erefs, | |||
vector< vector< bool > > & | targetNodes | |||
) |
Picks which messages we retain in the MsgDigest. Does so at two levels:
References ALLDATA, Eref::dataIndex(), Eref::element(), Eref::getNode(), Element::isGlobal(), and Shell::numNodes().
Referenced by testFilterOffNodeTargets().
void testChildren | ( | ) |
Test the Neutral::children and buildTree.
References Eref::data(), Shell::doCreate(), Shell::doDelete(), Field< A >::set(), TEST_WARNING, and verifyKids().
Referenced by testMpiShell(), and testShell().
void testChopPath | ( | ) |
void testChopString | ( | ) |
void testCopy | ( | ) |
References Eref::data(), Shell::doCopy(), Shell::doCreate(), Shell::doDelete(), Id::element(), Id::eref(), Field< A >::get(), Neutral::getChildren(), Element::getName(), Neutral::getParent(), MooseGlobal, and verifyKids().
Referenced by testMpiShell().
void testCopyFieldElement | ( | ) |
References Neutral::children(), Eref::data(), Shell::doCopy(), Shell::doCreate(), Shell::doDelete(), doubleEq(), Id::element(), Field< A >::get(), Element::getName(), Field< A >::getVec(), Element::isGlobal(), MooseGlobal, Element::numData(), Element::numField(), Field< A >::set(), Field< A >::setRepeat(), Field< A >::setVec(), and Id::value().
Referenced by testMpiShell().
void testCopyMsgOps | ( | ) |
References checkOutput(), Eref::data(), Shell::doAddMsg(), Shell::doCopy(), Shell::doCreate(), Shell::doDelete(), Shell::doReinit(), Shell::doSetClock(), Shell::doStart(), doubleEq(), Shell::doUseClock(), Field< A >::get(), init(), MooseGlobal, SetGet3< A1, A2, A3 >::set(), and SetGet1< A >::setVec().
Referenced by testMpiShell().
void testDescendant | ( | ) |
Test the Neutral::isDescendant.
References Eref::data(), Shell::doCreate(), Shell::doDelete(), and Neutral::isDescendant().
Referenced by testMpiShell().
void testExtractIndices | ( | ) |
void testFilterOffNodeTargets | ( | ) |
References ALLDATA, Eref::data(), Shell::doCreate(), Shell::doDelete(), Id::element(), filterOffNodeTargets(), MooseBlockBalance, and Shell::numNodes().
Referenced by testMpiShell(), and testShell().
void testFindModelParent | ( | ) |
References Eref::data(), Shell::doCreate(), Shell::doDelete(), and findModelParent().
Referenced by testMpiShell().
void testGetMsgs | ( | ) |
Tests message inspection fields on Neutral. These include msgOut: all outgoing Msgs, reported as ObjId of their managers msgIn: all incoming Msgs, reported as ObjId of their managers msgSrc: All source Ids of messages coming into specified field msgDest: All dest Ids of messages going out of specified field
References Eref::data(), Shell::doAddMsg(), Shell::doCreate(), and Shell::doDelete().
Referenced by testShell().
void testGetMsgSrcAndTarget | ( | ) |
Referenced by testShell().
void testInterNodeOps | ( | ) |
Tests Shell operations carried out on multiple nodes
References Eref::data(), Shell::doCreate(), Shell::doDelete(), and Shell::myNode().
Referenced by testMpiShell().
void testMove | ( | ) |
References Eref::data(), Shell::doCreate(), Shell::doDelete(), Shell::doMove(), Id::eref(), Field< A >::get(), Neutral::getChildren(), and verifyKids().
Referenced by testMpiShell().
void testMpiShell | ( | ) |
References testChildren(), testCopy(), testCopyFieldElement(), testCopyMsgOps(), testDescendant(), testFilterOffNodeTargets(), testFindModelParent(), testInterNodeOps(), testMove(), testObjIdToAndFromPath(), testShellAddMsg(), testShellParserCreateDelete(), testShellSetGet(), testSyncSynapseSize(), testTreeTraversal(), and testWildcard().
Referenced by mpiTests().
void testObjIdToAndFromPath | ( | ) |
References Eref::data(), ObjId::dataIndex, Shell::doCreate(), Shell::doDelete(), Shell::doMove(), doubleEq(), ObjId::eref(), ObjId::fieldIndex, Field< A >::get(), ObjId::id, Neutral::parent(), ObjId::path(), Field< A >::set(), and Id::value().
Referenced by testMpiShell().
void testShell | ( | ) |
References testChildren(), testChopPath(), testExtractIndices(), testFilterOffNodeTargets(), testGetMsgs(), testGetMsgSrcAndTarget(), testTreeTraversal(), and testWildcard().
Referenced by nonMpiTests().
void testShellAddMsg | ( | ) |
References checkOutput(), Eref::data(), Shell::doAddMsg(), Shell::doCreate(), Shell::doDelete(), Shell::doSetClock(), Shell::doStart(), doubleEq(), Shell::doUseClock(), Eref::element(), ObjId::eref(), Cinfo::findFinfo(), Field< A >::get(), Element::getNeighbors(), Field< A >::getVec(), init(), Clock::initCinfo(), SetGet3< A1, A2, A3 >::set(), and SetGet1< A >::setVec().
Referenced by testMpiShell().
void testShellParserCreateDelete | ( | ) |
Tests Create and Delete calls issued through the parser interface, which internally sets up blocking messaging calls.
References Eref::data(), Shell::doCreate(), and Shell::doDelete().
Referenced by testMpiShell().
void testShellParserQuit | ( | ) |
void testShellParserStart | ( | ) |
References Eref::data(), Id::destroy(), Shell::doCreate(), Shell::doSetClock(), Shell::doStart(), Shell::doUseClock(), MooseGlobal, and Shell::myNode().
void testShellSetGet | ( | ) |
References Eref::data(), Shell::doCreate(), Shell::doDelete(), doubleEq(), Field< A >::get(), Field< A >::getVec(), SetGet1< A >::set(), and SetGet1< A >::setVec().
Referenced by testMpiShell().
void testSyncSynapseSize | ( | ) |
References c, Eref::data(), Shell::doCreate(), Shell::doDelete(), ObjId::element(), Cinfo::find(), Cinfo::findFinfo(), Element::numField(), Shell::numNodes(), Field< A >::set(), Field< A >::setVec(), and Id::value().
Referenced by testMpiShell().
void testTreeTraversal | ( | ) |
Tests traversal through parents and siblings.
References ALLDATA, ObjId::bad(), Neutral::child(), Eref::data(), Shell::doCreate(), Shell::doDelete(), Shell::doFind(), Id::element(), Field< A >::get(), ObjId::id, Id::path(), ObjId::path(), Field< A >::set(), Shell::setCwe(), TEST_WARNING, and Id::value().
Referenced by testMpiShell(), and testShell().
void testWildcard | ( | ) |
References alignedSingleWildcardMatch(), ALLDATA, Shell::doCreate(), Shell::doDelete(), findWithSingleCharWildcard(), Field< A >::set(), simpleWildcardFind(), wildcardTestFunc(), and y.
Referenced by testMpiShell(), and testShell().
Utility function to check a commonly used tree structure.
References Neutral::buildTree(), Neutral::children(), Eref::data(), and Id::eref().
Referenced by testChildren(), testCopy(), and testMove().
const bool TEST_WARNING = false |
Referenced by testChildren(), and testTreeTraversal().