MpiJob now just deal with loop logic, not with handled data. Handled data is now handled by the MpiJob subclasses. Tests updated.

This commit is contained in:
Benjamin Bouvier 2012-06-21 18:26:56 +02:00
commit 28ab2004ea
4 changed files with 84 additions and 28 deletions

View file

@ -27,7 +27,7 @@ void subtask( vector<int>& v )
DynamicAssignmentAlgorithm algo( 2, MpiNode::comm().size()-1 );
plusOne plusOneInstance;
ParallelApply<int> job( plusOneInstance, v, algo, 1 );
Role<int> node( job );
Role node( job );
node.run();
}
@ -64,7 +64,7 @@ int main(int argc, char** argv)
// only one node is assigned to subjob mastering
DynamicAssignmentAlgorithm algo( 1, 1 );
ParallelApply< vector<int> > job( transmitInstance, metaV, algo, 0 );
Role< vector<int> > node( job );
Role node( job );
node.run();
if( node.master() )
{