[mpich-discuss] rank ordering from MPI_Cart_create

Rajeev Thakur thakur at mcs.anl.gov
Mon Nov 25 16:45:31 CST 2013


If you use a Cartesian topology, you have to follow the ordering it uses and use MPI_Cart_shift to know who the neighbors are in each direction. If the application insists on a different ordering, you could use one of the Dist_graph topologies where you explicitly specify who the neighbors are.

Rajeev

On Nov 25, 2013, at 4:08 PM, "Kokron, Daniel S. (GSFC-610.1)[Computer Sciences Corporation]" <daniel.s.kokron at nasa.gov> wrote:

> I am attempting to convert an existing application to use the new MPI_Neighbor_* routines for halo updates.  The trouble I'm having is that the application fixes the ranks in a right-handed cartesian grid while that produced by MPI_Cart_create appears to be left-handed.
> 
> MPI_Cart_create produces a rank ordering for a 4x4 grid
>  0   1    2   3
>  4   5    6   7
>  8   9  10 11
> 12 13 14 15
> 
> The application expects the ranks to be ordered like
> 12 13 14 15
>  8   9  10 11
>  4   5    6   7
>  0   1    2   3
> 
> I've read the MPI-3 manual at http://www.mpi-forum.org/docs/mpi-3.0/mpi30-report.pdf
> 
> What am I missing?  Can I manipulate the rank placement produced by MPI_Cart_create to suite this application?
> 
> Daniel Kokron
> NASA Ames (ARC-TN)
> SciCon group
> 301-286-3959
> _______________________________________________
> discuss mailing list     discuss at mpich.org
> To manage subscription options or unsubscribe:
> https://lists.mpich.org/mailman/listinfo/discuss




More information about the discuss mailing list