HOME
| OPENMP API Specification: Version 5.1 November 2020

3  Runtime Library Routines

This chapter describes the OpenMP API runtime library routines and queryable runtime states. In this chapter, true and false are used as generic terms to simplify the description of the routines.

SVG-Viewer needed.

true means a non-zero integer value and false means an integer value of zero.

SVG-Viewer needed.

SVG-Viewer needed.

true means a logical value of .TRUE. and false means a logical value of .FALSE..

SVG-Viewer needed.

SVG-Viewer needed.

Restrictions The following restrictions apply to all OpenMP runtime library routines:

SVG-Viewer needed.

 3.1  Runtime Library Definitions
 3.2  Thread Team Routines
  3.2.1  omp_set_num_threads
  3.2.2  omp_get_num_threads
  3.2.3  omp_get_max_threads
  3.2.4  omp_get_thread_num
  3.2.5  omp_in_parallel
  3.2.6  omp_set_dynamic
  3.2.7  omp_get_dynamic
  3.2.8  omp_get_cancellation
  3.2.9  omp_set_nested (Deprecated)
  3.2.10  omp_get_nested (Deprecated)
  3.2.11  omp_set_schedule
  3.2.12  omp_get_schedule
  3.2.13  omp_get_thread_limit
  3.2.14  omp_get_supported_active_levels
  3.2.15  omp_set_max_active_levels
  3.2.16  omp_get_max_active_levels
  3.2.17  omp_get_level
  3.2.18  omp_get_ancestor_thread_num
  3.2.19  omp_get_team_size
  3.2.20  omp_get_active_level
 3.3  Thread Affinity Routines
  3.3.1  omp_get_proc_bind
  3.3.2  omp_get_num_places
  3.3.3  omp_get_place_num_procs
  3.3.4  omp_get_place_proc_ids
  3.3.5  omp_get_place_num
  3.3.6  omp_get_partition_num_places
  3.3.7  omp_get_partition_place_nums
  3.3.8  omp_set_affinity_format
  3.3.9  omp_get_affinity_format
  3.3.10  omp_display_affinity
  3.3.11  omp_capture_affinity
 3.4  Teams Region Routines
  3.4.1  omp_get_num_teams
  3.4.2  omp_get_team_num
  3.4.3  omp_set_num_teams
  3.4.4  omp_get_max_teams
  3.4.5  omp_set_teams_thread_limit
  3.4.6  omp_get_teams_thread_limit
 3.5  Tasking Routines
  3.5.1  omp_get_max_task_priority
  3.5.2  omp_in_final
 3.6  Resource Relinquishing Routines
  3.6.1  omp_pause_resource
  3.6.2  omp_pause_resource_all
 3.7  Device Information Routines
  3.7.1  omp_get_num_procs
  3.7.2  omp_set_default_device
  3.7.3  omp_get_default_device
  3.7.4  omp_get_num_devices
  3.7.5  omp_get_device_num
  3.7.6  omp_is_initial_device
  3.7.7  omp_get_initial_device
 3.8  Device Memory Routines
  3.8.1  omp_target_alloc
  3.8.2  omp_target_free
  3.8.3  omp_target_is_present
  3.8.4  omp_target_is_accessible
  3.8.5  omp_target_memcpy
  3.8.6  omp_target_memcpy_rect
  3.8.7  omp_target_memcpy_async
  3.8.8  omp_target_memcpy_rect_async
  3.8.9  omp_target_associate_ptr
  3.8.10  omp_target_disassociate_ptr
  3.8.11  omp_get_mapped_ptr
 3.9  Lock Routines
  3.9.1  omp_init_lock and omp_init_nest_lock
  3.9.2  omp_init_lock_with_hint and
omp_init_nest_lock_with_hint

  3.9.3  omp_destroy_lock and omp_destroy_nest_lock
  3.9.4  omp_set_lock and omp_set_nest_lock
  3.9.5  omp_unset_lock and omp_unset_nest_lock
  3.9.6  omp_test_lock and omp_test_nest_lock
 3.10  Timing Routines
  3.10.1  omp_get_wtime
  3.10.2  omp_get_wtick
 3.11  Event Routine
  3.11.1  omp_fulfill_event
 3.12  Interoperability Routines
  3.12.1  omp_get_num_interop_properties
  3.12.2  omp_get_interop_int
  3.12.3  omp_get_interop_ptr
  3.12.4  omp_get_interop_str
  3.12.5  omp_get_interop_name
  3.12.6  omp_get_interop_type_desc
  3.12.7  omp_get_interop_rc_desc
 3.13  Memory Management Routines
  3.13.1  Memory Management Types
  3.13.2  omp_init_allocator
  3.13.3  omp_destroy_allocator
  3.13.4  omp_set_default_allocator
  3.13.5  omp_get_default_allocator
  3.13.6  omp_alloc and omp_aligned_alloc
  3.13.7  omp_free
  3.13.8  omp_calloc and omp_aligned_calloc
  3.13.9  omp_realloc
 3.14  Tool Control Routine
 3.15  Environment Display Routine