49#ifndef vtkMPIController_h
50#define vtkMPIController_h
52#include "vtkParallelMPIModule.h"
84 virtual void Initialize(
int* vtkNotUsed(argc),
char*** vtkNotUsed(argv),
85 int initializedExternally);
99 virtual void Finalize(
int finalizedExternally);
176#ifdef VTK_USE_64BIT_IDS
196 int remoteProcessId,
int tag,
216#ifdef VTK_USE_64BIT_IDS
235 source, tag, flag, actualSource); }
330 void* arg,
int argLength,
int rmiTag,
bool propagate);
339 friend class vtkMPIOutputWindow;
344 static char ProcessorName[];
a simple class to control print indentation
dynamic, self-adjusting array of int
Class for creating user defined MPI communicators.
Process communication using MPI.
int Iprobe(int source, int tag, int *flag, int *actualSource, int *type, int *size)
int WaitAll(const int count, vtkMPICommunicator::Request requests[])
Given the request objects of a set of non-blocking operations (send and/or receive) this method block...
int NoBlockReceive(char *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
virtual void Finalize(int finalizedExternally)
This method is for cleaning up.
virtual void SingleMethodExecute()
Execute the SingleMethod (as define by SetSingleMethod) using this->NumberOfProcesses processes.
int WaitSome(const int count, vtkMPICommunicator::Request requests[], vtkIntArray *completed)
Blocks until one or more of the specified requests in the given request request array completes.
virtual void Initialize(int *vtkNotUsed(argc), char ***vtkNotUsed(argv), int initializedExternally)
This method is for setting up the processes.
void InitializeCommunicator(vtkMPICommunicator *comm)
virtual void Initialize(int *argc, char ***argv)
This method is for setting up the processes.
int NoBlockSend(const char *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
int Iprobe(int source, int tag, int *flag, int *actualSource, double *type, int *size)
int NoBlockSend(const unsigned char *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
int Iprobe(int source, int tag, int *flag, int *actualSource, const char *type, int *size)
int NoBlockReceive(float *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
virtual void MultipleMethodExecute()
Execute the MultipleMethods (as define by calling SetMultipleMethod for each of the required this->Nu...
static int UseSsendForRMI
When set, TriggerRMI uses Ssend instead of Send.
virtual vtkMPIController * CreateSubController(vtkProcessGroup *group)
Creates a new controller with the processes specified by the given group.
bool TestSome(const int count, vtkMPICommunicator::Request requests[], vtkIntArray *completed)
Return true iff one or more of the communicator request objects is complete.
bool TestAny(const int count, vtkMPICommunicator::Request requests[], int &idx)
Returns true iff at least one of the communication request objects is complete.
static vtkMPICommunicator * WorldRMICommunicator
void SetCommunicator(vtkMPICommunicator *comm)
MPIController uses this communicator in all sends and receives.
int NoBlockSend(const float *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
int Iprobe(int source, int tag, int *flag, int *actualSource, float *type, int *size)
virtual vtkMPIController * PartitionController(int localColor, int localKey)
Partitions this controller based on a coloring.
int NoBlockReceive(double *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
static const char * GetProcessorName()
int NoBlockReceive(unsigned long *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
static char * ErrorString(int err)
Given an MPI error code, return a string which contains an error message.
void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
static vtkMPIController * New()
int NoBlockSend(const int *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int WaitAny(const int count, vtkMPICommunicator::Request requests[], int &idx)
Blocks until one of the specified requests in the given request array completes.
static void SetUseSsendForRMI(int use_send)
When set to 1, TriggerRMI uses Ssend() instead of Send() calls.
int NoBlockReceive(int *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
int NoBlockReceive(unsigned char *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
int Iprobe(int source, int tag, int *flag, int *actualSource)
Nonblocking test for a message.
virtual void Finalize()
This method is for cleaning up and has to be called before the end of the program if MPI was initiali...
virtual void TriggerRMIInternal(int remoteProcessId, void *arg, int argLength, int rmiTag, bool propagate)
Implementation for TriggerRMI() provides subclasses an opportunity to modify the behaviour eg.
int NoBlockSend(const double *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
virtual void CreateOutputWindow()
This method can be used to tell the controller to create a special output window in which all message...
bool TestAll(const int count, vtkMPICommunicator::Request requests[])
Returns true iff all of the communication request objects are complete.
virtual void Initialize()
Same as Initialize(0, 0, 1).
static int GetUseSsendForRMI()
int NoBlockSend(const unsigned long *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
int Iprobe(int source, int tag, int *flag, int *actualSource, unsigned long *type, int *size)
void InitializeRMICommunicator()
Multiprocessing communication superclass.
virtual void Initialize(int *vtkNotUsed(argc), char ***vtkNotUsed(argv))=0
This method is for setting up the processes.
A subgroup of processes from a communicator.
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)