To enable autoscoping, the program must be compiled with the -xopenmp option at an optimization level of -xO3 or higher. Autoscoping is not enabled if the program is compiled with -xopenmp=noopt.
Parallel and task autoscoping in C and C++ can handle only basic data types: integer, floating point, and pointer.
Task autoscoping cannot handle arrays.
Task autoscoping in C and C++ cannot handle global variables.
Task autoscoping cannot handle untied tasks.
Task autoscoping cannot handle tasks that are lexically enclosed in some other tasks. For example:
#pragma omp task /* task 1 */ { ... #pragma omp task /* task 2 */ { ... } ... }
In this example, the compiler does not attempt autoscoping for task 2 because it is lexically nested in task 1. The compiler will scope all variables referenced in task 2 as shared and will treat task 2 as if an if(0) (if(.false.) in Fortran) clause is specified on the task.
Only OpenMP directives are recognized and used in the analysis. Calls to OpenMP runtime routines are not recognized. For example, if a program uses omp_set_lock() and omp_unset_lock() to implement a critical section, the compiler is not able to detect the existence of the critical section. Use the critical directive if possible.
Only synchronizations specified using OpenMP synchronization directives, such as barrier and master, are recognized and used in the data race analysis. User-implemented synchronizations such as busy-waiting are not recognized.