mpcc_r NAME mpcc_r - Invokes a shell script to compile C programs which use threaded MPI. SYNOPSIS mpcc_r [cc_flags]... program.c The mpcc_r shell script compiles C programs while linking in the Partition Manager, the threaded implementation of Message Passing Interface (MPI), and (optionally) Low-level Applications Programming Interface (LAPI). FLAGS Any of the compiler flags normally accepted by the xlc_r or cc_r command can also be used on mpcc_r. For a complete listing of these flag options, refer to the manual page for the AIX cc_r command. Typical options to mpcc_r include: -v causes a "verbose" output listing of the shell script. -g Produces an object file with symbol table references. This object file is needed for debugging with the pdbx debugger. -o names the executable. -cpp enables the use of full C++ bindings in MPI.. -d7 compiles the program with POSIX Threads Draft 7 base MPI and compatibility libraries. Otherwise, the POSIX standard libraries are used. -l (lower-case L) names additional libraries to be searched. Several libraries are automatically included, and are listed below in the CONTEXT section. Note: Not all AIX libraries are thread safe. Verify that your intended use is supported. -I (upper-case i) names directories for additional includes. The directory /usr/lpp/ppe.poe/include or the appropriate subdirectory is included automatically. Command line or makefile hard coding of include paths for PE header files should normally be avoided. Such specifications will take precedence over the directory selected by the script and may result in generating incorrect code. -p enables profiling with the prof command. For more information, see the appendix on "Profiling Programs" in IBM Parallel Environment for AIX: Operation and Use, Volume 2 -pg enables profiling with the xprofiler and gprof commands. For more information, see the "Xprofiler" chapter and the appendix on "Profiling Programs" in IBM Parallel Environment for AIX: Operation and Use, Volume 2 -q64 enables compiling of 64-bit applications. DESCRIPTION The mpcc_r shell script invokes the xlc_r command. In addition, the Partition Manager and data communication interfaces are automatically linked in. The script creates an executable that dynamically binds with the communication subsystem libraries. Flags are passed by mpcc_r to the xlc_r command, so any of the xlc_r options can be used on the mpcc_r shell script. The communication subsystem library implementation is dynamically linked when you invoke the executable using the poe command. The value specified by the MP_EUILIB environment variable or the -euilib flag will then determine which communication subsystem library implementation is dynamically linked. ENVIRONMENT VARIABLES MP_PREFIX sets an alternate path to the scripts library. If not set or NULL, the standard path /usr/lpp/ppe.poe is used. If this environment variable is set, then all libraries are prefixed by $MP_PREFIX/ppe.poe. MP_UTE Setting this variable to yes causes the UTE library to be added to the link step, allowing the user to collect data from the application using PE Benchmarker. For more information, see IBM Parallel Environment for AIX: Operation and Use, Volume 2. EXAMPLES To compile a C program, enter: mpcc_r program.c -o program FILES When you compile a program using mpcc_r, the following libraries are automatically selected: /usr/lpp/ppe.poe/lib/libmpi_r.a (Message Passing Interface, collective communication routines) /usr/lpp/ppe.poe/lib/libppe_r.a (PE common routines) The following library is selected if it exists as a symbolic link to /usr/lpp/ssp/css/lib/liblapi_r.a: /usr/lib/liblapi_r.a RELATED INFORMATION Commands: mpCC(1), mpCC_r(1), mpcc(1), cc(1), pdbx(1), xprofiler(1)