Sun Studio 12 Update 1: C++ User's Guide

Warnings

Do not specify -xopenmp, with either -xexplicitpar, or -xparallel.

The default for -xopenmp might change in future releases. You can avoid warning messages by explicitly specifying an appropriate optimization.

If you compile and link in separate steps, specify -xopenmp in both the compilation step and the link step. This is important if you are building a shared object. The compiler which was used to compile the executable must not be any older than the compiler that built the .so with -xopenmp. This is especially important when you compile libraries that contain OpenMP directives. See 3.3.3 Compile-Time and Link-Time Options for a complete list of options that must be specified at both compile time and line time.

Make sure that the latest patch of the OpenMP runtime library, libmtsk.so, is installed on the system for best performance.