Getting Started - MPI

By Scott Colville, CS/ECE 757 TA, 1998

  1. Look at the example code sample.c in the /p/course/cs757-markhill/public/ directory.

  2. Copy sample.c, Makefile into your own directory.

  3. To compile and link, type

    make sample

  4. To make a symbol link to mpirun, type

    ln -s /p/course/cs757-markhill/public/mpich/bin/mpirun

  5. Run the program with 4 processors (for example) by typing

    ./mpirun -np 4 sample

  6. Write your source code and modify Makefile for it

  7. Now you may read through the documentation on-line, and the Overview first.