44ScipParaInitialStatMpi::createDatatype1(
47 const int nBlocks = 4;
49 MPI_Datatype datatype;
51 MPI_Aint startAddress = 0;
54 int blockLengths[nBlocks];
55 MPI_Aint displacements[nBlocks];
56 MPI_Datatype types[nBlocks];
59 MPI_Get_address( &
maxDepth, &startAddress )
69 displacements[1] = address - startAddress;
76 displacements[2] = address - startAddress;
83 displacements[3] = address - startAddress;
87 MPI_Type_create_struct(nBlocks, blockLengths, displacements, types, &datatype)
96 bool memAllocNecessary
103 MPI_Datatype datatype;
105 MPI_Aint startAddress = 0;
106 MPI_Aint address = 0;
108 int blockLengths[17];
109 MPI_Aint displacements[17];
110 MPI_Datatype types[17];
114 if( memAllocNecessary )
128 displacements[nBlocks] = 0;
130 types[nBlocks] = MPI_INT;
136 displacements[nBlocks] = address - startAddress;
138 types[nBlocks] = MPI_INT;
144 displacements[nBlocks] = address - startAddress;
146 types[nBlocks] = MPI_DOUBLE;
152 displacements[nBlocks] = address - startAddress;
154 types[nBlocks] = MPI_DOUBLE;
160 displacements[nBlocks] = address - startAddress;
162 types[nBlocks] = MPI_DOUBLE;
168 displacements[nBlocks] = address - startAddress;
170 types[nBlocks] = MPI_DOUBLE;
176 displacements[nBlocks] = address - startAddress;
178 types[nBlocks] = MPI_DOUBLE;
184 if( memAllocNecessary )
200 displacements[nBlocks] = 0;
207 displacements[nBlocks] = address - startAddress;
210 types[nBlocks] = MPI_INT;
216 displacements[nBlocks] = address - startAddress;;
218 types[nBlocks] = MPI_INT;
222 MPI_Get_address(
uppscost, &address )
224 displacements[nBlocks] = address - startAddress;;
226 types[nBlocks] = MPI_DOUBLE;
230 MPI_Get_address(
upvsids, &address )
232 displacements[nBlocks] = address - startAddress;;
234 types[nBlocks] = MPI_DOUBLE;
240 displacements[nBlocks] = address - startAddress;;
242 types[nBlocks] = MPI_DOUBLE;
246 MPI_Get_address(
upinfer, &address )
248 displacements[nBlocks] = address - startAddress;;
250 types[nBlocks] = MPI_DOUBLE;
254 MPI_Get_address(
upcutoff, &address )
256 displacements[nBlocks] = address - startAddress;;
258 types[nBlocks] = MPI_DOUBLE;
263 MPI_Type_create_struct(nBlocks, blockLengths, displacements, types, &datatype)
274 MPI_Datatype datatype1;
277 MPI_Type_commit( &datatype1 )
283 MPI_Type_free( &datatype1 )
288 MPI_Datatype datatype2;
291 MPI_Type_commit( &datatype2 )
309 MPI_Type_free( &datatype2 )
319 MPI_Datatype datatype1;
322 MPI_Type_commit( &datatype1 )
328 MPI_Type_free( &datatype1 )
333 MPI_Datatype datatype2;
336 MPI_Type_commit( &datatype2 )
354 MPI_Type_free( &datatype2 )
void send(UG::ParaComm *comm, int dest)
void receive(UG::ParaComm *comm, int source)
MPI_Datatype createDatatype2(bool memAllocNecessary)
MPI_Datatype createDatatype1()
int * idxLBranchStatsVarsUp
int * idxLBranchStatsVarsDown
Base class of communicator object.
static ScipParaCommTh * comm
static const int TagInitialStat
#define DEF_PARA_COMM(para_comm, comm)
#define MPI_CALL(mpicall)
#define PARA_COMM_CALL(paracommcall)
ScipParaInitialStat extension for MPI communication.