template<class ArrayT>
Definition at line 1202 of file PxDistribution.h. References ArrayCD(), ArrayCH(), ArrayCPB(), ArrayCW(), ArrayD(), ArrayH(), ArrayPB(), and ArrayW(). Referenced by PxBcastArray(). 01203 { 01204 /*** MPI-Bcast. May be faster than OFT/SBT broadcast provided ***/ 01205 /*** above, as specific communication subsystem capabilities ***/ 01206 /*** may be incorporated in the implementation. ***/ 01207 01208 int sSize = ArrayT::ElemSize()*sizeof(typename ArrayT::StorType); 01209 MPI_Datatype elem, blk2d, blk3d; 01210 MPI_Type_contiguous(sSize, MPI_BYTE, &elem); 01211 MPI_Type_commit(&elem); 01212 01213 if (!bdata) { 01214 MPI_Type_vector(ArrayCH(a), 01215 ArrayCW(a), ArrayW(a), elem, &blk2d); 01216 MPI_Type_hvector(ArrayCD(a), 1, 01217 ArrayW(a)*ArrayH(a)*sSize, blk2d, &blk3d); 01218 MPI_Type_commit(&blk3d); 01219 MPI_Bcast(ArrayCPB(a), 1, blk3d, root, MPI_COMM_WORLD); 01220 MPI_Type_free(&blk3d); 01221 MPI_Type_free(&blk2d); 01222 } else { 01223 MPI_Bcast(ArrayPB(a), ArrayW(a)*ArrayH(a)*ArrayD(a), 01224 elem, root, MPI_COMM_WORLD); 01225 } 01226 MPI_Type_free(&elem); 01227 }
Here is the call graph for this function:
|