Sun Compiler Usage on mathsun
Send questions regarding this to:
Ilya Lashuk ( ilashuk@math.cudenver.edu )
Who has been helping with Sun system administration.
or
trouble@math.cudenver.edu
Two compiler collections are installed currently on mathsun.
First is gnu family (gcc, g++, g77 which compile "c", "c++", "fortran77" respectively). You use then in usual manner, for instance "gcc -o myprog myprog.c".
Second family is "SUN ONE Studio 8 Compiler Collection". These include cc, CC, f77, f90, f95 which compile "c", "c++" and different versions of fortran respectively. Again, in most simple case compilation command looks like this: "cc -o myprog myprog.c"
You can find some info about "gcc", "cc", "CC", etc. by using man ("man cc", for instance). Be sure to tell me if man fails to find docs for particular compiler. Also, you can of course find lots of docs concerning gnu/sun compilers on the web (see docs.sun.com for instance)
Now what concerns MPI. In the simplest case you compile "c" program for MPI with a command "mpcc -o mpiprog.exe mpiprog.c -lmpi" and run it with a command "mprun -np 6 ./mpiprog.exe". Type "man mpcc" for further details and other languages (c++, fortran). Basically "mpcc" is just a script calling "cc" from sun compiler collection with special parameters.