Download Cluster OpenMP User`s Guide
Transcript
OpenMP* Usage with Cluster OpenMP* -lguide -lclusterguide and -lclompc To ensure that you linked with the correct library, use the KMP_VERSION environment variable as outlined in 10.5, Cluster OpenMP* Environment Variables. If you linked correctly with Cluster OpenMP*, the version output should show Intel(R) Cluster OMP. If not, the OpenMP* runtime library could be statically linked into the library you are trying to use. In this the case, compile the program to produce object files and link explicitly as follows: <intel compiler> <obj files> -o <exe> –lclusterguide –lclompc – l<other library> As long as –lclusterguide appears before the other library on the link line, the OpenMP* runtime library symbols will be resolved from the Cluster OpenMP* runtime library instead of from the other library you are trying to use. To verify, use KMP_VERSION to make sure you linked with Cluster OpenMP*. If you linked correctly with Cluster OpenMP*, the version output should show Intel(R) Cluster OMP. 10.3 OpenMP* Implementation-Defined Behaviors in Cluster OpenMP* The OpenMP* specification at www.openmp.org requires an implementation to document its behavior in a certain set of cases. This section documents these behaviors for Cluster OpenMP. 10.3.1 Number of Threads to Use for a Parallel Region The number of OpenMP threads that are started at the beginning of a given program is the value of the omp_num_threads option after proper defaults are applied. This is the maximum number of threads that can be used by any parallel region in the program. A parallel region can use fewer than the maximum number of threads by specifying a value for the OMP_NUM_THREADS environment variable, or by using the omp_set_num_threads() routine. 10.3.2 Number of Processors The number of processors reported by omp_get_num_procs() is the sum of the number of processors on all nodes. User Manual 51