The Shallow demo project from the eclipse tutorial cvs can be used with gprof and gcov with a few simple adjustments to the Makefile and MPI runtime.  Here are the details and some discussion of what can be done with the profiling and coverage output.