Beispiel #1
0
        private ParallelTask RecvTaskFromMaster()
        {
            var polarization = Mpi.RecvInt(Mpi.Master, (int)Tag.TaskData, Mpi.CommWorld);
            var frequency    = Mpi.RecvDouble(Mpi.Master, (int)Tag.TaskData, Mpi.CommWorld);

            return(ParallelTask.NewFrequencyTask(frequency, polarization));
        }
Beispiel #2
0
        private int RecvCompleteCommandFromSlave()
        {
            int source;
            int command = Mpi.RecvInt(Mpi.AnySource, (int)Tag.Command, Mpi.CommWorld, out source);

            if (command == (int)Command.TaskIsComplete)
            {
                return(source);
            }

            throw new InvalidOperationException();
        }
Beispiel #3
0
 private Command RecvCommandFromMaster()
 {
     return((Command)Mpi.RecvInt(Mpi.Master, (int)Tag.Command, Mpi.CommWorld));
 }