Go to main content
What's New in the Oracle® Developer Studio 12.6 Release

Exit Print View

Updated: July 2017
 
 

OpenMP

This section discusses new features and updates to the OpenMP API.

  • Improved Dynamic Loop Schedule — The OpenMP 4.5 specification clarifies how the dynamic loop schedule assigns chunks to threads. The chunks of loop iterations are not guaranteed to be assigned to the threads in monotonic order. For example, in the following OpenMP dynamic loop, the 50th iteration is executed before the 0th iteration.

    #pragma omp parallel for num_threads(2) schedule(dynamic)
    for (i=0;i<100;i++) A[i] = B[i];

    This enables more efficient dynamic loop scheduling implementation.

  • Priority Clause for OpenMP Task Pragma — The priority clause feature includes the following:

    • OMP_MAX_TASK_PRIORITY environment variable

    • omp_get_max_task_priority() API routine

    For more information, see OpenMP 4.5 specification section 2.9.1 for priority clause for task construct, section 4.14 for OMP_MAX_TASK_PRIORITY environment variable, and section 3.2.36 for omp_get_max_task_priority API routine.

  • Query Functions for Thread Affinity (Processor Binding) — The following query API routines are added:

    • omp_get_num_places()

    • omp_get_place_num_procs()

    • omp_get_place_proc_ids()

    • omp_get_place_num()

    • omp_get_partition_num_places()

    • omp_get_partition_place_nums()

    For more information, see Section 3.2.23 on page 256 to Section 3.2.28 on page 261 in OpenMP 4.5 specification.

For more information about OpenMP, see Oracle Developer Studio 12.6: OpenMP API User’s Guide.