37 #ifndef vtkMPIController_h
38 #define vtkMPIController_h
41 #include "vtkParallelMPIModule.h"
48 VTK_ABI_NAMESPACE_BEGIN
79 int* vtkNotUsed(argc),
char*** vtkNotUsed(argv),
int initializedExternally)
override;
93 void Finalize(
int finalizedExternally)
override;
119 static char* ErrorString(
int err);
150 ->NoBlockSend(data, length, remoteProcessId, tag, req);
156 ->NoBlockSend(data, length, remoteProcessId, tag, req);
162 ->NoBlockSend(data, length, remoteProcessId, tag, req);
168 ->NoBlockSend(data, length, remoteProcessId, tag, req);
174 ->NoBlockSend(data, length, remoteProcessId, tag, req);
180 ->NoBlockSend(data, length, remoteProcessId, tag, req);
186 ->NoBlockSend(data, length, remoteProcessId, tag, req);
192 ->NoBlockSend(data, length, remoteProcessId, tag, req);
198 ->NoBlockSend(data, length, remoteProcessId, tag, req);
204 ->NoBlockSend(data, length, remoteProcessId, tag, req);
210 ->NoBlockSend(data, length, remoteProcessId, tag, req);
216 ->NoBlockSend(data, length, remoteProcessId, tag, req);
222 ->NoBlockSend(data, length, remoteProcessId, tag, req);
228 ->NoBlockSend(data, length, remoteProcessId, tag, req);
239 ->NoBlockSend(data, length, mpiType, remoteProcessId, tag, req);
255 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
261 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
267 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
273 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
279 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
285 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
291 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
297 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
303 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
309 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
315 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
321 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
327 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
333 ->NoBlockReceive(data, length, remoteProcessId, tag, req);
350 return ((
vtkMPICommunicator*)this->Communicator)->Iprobe(source, tag, flag, actualSource);
355 ->Iprobe(source, tag, flag, actualSource, type, size);
360 ->Iprobe(source, tag, flag, actualSource, type, size);
365 ->Iprobe(source, tag, flag, actualSource, type, size);
370 ->Iprobe(source, tag, flag, actualSource, type, size);
375 ->Iprobe(source, tag, flag, actualSource, type, size);
400 return ((
vtkMPICommunicator*)this->Communicator)->Probe(source, tag, actualSource, type, size);
404 return ((
vtkMPICommunicator*)this->Communicator)->Probe(source, tag, actualSource, type, size);
408 return ((
vtkMPICommunicator*)this->Communicator)->Probe(source, tag, actualSource, type, size);
412 return ((
vtkMPICommunicator*)this->Communicator)->Probe(source, tag, actualSource, type, size);
416 return ((
vtkMPICommunicator*)this->Communicator)->Probe(source, tag, actualSource, type, size);
472 static const char* GetProcessorName();
494 void InitializeRMICommunicator();
502 int remoteProcessId,
void* arg,
int argLength,
int rmiTag,
bool propagate)
override;
511 friend class vtkMPIOutputWindow;
516 static char ProcessorName[];
528 VTK_ABI_NAMESPACE_END
int NoBlockSend(const double *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int NoBlockReceive(double *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
int NoBlockSend(const unsigned char *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int Probe(int source, int tag, int *actualSource, float *type, int *size)
Blocking test for a message.
int NoBlockReceive(unsigned char *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
int NoBlockSend(const unsigned long *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int Probe(int source, int tag, int *actualSource, unsigned long *type, int *size)
Blocking test for a message.
int NoBlockReceive(vtkTypeInt64 *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
int NoBlockReceive(float *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
virtual void Finalize()=0
This method is for cleaning up.
Class for creating user defined MPI communicators.
int Iprobe(int source, int tag, int *flag, int *actualSource, const char *type, int *size)
Nonblocking test for a message.
int WaitAny(int count, vtkMPICommunicator::Request requests[], int &idx)
Blocks until one of the specified requests in the given request array completes.
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 unsigned long *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
virtual void Initialize(int *argc, char ***argv)=0
This method is for setting up the processes.
virtual void MultipleMethodExecute()=0
Execute the MultipleMethods (as define by calling SetMultipleMethod for each of the required this->Nu...
typename vtkTypeList::detail::CreateImpl< Ts... >::type Create
int NoBlockReceive(int *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
static int UseSsendForRMI
When set, TriggerRMI uses Ssend instead of Send.
int NoBlockReceive(unsigned char *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
void Initialize(int *argc, char ***argv) override
This method is for setting up the processes.
static void SetUseSsendForRMI(int use_send)
When set to 1, TriggerRMI uses Ssend() instead of Send() calls.
int NoBlockSend(const double *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
void Finalize() override
This method is for cleaning up and has to be called before the end of the program if MPI was initiali...
dynamic, self-adjusting array of int
int Probe(int source, int tag, int *actualSource, double *type, int *size)
Blocking test for a message.
int NoBlockSend(const int *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int NoBlockReceive(unsigned long *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
a simple class to control print indentation
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int NoBlockSend(const vtkTypeInt64 *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int NoBlockSend(const void *data, vtkTypeInt64 length, MPI_Datatype mpiType, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
Variant that permits dynamic type sends, like those create by MPI_Type_create_subarray.
int NoBlockSend(const int *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
vtkTypeList::Create< float, double, char, int, vtkTypeInt64, unsigned char, unsigned long > ValueTypes
The list of value types supported by MPIController.
int NoBlockSend(const float *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
A subgroup of processes from a communicator.
Process communication using MPI.
static vtkMPICommunicator * WorldRMICommunicator
int Probe(int source, int tag, int *actualSource) override
Blocking test for a message.
#define VTK_SIZEHINT(...)
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
int NoBlockReceive(float *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
int Iprobe(int source, int tag, int *flag, int *actualSource, double *type, int *size)
Nonblocking test for a message.
virtual void CreateOutputWindow()=0
This method can be used to tell the controller to create a special output window in which all message...
int NoBlockSend(const vtkTypeInt64 *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int NoBlockSend(const char *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int Iprobe(int source, int tag, int *flag, int *actualSource, unsigned long *type, int *size)
Nonblocking test for a message.
int WaitAll(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, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
int NoBlockReceive(double *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
int Probe(int source, int tag, int *actualSource, const char *type, int *size)
Blocking test for a message.
int NoBlockReceive(char *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
int Iprobe(int source, int tag, int *flag, int *actualSource, float *type, int *size)
Nonblocking test for a message.
static int GetUseSsendForRMI()
int NoBlockSend(const char *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int NoBlockReceive(int *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
int NoBlockSend(const float *data, int length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int Iprobe(int source, int tag, int *flag, int *actualSource, int *type, int *size)
Nonblocking test for a message.
virtual void SingleMethodExecute()=0
Execute the SingleMethod (as define by SetSingleMethod) using this->NumberOfProcesses processes...
virtual vtkMultiProcessController * PartitionController(int localColor, int localKey)
Partitions this controller based on a coloring.
int NoBlockReceive(vtkTypeInt64 *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
virtual vtkMultiProcessController * CreateSubController(vtkProcessGroup *group)
Creates a new controller with the processes specified by the given group.
int NoBlockReceive(unsigned long *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method receives data from a corresponding send (non-blocking).
int NoBlockSend(const unsigned char *data, vtkTypeInt64 length, int remoteProcessId, int tag, vtkMPICommunicator::Request &req)
This method sends data to another process (non-blocking).
int Iprobe(int source, int tag, int *flag, int *actualSource)
Nonblocking test for a message.
bool CanProbe() override
This controller does have probing capability.
int Probe(int source, int tag, int *actualSource, int *type, int *size)
Blocking test for a message.
Multiprocessing communication superclass.