Converting Legacy Code from MPI to QMP
To make code portable to the QCDOC and to access special message
passing on clusters, MPI calls should be converted to QMP. For
clusters QMP builds on MPICH and on GM (Myrinet).
The conversion from MPI to QMP is very straightforward:
Sends, receives, broadcasts, reductions all have QMP counterparts.
- No wild cards for source nodes.
MPI_ANY_SOURCE must be replaced by a specific source node.
- QMP memory allocation
Use QMP to allocate buffer memory.
buf = (char *)QMP_allocate_aligned_memory(size);
- Reuse buffers where possible
Closing and opening message buffers and handles incurs overhead.
- Combine multidirectional messages where possible
QCDOC: Combine multidirectional messages - e.g. Dslash.
Last modified: Tue Feb 18 15:52:17 MST 2003