HELLO
The Hello World Program
MPI version


HELLO is an MPI version of the HELLO program which does nothing but print "Hello" from each of the processors. It's useful as a basic test program and sanity checker.

Assignment:

Get this simple program to compile, so that you figure out how the MPI compiler works on your system.

Make sure that the executable program that is created is called "hello".

If your computer system allows interactive MPI execution, you can try a command like:


        mpirun ./hello -np 4
      
to run the program interactively using 4 processes.

If your computer system requires batch execution of MPI programs, create a script called hello.sh and try to run your executable program. An example script is available below.

Source Code:

Script for Execution on the FSU HPC Cluster:

Before using MPI on the FSU_HPC cluster, you must first set up the appropriate environment. You can do this by typing

        module load gnu-openmpi
      

Once you have set up the environment, you should compile your program, using one of the following:

to create your executable program. Now you can use the msub command to submit a script to run your program.


Last revised on 22 October 2012.