Home | History | Annotate | Line # | Download | only in libgomp
libgomp.info revision 1.1.1.11
      1  1.1.1.11  mrg This is libgomp.info, produced by makeinfo version 6.5 from
      2   1.1.1.8  mrg libgomp.texi.
      3       1.1  mrg 
      4  1.1.1.10  mrg Copyright (C) 2006-2020 Free Software Foundation, Inc.
      5       1.1  mrg 
      6       1.1  mrg    Permission is granted to copy, distribute and/or modify this document
      7   1.1.1.2  mrg under the terms of the GNU Free Documentation License, Version 1.3 or
      8       1.1  mrg any later version published by the Free Software Foundation; with the
      9       1.1  mrg Invariant Sections being "Funding Free Software", the Front-Cover texts
     10       1.1  mrg being (a) (see below), and with the Back-Cover Texts being (b) (see
     11       1.1  mrg below).  A copy of the license is included in the section entitled "GNU
     12       1.1  mrg Free Documentation License".
     13       1.1  mrg 
     14       1.1  mrg    (a) The FSF's Front-Cover Text is:
     15       1.1  mrg 
     16       1.1  mrg    A GNU Manual
     17       1.1  mrg 
     18       1.1  mrg    (b) The FSF's Back-Cover Text is:
     19       1.1  mrg 
     20       1.1  mrg    You have freedom to copy and modify this GNU Manual, like GNU
     21   1.1.1.8  mrg software.  Copies published by the Free Software Foundation raise funds
     22   1.1.1.8  mrg for GNU development.
     23       1.1  mrg INFO-DIR-SECTION GNU Libraries
     24       1.1  mrg START-INFO-DIR-ENTRY
     25   1.1.1.3  mrg * libgomp: (libgomp).          GNU Offloading and Multi Processing Runtime Library.
     26       1.1  mrg END-INFO-DIR-ENTRY
     27       1.1  mrg 
     28   1.1.1.3  mrg    This manual documents libgomp, the GNU Offloading and Multi
     29   1.1.1.3  mrg Processing Runtime library.  This is the GNU implementation of the
     30   1.1.1.3  mrg OpenMP and OpenACC APIs for parallel and accelerator programming in
     31   1.1.1.3  mrg C/C++ and Fortran.
     32       1.1  mrg 
     33       1.1  mrg    Published by the Free Software Foundation 51 Franklin Street, Fifth
     34       1.1  mrg Floor Boston, MA 02110-1301 USA
     35       1.1  mrg 
     36  1.1.1.10  mrg    Copyright (C) 2006-2020 Free Software Foundation, Inc.
     37       1.1  mrg 
     38       1.1  mrg    Permission is granted to copy, distribute and/or modify this document
     39   1.1.1.2  mrg under the terms of the GNU Free Documentation License, Version 1.3 or
     40       1.1  mrg any later version published by the Free Software Foundation; with the
     41       1.1  mrg Invariant Sections being "Funding Free Software", the Front-Cover texts
     42       1.1  mrg being (a) (see below), and with the Back-Cover Texts being (b) (see
     43       1.1  mrg below).  A copy of the license is included in the section entitled "GNU
     44       1.1  mrg Free Documentation License".
     45       1.1  mrg 
     46       1.1  mrg    (a) The FSF's Front-Cover Text is:
     47       1.1  mrg 
     48       1.1  mrg    A GNU Manual
     49       1.1  mrg 
     50       1.1  mrg    (b) The FSF's Back-Cover Text is:
     51       1.1  mrg 
     52       1.1  mrg    You have freedom to copy and modify this GNU Manual, like GNU
     53   1.1.1.8  mrg software.  Copies published by the Free Software Foundation raise funds
     54   1.1.1.8  mrg for GNU development.
     55       1.1  mrg 
     56       1.1  mrg 
     57       1.1  mrg File: libgomp.info,  Node: Top,  Next: Enabling OpenMP,  Up: (dir)
     58       1.1  mrg 
     59       1.1  mrg Introduction
     60       1.1  mrg ************
     61       1.1  mrg 
     62   1.1.1.8  mrg This manual documents the usage of libgomp, the GNU Offloading and Multi
     63   1.1.1.8  mrg Processing Runtime Library.  This includes the GNU implementation of the
     64   1.1.1.9  mrg OpenMP (https://www.openmp.org) Application Programming Interface (API)
     65   1.1.1.8  mrg for multi-platform shared-memory parallel programming in C/C++ and
     66   1.1.1.8  mrg Fortran, and the GNU implementation of the OpenACC
     67   1.1.1.8  mrg (https://www.openacc.org) Application Programming Interface (API) for
     68   1.1.1.3  mrg offloading of code to accelerator devices in C/C++ and Fortran.
     69   1.1.1.3  mrg 
     70   1.1.1.3  mrg    Originally, libgomp implemented the GNU OpenMP Runtime Library.
     71   1.1.1.3  mrg Based on this, support for OpenACC and offloading (both OpenACC and
     72   1.1.1.3  mrg OpenMP 4's target construct) has been added later on, and the library's
     73   1.1.1.3  mrg name changed to GNU Offloading and Multi Processing Runtime Library.
     74       1.1  mrg 
     75       1.1  mrg * Menu:
     76       1.1  mrg 
     77       1.1  mrg * Enabling OpenMP::            How to enable OpenMP for your applications.
     78   1.1.1.9  mrg * OpenMP Runtime Library Routines: Runtime Library Routines.
     79   1.1.1.9  mrg                                The OpenMP runtime application programming
     80       1.1  mrg                                interface.
     81   1.1.1.9  mrg * OpenMP Environment Variables: Environment Variables.
     82   1.1.1.9  mrg                                Influencing OpenMP runtime behavior with
     83   1.1.1.9  mrg                                environment variables.
     84   1.1.1.5  mrg * Enabling OpenACC::           How to enable OpenACC for your
     85   1.1.1.5  mrg                                applications.
     86   1.1.1.5  mrg * OpenACC Runtime Library Routines:: The OpenACC runtime application
     87   1.1.1.5  mrg                                programming interface.
     88   1.1.1.5  mrg * OpenACC Environment Variables:: Influencing OpenACC runtime behavior with
     89   1.1.1.5  mrg                                environment variables.
     90   1.1.1.5  mrg * CUDA Streams Usage::         Notes on the implementation of
     91   1.1.1.5  mrg                                asynchronous operations.
     92   1.1.1.5  mrg * OpenACC Library Interoperability:: OpenACC library interoperability with the
     93   1.1.1.5  mrg                                NVIDIA CUBLAS library.
     94  1.1.1.10  mrg * OpenACC Profiling Interface::
     95       1.1  mrg * The libgomp ABI::            Notes on the external ABI presented by libgomp.
     96   1.1.1.3  mrg * Reporting Bugs::             How to report bugs in the GNU Offloading and
     97   1.1.1.3  mrg                                Multi Processing Runtime Library.
     98       1.1  mrg * Copying::                    GNU general public license says
     99       1.1  mrg                                how you can copy and share libgomp.
    100       1.1  mrg * GNU Free Documentation License::
    101       1.1  mrg                                How you can copy and share this manual.
    102       1.1  mrg * Funding::                    How to help assure continued work for free
    103       1.1  mrg                                software.
    104   1.1.1.2  mrg * Library Index::              Index of this documentation.
    105       1.1  mrg 
    106       1.1  mrg 
    107       1.1  mrg File: libgomp.info,  Node: Enabling OpenMP,  Next: Runtime Library Routines,  Prev: Top,  Up: Top
    108       1.1  mrg 
    109       1.1  mrg 1 Enabling OpenMP
    110       1.1  mrg *****************
    111       1.1  mrg 
    112       1.1  mrg To activate the OpenMP extensions for C/C++ and Fortran, the
    113   1.1.1.8  mrg compile-time flag '-fopenmp' must be specified.  This enables the OpenMP
    114   1.1.1.8  mrg directive '#pragma omp' in C/C++ and '!$omp' directives in free form,
    115   1.1.1.8  mrg 'c$omp', '*$omp' and '!$omp' directives in fixed form, '!$' conditional
    116   1.1.1.8  mrg compilation sentinels in free form and 'c$', '*$' and '!$' sentinels in
    117   1.1.1.8  mrg fixed form, for Fortran.  The flag also arranges for automatic linking
    118   1.1.1.8  mrg of the OpenMP runtime library (*note Runtime Library Routines::).
    119   1.1.1.8  mrg 
    120   1.1.1.8  mrg    A complete description of all OpenMP directives accepted may be found
    121   1.1.1.9  mrg in the OpenMP Application Program Interface (https://www.openmp.org)
    122   1.1.1.8  mrg manual, version 4.5.
    123       1.1  mrg 
    124       1.1  mrg 
    125       1.1  mrg File: libgomp.info,  Node: Runtime Library Routines,  Next: Environment Variables,  Prev: Enabling OpenMP,  Up: Top
    126       1.1  mrg 
    127   1.1.1.9  mrg 2 OpenMP Runtime Library Routines
    128   1.1.1.9  mrg *********************************
    129       1.1  mrg 
    130   1.1.1.3  mrg The runtime routines described here are defined by Section 3 of the
    131   1.1.1.5  mrg OpenMP specification in version 4.5.  The routines are structured in
    132       1.1  mrg following three parts:
    133       1.1  mrg 
    134       1.1  mrg * Menu:
    135       1.1  mrg 
    136   1.1.1.3  mrg Control threads, processors and the parallel environment.  They have C
    137   1.1.1.3  mrg linkage, and do not throw exceptions.
    138   1.1.1.3  mrg 
    139       1.1  mrg * omp_get_active_level::        Number of active parallel regions
    140       1.1  mrg * omp_get_ancestor_thread_num:: Ancestor thread ID
    141   1.1.1.3  mrg * omp_get_cancellation::        Whether cancellation support is enabled
    142   1.1.1.3  mrg * omp_get_default_device::      Get the default device for target regions
    143       1.1  mrg * omp_get_dynamic::             Dynamic teams setting
    144       1.1  mrg * omp_get_level::               Number of parallel regions
    145   1.1.1.2  mrg * omp_get_max_active_levels::   Maximum number of active regions
    146   1.1.1.5  mrg * omp_get_max_task_priority::   Maximum task priority value that can be set
    147   1.1.1.2  mrg * omp_get_max_threads::         Maximum number of threads of parallel region
    148       1.1  mrg * omp_get_nested::              Nested parallel regions
    149   1.1.1.3  mrg * omp_get_num_devices::         Number of target devices
    150       1.1  mrg * omp_get_num_procs::           Number of processors online
    151   1.1.1.3  mrg * omp_get_num_teams::           Number of teams
    152       1.1  mrg * omp_get_num_threads::         Size of the active team
    153  1.1.1.11  mrg * omp_get_proc_bind::           Whether threads may be moved between CPUs
    154       1.1  mrg * omp_get_schedule::            Obtain the runtime scheduling method
    155   1.1.1.3  mrg * omp_get_team_num::            Get team number
    156       1.1  mrg * omp_get_team_size::           Number of threads in a team
    157   1.1.1.2  mrg * omp_get_thread_limit::        Maximum number of threads
    158       1.1  mrg * omp_get_thread_num::          Current thread ID
    159       1.1  mrg * omp_in_parallel::             Whether a parallel region is active
    160   1.1.1.2  mrg * omp_in_final::                Whether in final or included task region
    161   1.1.1.3  mrg * omp_is_initial_device::       Whether executing on the host device
    162   1.1.1.3  mrg * omp_set_default_device::      Set the default device for target regions
    163       1.1  mrg * omp_set_dynamic::             Enable/disable dynamic teams
    164       1.1  mrg * omp_set_max_active_levels::   Limits the number of active parallel regions
    165       1.1  mrg * omp_set_nested::              Enable/disable nested parallel regions
    166       1.1  mrg * omp_set_num_threads::         Set upper team size limit
    167       1.1  mrg * omp_set_schedule::            Set the runtime scheduling method
    168       1.1  mrg 
    169   1.1.1.3  mrg Initialize, set, test, unset and destroy simple and nested locks.
    170       1.1  mrg 
    171       1.1  mrg * omp_init_lock::            Initialize simple lock
    172       1.1  mrg * omp_set_lock::             Wait for and set simple lock
    173       1.1  mrg * omp_test_lock::            Test and set simple lock if available
    174       1.1  mrg * omp_unset_lock::           Unset simple lock
    175       1.1  mrg * omp_destroy_lock::         Destroy simple lock
    176       1.1  mrg * omp_init_nest_lock::       Initialize nested lock
    177       1.1  mrg * omp_set_nest_lock::        Wait for and set simple lock
    178       1.1  mrg * omp_test_nest_lock::       Test and set nested lock if available
    179       1.1  mrg * omp_unset_nest_lock::      Unset nested lock
    180       1.1  mrg * omp_destroy_nest_lock::    Destroy nested lock
    181       1.1  mrg 
    182   1.1.1.3  mrg Portable, thread-based, wall clock timer.
    183       1.1  mrg 
    184       1.1  mrg * omp_get_wtick::            Get timer precision.
    185       1.1  mrg * omp_get_wtime::            Elapsed wall clock time.
    186       1.1  mrg 
    187       1.1  mrg 
    188       1.1  mrg File: libgomp.info,  Node: omp_get_active_level,  Next: omp_get_ancestor_thread_num,  Up: Runtime Library Routines
    189       1.1  mrg 
    190   1.1.1.8  mrg 2.1 'omp_get_active_level' - Number of parallel regions
    191       1.1  mrg =======================================================
    192       1.1  mrg 
    193       1.1  mrg _Description_:
    194       1.1  mrg      This function returns the nesting level for the active parallel
    195       1.1  mrg      blocks, which enclose the calling call.
    196       1.1  mrg 
    197       1.1  mrg _C/C++_
    198   1.1.1.8  mrg      _Prototype_:   'int omp_get_active_level(void);'
    199       1.1  mrg 
    200       1.1  mrg _Fortran_:
    201   1.1.1.8  mrg      _Interface_:   'integer function omp_get_active_level()'
    202       1.1  mrg 
    203       1.1  mrg _See also_:
    204       1.1  mrg      *note omp_get_level::, *note omp_get_max_active_levels::, *note
    205       1.1  mrg      omp_set_max_active_levels::
    206       1.1  mrg 
    207       1.1  mrg _Reference_:
    208   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.20.
    209       1.1  mrg 
    210       1.1  mrg 
    211   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_ancestor_thread_num,  Next: omp_get_cancellation,  Prev: omp_get_active_level,  Up: Runtime Library Routines
    212       1.1  mrg 
    213   1.1.1.8  mrg 2.2 'omp_get_ancestor_thread_num' - Ancestor thread ID
    214       1.1  mrg ======================================================
    215       1.1  mrg 
    216       1.1  mrg _Description_:
    217       1.1  mrg      This function returns the thread identification number for the
    218   1.1.1.3  mrg      given nesting level of the current thread.  For values of LEVEL
    219   1.1.1.8  mrg      outside zero to 'omp_get_level' -1 is returned; if LEVEL is
    220   1.1.1.8  mrg      'omp_get_level' the result is identical to 'omp_get_thread_num'.
    221       1.1  mrg 
    222       1.1  mrg _C/C++_
    223   1.1.1.8  mrg      _Prototype_:   'int omp_get_ancestor_thread_num(int level);'
    224       1.1  mrg 
    225       1.1  mrg _Fortran_:
    226   1.1.1.8  mrg      _Interface_:   'integer function omp_get_ancestor_thread_num(level)'
    227   1.1.1.8  mrg                     'integer level'
    228       1.1  mrg 
    229       1.1  mrg _See also_:
    230       1.1  mrg      *note omp_get_level::, *note omp_get_thread_num::, *note
    231       1.1  mrg      omp_get_team_size::
    232       1.1  mrg 
    233       1.1  mrg _Reference_:
    234   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.18.
    235       1.1  mrg 
    236       1.1  mrg 
    237   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_cancellation,  Next: omp_get_default_device,  Prev: omp_get_ancestor_thread_num,  Up: Runtime Library Routines
    238   1.1.1.3  mrg 
    239   1.1.1.8  mrg 2.3 'omp_get_cancellation' - Whether cancellation support is enabled
    240   1.1.1.3  mrg ====================================================================
    241   1.1.1.3  mrg 
    242   1.1.1.3  mrg _Description_:
    243   1.1.1.8  mrg      This function returns 'true' if cancellation is activated, 'false'
    244   1.1.1.8  mrg      otherwise.  Here, 'true' and 'false' represent their
    245   1.1.1.8  mrg      language-specific counterparts.  Unless 'OMP_CANCELLATION' is set
    246   1.1.1.3  mrg      true, cancellations are deactivated.
    247   1.1.1.3  mrg 
    248   1.1.1.3  mrg _C/C++_:
    249   1.1.1.8  mrg      _Prototype_:   'int omp_get_cancellation(void);'
    250   1.1.1.3  mrg 
    251   1.1.1.3  mrg _Fortran_:
    252   1.1.1.8  mrg      _Interface_:   'logical function omp_get_cancellation()'
    253   1.1.1.3  mrg 
    254   1.1.1.3  mrg _See also_:
    255   1.1.1.3  mrg      *note OMP_CANCELLATION::
    256   1.1.1.3  mrg 
    257   1.1.1.3  mrg _Reference_:
    258   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.9.
    259   1.1.1.3  mrg 
    260   1.1.1.3  mrg 
    261   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_default_device,  Next: omp_get_dynamic,  Prev: omp_get_cancellation,  Up: Runtime Library Routines
    262   1.1.1.3  mrg 
    263   1.1.1.8  mrg 2.4 'omp_get_default_device' - Get the default device for target regions
    264   1.1.1.3  mrg ========================================================================
    265   1.1.1.3  mrg 
    266   1.1.1.3  mrg _Description_:
    267   1.1.1.3  mrg      Get the default device for target regions without device clause.
    268   1.1.1.3  mrg 
    269   1.1.1.3  mrg _C/C++_:
    270   1.1.1.8  mrg      _Prototype_:   'int omp_get_default_device(void);'
    271       1.1  mrg 
    272   1.1.1.3  mrg _Fortran_:
    273   1.1.1.8  mrg      _Interface_:   'integer function omp_get_default_device()'
    274   1.1.1.3  mrg 
    275   1.1.1.3  mrg _See also_:
    276   1.1.1.3  mrg      *note OMP_DEFAULT_DEVICE::, *note omp_set_default_device::
    277   1.1.1.3  mrg 
    278   1.1.1.3  mrg _Reference_:
    279   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.30.
    280   1.1.1.3  mrg 
    281   1.1.1.3  mrg 
    282   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_dynamic,  Next: omp_get_level,  Prev: omp_get_default_device,  Up: Runtime Library Routines
    283   1.1.1.3  mrg 
    284   1.1.1.8  mrg 2.5 'omp_get_dynamic' - Dynamic teams setting
    285       1.1  mrg =============================================
    286       1.1  mrg 
    287       1.1  mrg _Description_:
    288   1.1.1.8  mrg      This function returns 'true' if enabled, 'false' otherwise.  Here,
    289   1.1.1.8  mrg      'true' and 'false' represent their language-specific counterparts.
    290       1.1  mrg 
    291       1.1  mrg      The dynamic team setting may be initialized at startup by the
    292   1.1.1.8  mrg      'OMP_DYNAMIC' environment variable or at runtime using
    293   1.1.1.8  mrg      'omp_set_dynamic'.  If undefined, dynamic adjustment is disabled by
    294   1.1.1.8  mrg      default.
    295       1.1  mrg 
    296       1.1  mrg _C/C++_:
    297   1.1.1.8  mrg      _Prototype_:   'int omp_get_dynamic(void);'
    298       1.1  mrg 
    299       1.1  mrg _Fortran_:
    300   1.1.1.8  mrg      _Interface_:   'logical function omp_get_dynamic()'
    301       1.1  mrg 
    302       1.1  mrg _See also_:
    303       1.1  mrg      *note omp_set_dynamic::, *note OMP_DYNAMIC::
    304       1.1  mrg 
    305       1.1  mrg _Reference_:
    306   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.8.
    307       1.1  mrg 
    308       1.1  mrg 
    309       1.1  mrg File: libgomp.info,  Node: omp_get_level,  Next: omp_get_max_active_levels,  Prev: omp_get_dynamic,  Up: Runtime Library Routines
    310       1.1  mrg 
    311   1.1.1.8  mrg 2.6 'omp_get_level' - Obtain the current nesting level
    312       1.1  mrg ======================================================
    313       1.1  mrg 
    314       1.1  mrg _Description_:
    315       1.1  mrg      This function returns the nesting level for the parallel blocks,
    316       1.1  mrg      which enclose the calling call.
    317       1.1  mrg 
    318       1.1  mrg _C/C++_
    319   1.1.1.8  mrg      _Prototype_:   'int omp_get_level(void);'
    320       1.1  mrg 
    321       1.1  mrg _Fortran_:
    322   1.1.1.8  mrg      _Interface_:   'integer function omp_level()'
    323       1.1  mrg 
    324       1.1  mrg _See also_:
    325       1.1  mrg      *note omp_get_active_level::
    326       1.1  mrg 
    327       1.1  mrg _Reference_:
    328   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.17.
    329       1.1  mrg 
    330       1.1  mrg 
    331   1.1.1.5  mrg File: libgomp.info,  Node: omp_get_max_active_levels,  Next: omp_get_max_task_priority,  Prev: omp_get_level,  Up: Runtime Library Routines
    332       1.1  mrg 
    333   1.1.1.8  mrg 2.7 'omp_get_max_active_levels' - Maximum number of active regions
    334       1.1  mrg ==================================================================
    335       1.1  mrg 
    336       1.1  mrg _Description_:
    337   1.1.1.2  mrg      This function obtains the maximum allowed number of nested, active
    338   1.1.1.2  mrg      parallel regions.
    339       1.1  mrg 
    340       1.1  mrg _C/C++_
    341   1.1.1.8  mrg      _Prototype_:   'int omp_get_max_active_levels(void);'
    342       1.1  mrg 
    343       1.1  mrg _Fortran_:
    344   1.1.1.8  mrg      _Interface_:   'integer function omp_get_max_active_levels()'
    345       1.1  mrg 
    346       1.1  mrg _See also_:
    347       1.1  mrg      *note omp_set_max_active_levels::, *note omp_get_active_level::
    348       1.1  mrg 
    349       1.1  mrg _Reference_:
    350   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.16.
    351       1.1  mrg 
    352       1.1  mrg 
    353   1.1.1.5  mrg File: libgomp.info,  Node: omp_get_max_task_priority,  Next: omp_get_max_threads,  Prev: omp_get_max_active_levels,  Up: Runtime Library Routines
    354   1.1.1.5  mrg 
    355   1.1.1.8  mrg 2.8 'omp_get_max_task_priority' - Maximum priority value
    356   1.1.1.5  mrg ========================================================
    357   1.1.1.5  mrg 
    358   1.1.1.5  mrg that can be set for tasks.
    359   1.1.1.5  mrg _Description_:
    360   1.1.1.5  mrg      This function obtains the maximum allowed priority number for
    361   1.1.1.5  mrg      tasks.
    362   1.1.1.5  mrg 
    363   1.1.1.5  mrg _C/C++_
    364   1.1.1.8  mrg      _Prototype_:   'int omp_get_max_task_priority(void);'
    365       1.1  mrg 
    366   1.1.1.5  mrg _Fortran_:
    367   1.1.1.8  mrg      _Interface_:   'integer function omp_get_max_task_priority()'
    368   1.1.1.5  mrg 
    369   1.1.1.5  mrg _Reference_:
    370   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.29.
    371   1.1.1.5  mrg 
    372   1.1.1.5  mrg 
    373   1.1.1.5  mrg File: libgomp.info,  Node: omp_get_max_threads,  Next: omp_get_nested,  Prev: omp_get_max_task_priority,  Up: Runtime Library Routines
    374   1.1.1.5  mrg 
    375   1.1.1.8  mrg 2.9 'omp_get_max_threads' - Maximum number of threads of parallel region
    376       1.1  mrg ========================================================================
    377       1.1  mrg 
    378       1.1  mrg _Description_:
    379   1.1.1.2  mrg      Return the maximum number of threads used for the current parallel
    380   1.1.1.8  mrg      region that does not use the clause 'num_threads'.
    381       1.1  mrg 
    382       1.1  mrg _C/C++_:
    383   1.1.1.8  mrg      _Prototype_:   'int omp_get_max_threads(void);'
    384       1.1  mrg 
    385       1.1  mrg _Fortran_:
    386   1.1.1.8  mrg      _Interface_:   'integer function omp_get_max_threads()'
    387       1.1  mrg 
    388       1.1  mrg _See also_:
    389       1.1  mrg      *note omp_set_num_threads::, *note omp_set_dynamic::, *note
    390       1.1  mrg      omp_get_thread_limit::
    391       1.1  mrg 
    392       1.1  mrg _Reference_:
    393   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.3.
    394       1.1  mrg 
    395       1.1  mrg 
    396   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_nested,  Next: omp_get_num_devices,  Prev: omp_get_max_threads,  Up: Runtime Library Routines
    397       1.1  mrg 
    398   1.1.1.8  mrg 2.10 'omp_get_nested' - Nested parallel regions
    399   1.1.1.5  mrg ===============================================
    400       1.1  mrg 
    401       1.1  mrg _Description_:
    402   1.1.1.8  mrg      This function returns 'true' if nested parallel regions are
    403   1.1.1.8  mrg      enabled, 'false' otherwise.  Here, 'true' and 'false' represent
    404       1.1  mrg      their language-specific counterparts.
    405       1.1  mrg 
    406       1.1  mrg      Nested parallel regions may be initialized at startup by the
    407   1.1.1.8  mrg      'OMP_NESTED' environment variable or at runtime using
    408   1.1.1.8  mrg      'omp_set_nested'.  If undefined, nested parallel regions are
    409       1.1  mrg      disabled by default.
    410       1.1  mrg 
    411       1.1  mrg _C/C++_:
    412   1.1.1.8  mrg      _Prototype_:   'int omp_get_nested(void);'
    413       1.1  mrg 
    414       1.1  mrg _Fortran_:
    415   1.1.1.8  mrg      _Interface_:   'logical function omp_get_nested()'
    416       1.1  mrg 
    417       1.1  mrg _See also_:
    418       1.1  mrg      *note omp_set_nested::, *note OMP_NESTED::
    419       1.1  mrg 
    420       1.1  mrg _Reference_:
    421   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.11.
    422       1.1  mrg 
    423       1.1  mrg 
    424   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_num_devices,  Next: omp_get_num_procs,  Prev: omp_get_nested,  Up: Runtime Library Routines
    425       1.1  mrg 
    426   1.1.1.8  mrg 2.11 'omp_get_num_devices' - Number of target devices
    427       1.1  mrg =====================================================
    428       1.1  mrg 
    429       1.1  mrg _Description_:
    430   1.1.1.3  mrg      Returns the number of target devices.
    431   1.1.1.3  mrg 
    432   1.1.1.3  mrg _C/C++_:
    433   1.1.1.8  mrg      _Prototype_:   'int omp_get_num_devices(void);'
    434   1.1.1.3  mrg 
    435   1.1.1.3  mrg _Fortran_:
    436   1.1.1.8  mrg      _Interface_:   'integer function omp_get_num_devices()'
    437   1.1.1.3  mrg 
    438   1.1.1.3  mrg _Reference_:
    439   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.31.
    440   1.1.1.3  mrg 
    441   1.1.1.3  mrg 
    442   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_num_procs,  Next: omp_get_num_teams,  Prev: omp_get_num_devices,  Up: Runtime Library Routines
    443   1.1.1.3  mrg 
    444   1.1.1.8  mrg 2.12 'omp_get_num_procs' - Number of processors online
    445   1.1.1.3  mrg ======================================================
    446   1.1.1.3  mrg 
    447   1.1.1.3  mrg _Description_:
    448   1.1.1.3  mrg      Returns the number of processors online on that device.
    449       1.1  mrg 
    450       1.1  mrg _C/C++_:
    451   1.1.1.8  mrg      _Prototype_:   'int omp_get_num_procs(void);'
    452       1.1  mrg 
    453       1.1  mrg _Fortran_:
    454   1.1.1.8  mrg      _Interface_:   'integer function omp_get_num_procs()'
    455       1.1  mrg 
    456       1.1  mrg _Reference_:
    457   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.5.
    458       1.1  mrg 
    459       1.1  mrg 
    460   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_num_teams,  Next: omp_get_num_threads,  Prev: omp_get_num_procs,  Up: Runtime Library Routines
    461       1.1  mrg 
    462   1.1.1.8  mrg 2.13 'omp_get_num_teams' - Number of teams
    463   1.1.1.3  mrg ==========================================
    464       1.1  mrg 
    465       1.1  mrg _Description_:
    466   1.1.1.3  mrg      Returns the number of teams in the current team region.
    467   1.1.1.3  mrg 
    468   1.1.1.3  mrg _C/C++_:
    469   1.1.1.8  mrg      _Prototype_:   'int omp_get_num_teams(void);'
    470   1.1.1.3  mrg 
    471   1.1.1.3  mrg _Fortran_:
    472   1.1.1.8  mrg      _Interface_:   'integer function omp_get_num_teams()'
    473   1.1.1.3  mrg 
    474   1.1.1.3  mrg _Reference_:
    475   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.32.
    476   1.1.1.3  mrg 
    477   1.1.1.3  mrg 
    478   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_num_threads,  Next: omp_get_proc_bind,  Prev: omp_get_num_teams,  Up: Runtime Library Routines
    479   1.1.1.3  mrg 
    480   1.1.1.8  mrg 2.14 'omp_get_num_threads' - Size of the active team
    481   1.1.1.3  mrg ====================================================
    482   1.1.1.3  mrg 
    483   1.1.1.3  mrg _Description_:
    484   1.1.1.8  mrg      Returns the number of threads in the current team.  In a sequential
    485   1.1.1.8  mrg      section of the program 'omp_get_num_threads' returns 1.
    486       1.1  mrg 
    487       1.1  mrg      The default team size may be initialized at startup by the
    488   1.1.1.8  mrg      'OMP_NUM_THREADS' environment variable.  At runtime, the size of
    489   1.1.1.8  mrg      the current team may be set either by the 'NUM_THREADS' clause or
    490   1.1.1.8  mrg      by 'omp_set_num_threads'.  If none of the above were used to define
    491   1.1.1.8  mrg      a specific value and 'OMP_DYNAMIC' is disabled, one thread per CPU
    492   1.1.1.8  mrg      online is used.
    493       1.1  mrg 
    494       1.1  mrg _C/C++_:
    495   1.1.1.8  mrg      _Prototype_:   'int omp_get_num_threads(void);'
    496       1.1  mrg 
    497       1.1  mrg _Fortran_:
    498   1.1.1.8  mrg      _Interface_:   'integer function omp_get_num_threads()'
    499       1.1  mrg 
    500       1.1  mrg _See also_:
    501       1.1  mrg      *note omp_get_max_threads::, *note omp_set_num_threads::, *note
    502       1.1  mrg      OMP_NUM_THREADS::
    503       1.1  mrg 
    504       1.1  mrg _Reference_:
    505   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.2.
    506   1.1.1.3  mrg 
    507   1.1.1.3  mrg 
    508   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_proc_bind,  Next: omp_get_schedule,  Prev: omp_get_num_threads,  Up: Runtime Library Routines
    509   1.1.1.3  mrg 
    510  1.1.1.11  mrg 2.15 'omp_get_proc_bind' - Whether threads may be moved between CPUs
    511  1.1.1.11  mrg ====================================================================
    512   1.1.1.3  mrg 
    513   1.1.1.3  mrg _Description_:
    514   1.1.1.8  mrg      This functions returns the currently active thread affinity policy,
    515   1.1.1.8  mrg      which is set via 'OMP_PROC_BIND'.  Possible values are
    516   1.1.1.8  mrg      'omp_proc_bind_false', 'omp_proc_bind_true',
    517   1.1.1.8  mrg      'omp_proc_bind_master', 'omp_proc_bind_close' and
    518   1.1.1.8  mrg      'omp_proc_bind_spread'.
    519   1.1.1.3  mrg 
    520   1.1.1.3  mrg _C/C++_:
    521   1.1.1.8  mrg      _Prototype_:   'omp_proc_bind_t omp_get_proc_bind(void);'
    522   1.1.1.3  mrg 
    523   1.1.1.3  mrg _Fortran_:
    524   1.1.1.8  mrg      _Interface_:   'integer(kind=omp_proc_bind_kind) function
    525   1.1.1.8  mrg                     omp_get_proc_bind()'
    526   1.1.1.3  mrg 
    527   1.1.1.3  mrg _See also_:
    528   1.1.1.3  mrg      *note OMP_PROC_BIND::, *note OMP_PLACES::, *note
    529   1.1.1.3  mrg      GOMP_CPU_AFFINITY::,
    530   1.1.1.3  mrg 
    531   1.1.1.3  mrg _Reference_:
    532   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.22.
    533       1.1  mrg 
    534       1.1  mrg 
    535   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_schedule,  Next: omp_get_team_num,  Prev: omp_get_proc_bind,  Up: Runtime Library Routines
    536       1.1  mrg 
    537   1.1.1.8  mrg 2.16 'omp_get_schedule' - Obtain the runtime scheduling method
    538       1.1  mrg ==============================================================
    539       1.1  mrg 
    540       1.1  mrg _Description_:
    541   1.1.1.3  mrg      Obtain the runtime scheduling method.  The KIND argument will be
    542   1.1.1.8  mrg      set to the value 'omp_sched_static', 'omp_sched_dynamic',
    543   1.1.1.8  mrg      'omp_sched_guided' or 'omp_sched_auto'.  The second argument,
    544   1.1.1.5  mrg      CHUNK_SIZE, is set to the chunk size.
    545       1.1  mrg 
    546       1.1  mrg _C/C++_
    547   1.1.1.8  mrg      _Prototype_:   'void omp_get_schedule(omp_sched_t *kind, int
    548   1.1.1.8  mrg                     *chunk_size);'
    549       1.1  mrg 
    550       1.1  mrg _Fortran_:
    551   1.1.1.8  mrg      _Interface_:   'subroutine omp_get_schedule(kind, chunk_size)'
    552   1.1.1.8  mrg                     'integer(kind=omp_sched_kind) kind'
    553   1.1.1.8  mrg                     'integer chunk_size'
    554       1.1  mrg 
    555       1.1  mrg _See also_:
    556       1.1  mrg      *note omp_set_schedule::, *note OMP_SCHEDULE::
    557       1.1  mrg 
    558       1.1  mrg _Reference_:
    559   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.13.
    560   1.1.1.3  mrg 
    561   1.1.1.3  mrg 
    562   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_team_num,  Next: omp_get_team_size,  Prev: omp_get_schedule,  Up: Runtime Library Routines
    563   1.1.1.3  mrg 
    564   1.1.1.8  mrg 2.17 'omp_get_team_num' - Get team number
    565   1.1.1.3  mrg =========================================
    566   1.1.1.3  mrg 
    567   1.1.1.3  mrg _Description_:
    568   1.1.1.3  mrg      Returns the team number of the calling thread.
    569   1.1.1.3  mrg 
    570   1.1.1.3  mrg _C/C++_:
    571   1.1.1.8  mrg      _Prototype_:   'int omp_get_team_num(void);'
    572   1.1.1.3  mrg 
    573   1.1.1.3  mrg _Fortran_:
    574   1.1.1.8  mrg      _Interface_:   'integer function omp_get_team_num()'
    575   1.1.1.3  mrg 
    576   1.1.1.3  mrg _Reference_:
    577   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.33.
    578       1.1  mrg 
    579       1.1  mrg 
    580   1.1.1.3  mrg File: libgomp.info,  Node: omp_get_team_size,  Next: omp_get_thread_limit,  Prev: omp_get_team_num,  Up: Runtime Library Routines
    581       1.1  mrg 
    582   1.1.1.8  mrg 2.18 'omp_get_team_size' - Number of threads in a team
    583       1.1  mrg ======================================================
    584       1.1  mrg 
    585       1.1  mrg _Description_:
    586       1.1  mrg      This function returns the number of threads in a thread team to
    587   1.1.1.3  mrg      which either the current thread or its ancestor belongs.  For
    588   1.1.1.8  mrg      values of LEVEL outside zero to 'omp_get_level', -1 is returned; if
    589   1.1.1.8  mrg      LEVEL is zero, 1 is returned, and for 'omp_get_level', the result
    590   1.1.1.8  mrg      is identical to 'omp_get_num_threads'.
    591       1.1  mrg 
    592       1.1  mrg _C/C++_:
    593   1.1.1.8  mrg      _Prototype_:   'int omp_get_team_size(int level);'
    594       1.1  mrg 
    595       1.1  mrg _Fortran_:
    596   1.1.1.8  mrg      _Interface_:   'integer function omp_get_team_size(level)'
    597   1.1.1.8  mrg                     'integer level'
    598       1.1  mrg 
    599       1.1  mrg _See also_:
    600       1.1  mrg      *note omp_get_num_threads::, *note omp_get_level::, *note
    601       1.1  mrg      omp_get_ancestor_thread_num::
    602       1.1  mrg 
    603       1.1  mrg _Reference_:
    604   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.19.
    605       1.1  mrg 
    606       1.1  mrg 
    607       1.1  mrg File: libgomp.info,  Node: omp_get_thread_limit,  Next: omp_get_thread_num,  Prev: omp_get_team_size,  Up: Runtime Library Routines
    608       1.1  mrg 
    609   1.1.1.8  mrg 2.19 'omp_get_thread_limit' - Maximum number of threads
    610       1.1  mrg =======================================================
    611       1.1  mrg 
    612       1.1  mrg _Description_:
    613   1.1.1.2  mrg      Return the maximum number of threads of the program.
    614       1.1  mrg 
    615       1.1  mrg _C/C++_:
    616   1.1.1.8  mrg      _Prototype_:   'int omp_get_thread_limit(void);'
    617       1.1  mrg 
    618       1.1  mrg _Fortran_:
    619   1.1.1.8  mrg      _Interface_:   'integer function omp_get_thread_limit()'
    620       1.1  mrg 
    621       1.1  mrg _See also_:
    622       1.1  mrg      *note omp_get_max_threads::, *note OMP_THREAD_LIMIT::
    623       1.1  mrg 
    624       1.1  mrg _Reference_:
    625   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.14.
    626       1.1  mrg 
    627       1.1  mrg 
    628       1.1  mrg File: libgomp.info,  Node: omp_get_thread_num,  Next: omp_in_parallel,  Prev: omp_get_thread_limit,  Up: Runtime Library Routines
    629       1.1  mrg 
    630   1.1.1.8  mrg 2.20 'omp_get_thread_num' - Current thread ID
    631       1.1  mrg =============================================
    632       1.1  mrg 
    633       1.1  mrg _Description_:
    634   1.1.1.2  mrg      Returns a unique thread identification number within the current
    635   1.1.1.8  mrg      team.  In a sequential parts of the program, 'omp_get_thread_num'
    636   1.1.1.8  mrg      always returns 0.  In parallel regions the return value varies from
    637   1.1.1.8  mrg      0 to 'omp_get_num_threads'-1 inclusive.  The return value of the
    638   1.1.1.8  mrg      master thread of a team is always 0.
    639       1.1  mrg 
    640       1.1  mrg _C/C++_:
    641   1.1.1.8  mrg      _Prototype_:   'int omp_get_thread_num(void);'
    642       1.1  mrg 
    643       1.1  mrg _Fortran_:
    644   1.1.1.8  mrg      _Interface_:   'integer function omp_get_thread_num()'
    645       1.1  mrg 
    646       1.1  mrg _See also_:
    647       1.1  mrg      *note omp_get_num_threads::, *note omp_get_ancestor_thread_num::
    648       1.1  mrg 
    649       1.1  mrg _Reference_:
    650   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.4.
    651       1.1  mrg 
    652       1.1  mrg 
    653   1.1.1.2  mrg File: libgomp.info,  Node: omp_in_parallel,  Next: omp_in_final,  Prev: omp_get_thread_num,  Up: Runtime Library Routines
    654       1.1  mrg 
    655   1.1.1.8  mrg 2.21 'omp_in_parallel' - Whether a parallel region is active
    656       1.1  mrg ============================================================
    657       1.1  mrg 
    658       1.1  mrg _Description_:
    659   1.1.1.8  mrg      This function returns 'true' if currently running in parallel,
    660   1.1.1.8  mrg      'false' otherwise.  Here, 'true' and 'false' represent their
    661       1.1  mrg      language-specific counterparts.
    662       1.1  mrg 
    663       1.1  mrg _C/C++_:
    664   1.1.1.8  mrg      _Prototype_:   'int omp_in_parallel(void);'
    665       1.1  mrg 
    666       1.1  mrg _Fortran_:
    667   1.1.1.8  mrg      _Interface_:   'logical function omp_in_parallel()'
    668       1.1  mrg 
    669       1.1  mrg _Reference_:
    670   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.6.
    671       1.1  mrg 
    672       1.1  mrg 
    673   1.1.1.3  mrg File: libgomp.info,  Node: omp_in_final,  Next: omp_is_initial_device,  Prev: omp_in_parallel,  Up: Runtime Library Routines
    674   1.1.1.2  mrg 
    675   1.1.1.8  mrg 2.22 'omp_in_final' - Whether in final or included task region
    676   1.1.1.2  mrg ==============================================================
    677   1.1.1.2  mrg 
    678   1.1.1.2  mrg _Description_:
    679   1.1.1.8  mrg      This function returns 'true' if currently running in a final or
    680   1.1.1.8  mrg      included task region, 'false' otherwise.  Here, 'true' and 'false'
    681   1.1.1.2  mrg      represent their language-specific counterparts.
    682   1.1.1.2  mrg 
    683   1.1.1.2  mrg _C/C++_:
    684   1.1.1.8  mrg      _Prototype_:   'int omp_in_final(void);'
    685       1.1  mrg 
    686   1.1.1.2  mrg _Fortran_:
    687   1.1.1.8  mrg      _Interface_:   'logical function omp_in_final()'
    688   1.1.1.2  mrg 
    689   1.1.1.2  mrg _Reference_:
    690   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.21.
    691   1.1.1.3  mrg 
    692   1.1.1.3  mrg 
    693   1.1.1.3  mrg File: libgomp.info,  Node: omp_is_initial_device,  Next: omp_set_default_device,  Prev: omp_in_final,  Up: Runtime Library Routines
    694   1.1.1.3  mrg 
    695   1.1.1.8  mrg 2.23 'omp_is_initial_device' - Whether executing on the host device
    696   1.1.1.3  mrg ===================================================================
    697   1.1.1.3  mrg 
    698   1.1.1.3  mrg _Description_:
    699   1.1.1.8  mrg      This function returns 'true' if currently running on the host
    700   1.1.1.8  mrg      device, 'false' otherwise.  Here, 'true' and 'false' represent
    701   1.1.1.3  mrg      their language-specific counterparts.
    702   1.1.1.3  mrg 
    703   1.1.1.3  mrg _C/C++_:
    704   1.1.1.8  mrg      _Prototype_:   'int omp_is_initial_device(void);'
    705   1.1.1.3  mrg 
    706   1.1.1.3  mrg _Fortran_:
    707   1.1.1.8  mrg      _Interface_:   'logical function omp_is_initial_device()'
    708   1.1.1.3  mrg 
    709   1.1.1.3  mrg _Reference_:
    710   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.34.
    711   1.1.1.3  mrg 
    712   1.1.1.3  mrg 
    713   1.1.1.3  mrg File: libgomp.info,  Node: omp_set_default_device,  Next: omp_set_dynamic,  Prev: omp_is_initial_device,  Up: Runtime Library Routines
    714   1.1.1.3  mrg 
    715   1.1.1.8  mrg 2.24 'omp_set_default_device' - Set the default device for target regions
    716   1.1.1.3  mrg =========================================================================
    717   1.1.1.3  mrg 
    718   1.1.1.3  mrg _Description_:
    719   1.1.1.3  mrg      Set the default device for target regions without device clause.
    720   1.1.1.3  mrg      The argument shall be a nonnegative device number.
    721   1.1.1.3  mrg 
    722   1.1.1.3  mrg _C/C++_:
    723   1.1.1.8  mrg      _Prototype_:   'void omp_set_default_device(int device_num);'
    724   1.1.1.3  mrg 
    725   1.1.1.3  mrg _Fortran_:
    726   1.1.1.8  mrg      _Interface_:   'subroutine omp_set_default_device(device_num)'
    727   1.1.1.8  mrg                     'integer device_num'
    728   1.1.1.3  mrg 
    729   1.1.1.3  mrg _See also_:
    730   1.1.1.3  mrg      *note OMP_DEFAULT_DEVICE::, *note omp_get_default_device::
    731   1.1.1.3  mrg 
    732   1.1.1.3  mrg _Reference_:
    733   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.29.
    734   1.1.1.2  mrg 
    735   1.1.1.2  mrg 
    736   1.1.1.3  mrg File: libgomp.info,  Node: omp_set_dynamic,  Next: omp_set_max_active_levels,  Prev: omp_set_default_device,  Up: Runtime Library Routines
    737   1.1.1.2  mrg 
    738   1.1.1.8  mrg 2.25 'omp_set_dynamic' - Enable/disable dynamic teams
    739       1.1  mrg =====================================================
    740       1.1  mrg 
    741       1.1  mrg _Description_:
    742       1.1  mrg      Enable or disable the dynamic adjustment of the number of threads
    743   1.1.1.3  mrg      within a team.  The function takes the language-specific equivalent
    744   1.1.1.8  mrg      of 'true' and 'false', where 'true' enables dynamic adjustment of
    745   1.1.1.8  mrg      team sizes and 'false' disables it.
    746       1.1  mrg 
    747       1.1  mrg _C/C++_:
    748   1.1.1.8  mrg      _Prototype_:   'void omp_set_dynamic(int dynamic_threads);'
    749       1.1  mrg 
    750       1.1  mrg _Fortran_:
    751   1.1.1.8  mrg      _Interface_:   'subroutine omp_set_dynamic(dynamic_threads)'
    752   1.1.1.8  mrg                     'logical, intent(in) :: dynamic_threads'
    753       1.1  mrg 
    754       1.1  mrg _See also_:
    755       1.1  mrg      *note OMP_DYNAMIC::, *note omp_get_dynamic::
    756       1.1  mrg 
    757       1.1  mrg _Reference_:
    758   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.7.
    759       1.1  mrg 
    760       1.1  mrg 
    761       1.1  mrg File: libgomp.info,  Node: omp_set_max_active_levels,  Next: omp_set_nested,  Prev: omp_set_dynamic,  Up: Runtime Library Routines
    762       1.1  mrg 
    763   1.1.1.8  mrg 2.26 'omp_set_max_active_levels' - Limits the number of active parallel regions
    764       1.1  mrg ===============================================================================
    765       1.1  mrg 
    766       1.1  mrg _Description_:
    767   1.1.1.2  mrg      This function limits the maximum allowed number of nested, active
    768   1.1.1.2  mrg      parallel regions.
    769       1.1  mrg 
    770       1.1  mrg _C/C++_
    771   1.1.1.8  mrg      _Prototype_:   'void omp_set_max_active_levels(int max_levels);'
    772       1.1  mrg 
    773       1.1  mrg _Fortran_:
    774   1.1.1.8  mrg      _Interface_:   'subroutine omp_set_max_active_levels(max_levels)'
    775   1.1.1.8  mrg                     'integer max_levels'
    776       1.1  mrg 
    777       1.1  mrg _See also_:
    778       1.1  mrg      *note omp_get_max_active_levels::, *note omp_get_active_level::
    779       1.1  mrg 
    780       1.1  mrg _Reference_:
    781   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.15.
    782       1.1  mrg 
    783       1.1  mrg 
    784       1.1  mrg File: libgomp.info,  Node: omp_set_nested,  Next: omp_set_num_threads,  Prev: omp_set_max_active_levels,  Up: Runtime Library Routines
    785       1.1  mrg 
    786   1.1.1.8  mrg 2.27 'omp_set_nested' - Enable/disable nested parallel regions
    787       1.1  mrg ==============================================================
    788       1.1  mrg 
    789       1.1  mrg _Description_:
    790       1.1  mrg      Enable or disable nested parallel regions, i.e., whether team
    791   1.1.1.3  mrg      members are allowed to create new teams.  The function takes the
    792   1.1.1.8  mrg      language-specific equivalent of 'true' and 'false', where 'true'
    793   1.1.1.8  mrg      enables dynamic adjustment of team sizes and 'false' disables it.
    794       1.1  mrg 
    795       1.1  mrg _C/C++_:
    796   1.1.1.8  mrg      _Prototype_:   'void omp_set_nested(int nested);'
    797       1.1  mrg 
    798       1.1  mrg _Fortran_:
    799   1.1.1.8  mrg      _Interface_:   'subroutine omp_set_nested(nested)'
    800   1.1.1.8  mrg                     'logical, intent(in) :: nested'
    801       1.1  mrg 
    802       1.1  mrg _See also_:
    803       1.1  mrg      *note OMP_NESTED::, *note omp_get_nested::
    804       1.1  mrg 
    805       1.1  mrg _Reference_:
    806   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.10.
    807       1.1  mrg 
    808       1.1  mrg 
    809       1.1  mrg File: libgomp.info,  Node: omp_set_num_threads,  Next: omp_set_schedule,  Prev: omp_set_nested,  Up: Runtime Library Routines
    810       1.1  mrg 
    811   1.1.1.8  mrg 2.28 'omp_set_num_threads' - Set upper team size limit
    812       1.1  mrg ======================================================
    813       1.1  mrg 
    814       1.1  mrg _Description_:
    815       1.1  mrg      Specifies the number of threads used by default in subsequent
    816   1.1.1.8  mrg      parallel sections, if those do not specify a 'num_threads' clause.
    817   1.1.1.8  mrg      The argument of 'omp_set_num_threads' shall be a positive integer.
    818       1.1  mrg 
    819       1.1  mrg _C/C++_:
    820   1.1.1.8  mrg      _Prototype_:   'void omp_set_num_threads(int num_threads);'
    821       1.1  mrg 
    822       1.1  mrg _Fortran_:
    823   1.1.1.8  mrg      _Interface_:   'subroutine omp_set_num_threads(num_threads)'
    824   1.1.1.8  mrg                     'integer, intent(in) :: num_threads'
    825       1.1  mrg 
    826       1.1  mrg _See also_:
    827       1.1  mrg      *note OMP_NUM_THREADS::, *note omp_get_num_threads::, *note
    828       1.1  mrg      omp_get_max_threads::
    829       1.1  mrg 
    830       1.1  mrg _Reference_:
    831   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.1.
    832       1.1  mrg 
    833       1.1  mrg 
    834       1.1  mrg File: libgomp.info,  Node: omp_set_schedule,  Next: omp_init_lock,  Prev: omp_set_num_threads,  Up: Runtime Library Routines
    835       1.1  mrg 
    836   1.1.1.8  mrg 2.29 'omp_set_schedule' - Set the runtime scheduling method
    837       1.1  mrg ===========================================================
    838       1.1  mrg 
    839       1.1  mrg _Description_:
    840   1.1.1.3  mrg      Sets the runtime scheduling method.  The KIND argument can have the
    841   1.1.1.8  mrg      value 'omp_sched_static', 'omp_sched_dynamic', 'omp_sched_guided'
    842   1.1.1.8  mrg      or 'omp_sched_auto'.  Except for 'omp_sched_auto', the chunk size
    843   1.1.1.5  mrg      is set to the value of CHUNK_SIZE if positive, or to the default
    844   1.1.1.8  mrg      value if zero or negative.  For 'omp_sched_auto' the CHUNK_SIZE
    845       1.1  mrg      argument is ignored.
    846       1.1  mrg 
    847       1.1  mrg _C/C++_
    848   1.1.1.8  mrg      _Prototype_:   'void omp_set_schedule(omp_sched_t kind, int
    849   1.1.1.8  mrg                     chunk_size);'
    850       1.1  mrg 
    851       1.1  mrg _Fortran_:
    852   1.1.1.8  mrg      _Interface_:   'subroutine omp_set_schedule(kind, chunk_size)'
    853   1.1.1.8  mrg                     'integer(kind=omp_sched_kind) kind'
    854   1.1.1.8  mrg                     'integer chunk_size'
    855       1.1  mrg 
    856       1.1  mrg _See also_:
    857       1.1  mrg      *note omp_get_schedule:: *note OMP_SCHEDULE::
    858       1.1  mrg 
    859       1.1  mrg _Reference_:
    860   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.2.12.
    861       1.1  mrg 
    862       1.1  mrg 
    863       1.1  mrg File: libgomp.info,  Node: omp_init_lock,  Next: omp_set_lock,  Prev: omp_set_schedule,  Up: Runtime Library Routines
    864       1.1  mrg 
    865   1.1.1.8  mrg 2.30 'omp_init_lock' - Initialize simple lock
    866       1.1  mrg =============================================
    867       1.1  mrg 
    868       1.1  mrg _Description_:
    869   1.1.1.2  mrg      Initialize a simple lock.  After initialization, the lock is in an
    870       1.1  mrg      unlocked state.
    871       1.1  mrg 
    872       1.1  mrg _C/C++_:
    873   1.1.1.8  mrg      _Prototype_:   'void omp_init_lock(omp_lock_t *lock);'
    874       1.1  mrg 
    875       1.1  mrg _Fortran_:
    876   1.1.1.8  mrg      _Interface_:   'subroutine omp_init_lock(svar)'
    877   1.1.1.8  mrg                     'integer(omp_lock_kind), intent(out) :: svar'
    878       1.1  mrg 
    879       1.1  mrg _See also_:
    880       1.1  mrg      *note omp_destroy_lock::
    881       1.1  mrg 
    882       1.1  mrg _Reference_:
    883   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.3.1.
    884       1.1  mrg 
    885       1.1  mrg 
    886       1.1  mrg File: libgomp.info,  Node: omp_set_lock,  Next: omp_test_lock,  Prev: omp_init_lock,  Up: Runtime Library Routines
    887       1.1  mrg 
    888   1.1.1.8  mrg 2.31 'omp_set_lock' - Wait for and set simple lock
    889       1.1  mrg ==================================================
    890       1.1  mrg 
    891       1.1  mrg _Description_:
    892   1.1.1.8  mrg      Before setting a simple lock, the lock variable must be initialized
    893   1.1.1.8  mrg      by 'omp_init_lock'.  The calling thread is blocked until the lock
    894   1.1.1.8  mrg      is available.  If the lock is already held by the current thread, a
    895   1.1.1.8  mrg      deadlock occurs.
    896       1.1  mrg 
    897       1.1  mrg _C/C++_:
    898   1.1.1.8  mrg      _Prototype_:   'void omp_set_lock(omp_lock_t *lock);'
    899       1.1  mrg 
    900       1.1  mrg _Fortran_:
    901   1.1.1.8  mrg      _Interface_:   'subroutine omp_set_lock(svar)'
    902   1.1.1.8  mrg                     'integer(omp_lock_kind), intent(inout) :: svar'
    903       1.1  mrg 
    904       1.1  mrg _See also_:
    905       1.1  mrg      *note omp_init_lock::, *note omp_test_lock::, *note
    906       1.1  mrg      omp_unset_lock::
    907       1.1  mrg 
    908       1.1  mrg _Reference_:
    909   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.3.4.
    910       1.1  mrg 
    911       1.1  mrg 
    912       1.1  mrg File: libgomp.info,  Node: omp_test_lock,  Next: omp_unset_lock,  Prev: omp_set_lock,  Up: Runtime Library Routines
    913       1.1  mrg 
    914   1.1.1.8  mrg 2.32 'omp_test_lock' - Test and set simple lock if available
    915       1.1  mrg ============================================================
    916       1.1  mrg 
    917       1.1  mrg _Description_:
    918   1.1.1.8  mrg      Before setting a simple lock, the lock variable must be initialized
    919   1.1.1.8  mrg      by 'omp_init_lock'.  Contrary to 'omp_set_lock', 'omp_test_lock'
    920   1.1.1.8  mrg      does not block if the lock is not available.  This function returns
    921   1.1.1.8  mrg      'true' upon success, 'false' otherwise.  Here, 'true' and 'false'
    922   1.1.1.8  mrg      represent their language-specific counterparts.
    923       1.1  mrg 
    924       1.1  mrg _C/C++_:
    925   1.1.1.8  mrg      _Prototype_:   'int omp_test_lock(omp_lock_t *lock);'
    926       1.1  mrg 
    927       1.1  mrg _Fortran_:
    928   1.1.1.8  mrg      _Interface_:   'logical function omp_test_lock(svar)'
    929   1.1.1.8  mrg                     'integer(omp_lock_kind), intent(inout) :: svar'
    930       1.1  mrg 
    931       1.1  mrg _See also_:
    932       1.1  mrg      *note omp_init_lock::, *note omp_set_lock::, *note omp_set_lock::
    933       1.1  mrg 
    934       1.1  mrg _Reference_:
    935   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.3.6.
    936       1.1  mrg 
    937       1.1  mrg 
    938       1.1  mrg File: libgomp.info,  Node: omp_unset_lock,  Next: omp_destroy_lock,  Prev: omp_test_lock,  Up: Runtime Library Routines
    939       1.1  mrg 
    940   1.1.1.8  mrg 2.33 'omp_unset_lock' - Unset simple lock
    941       1.1  mrg =========================================
    942       1.1  mrg 
    943       1.1  mrg _Description_:
    944       1.1  mrg      A simple lock about to be unset must have been locked by
    945   1.1.1.8  mrg      'omp_set_lock' or 'omp_test_lock' before.  In addition, the lock
    946   1.1.1.8  mrg      must be held by the thread calling 'omp_unset_lock'.  Then, the
    947   1.1.1.8  mrg      lock becomes unlocked.  If one or more threads attempted to set the
    948   1.1.1.8  mrg      lock before, one of them is chosen to, again, set the lock to
    949       1.1  mrg      itself.
    950       1.1  mrg 
    951       1.1  mrg _C/C++_:
    952   1.1.1.8  mrg      _Prototype_:   'void omp_unset_lock(omp_lock_t *lock);'
    953       1.1  mrg 
    954       1.1  mrg _Fortran_:
    955   1.1.1.8  mrg      _Interface_:   'subroutine omp_unset_lock(svar)'
    956   1.1.1.8  mrg                     'integer(omp_lock_kind), intent(inout) :: svar'
    957       1.1  mrg 
    958       1.1  mrg _See also_:
    959       1.1  mrg      *note omp_set_lock::, *note omp_test_lock::
    960       1.1  mrg 
    961       1.1  mrg _Reference_:
    962   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.3.5.
    963       1.1  mrg 
    964       1.1  mrg 
    965       1.1  mrg File: libgomp.info,  Node: omp_destroy_lock,  Next: omp_init_nest_lock,  Prev: omp_unset_lock,  Up: Runtime Library Routines
    966       1.1  mrg 
    967   1.1.1.8  mrg 2.34 'omp_destroy_lock' - Destroy simple lock
    968       1.1  mrg =============================================
    969       1.1  mrg 
    970       1.1  mrg _Description_:
    971   1.1.1.3  mrg      Destroy a simple lock.  In order to be destroyed, a simple lock
    972       1.1  mrg      must be in the unlocked state.
    973       1.1  mrg 
    974       1.1  mrg _C/C++_:
    975   1.1.1.8  mrg      _Prototype_:   'void omp_destroy_lock(omp_lock_t *lock);'
    976       1.1  mrg 
    977       1.1  mrg _Fortran_:
    978   1.1.1.8  mrg      _Interface_:   'subroutine omp_destroy_lock(svar)'
    979   1.1.1.8  mrg                     'integer(omp_lock_kind), intent(inout) :: svar'
    980       1.1  mrg 
    981       1.1  mrg _See also_:
    982       1.1  mrg      *note omp_init_lock::
    983       1.1  mrg 
    984       1.1  mrg _Reference_:
    985   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.3.3.
    986       1.1  mrg 
    987       1.1  mrg 
    988       1.1  mrg File: libgomp.info,  Node: omp_init_nest_lock,  Next: omp_set_nest_lock,  Prev: omp_destroy_lock,  Up: Runtime Library Routines
    989       1.1  mrg 
    990   1.1.1.8  mrg 2.35 'omp_init_nest_lock' - Initialize nested lock
    991       1.1  mrg ==================================================
    992       1.1  mrg 
    993       1.1  mrg _Description_:
    994   1.1.1.2  mrg      Initialize a nested lock.  After initialization, the lock is in an
    995       1.1  mrg      unlocked state and the nesting count is set to zero.
    996       1.1  mrg 
    997       1.1  mrg _C/C++_:
    998   1.1.1.8  mrg      _Prototype_:   'void omp_init_nest_lock(omp_nest_lock_t *lock);'
    999       1.1  mrg 
   1000       1.1  mrg _Fortran_:
   1001   1.1.1.8  mrg      _Interface_:   'subroutine omp_init_nest_lock(nvar)'
   1002   1.1.1.8  mrg                     'integer(omp_nest_lock_kind), intent(out) :: nvar'
   1003       1.1  mrg 
   1004       1.1  mrg _See also_:
   1005       1.1  mrg      *note omp_destroy_nest_lock::
   1006       1.1  mrg 
   1007       1.1  mrg _Reference_:
   1008   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.3.1.
   1009       1.1  mrg 
   1010       1.1  mrg 
   1011       1.1  mrg File: libgomp.info,  Node: omp_set_nest_lock,  Next: omp_test_nest_lock,  Prev: omp_init_nest_lock,  Up: Runtime Library Routines
   1012       1.1  mrg 
   1013   1.1.1.8  mrg 2.36 'omp_set_nest_lock' - Wait for and set nested lock
   1014       1.1  mrg =======================================================
   1015       1.1  mrg 
   1016       1.1  mrg _Description_:
   1017   1.1.1.8  mrg      Before setting a nested lock, the lock variable must be initialized
   1018   1.1.1.8  mrg      by 'omp_init_nest_lock'.  The calling thread is blocked until the
   1019   1.1.1.8  mrg      lock is available.  If the lock is already held by the current
   1020   1.1.1.8  mrg      thread, the nesting count for the lock is incremented.
   1021       1.1  mrg 
   1022       1.1  mrg _C/C++_:
   1023   1.1.1.8  mrg      _Prototype_:   'void omp_set_nest_lock(omp_nest_lock_t *lock);'
   1024       1.1  mrg 
   1025       1.1  mrg _Fortran_:
   1026   1.1.1.8  mrg      _Interface_:   'subroutine omp_set_nest_lock(nvar)'
   1027   1.1.1.8  mrg                     'integer(omp_nest_lock_kind), intent(inout) :: nvar'
   1028       1.1  mrg 
   1029       1.1  mrg _See also_:
   1030       1.1  mrg      *note omp_init_nest_lock::, *note omp_unset_nest_lock::
   1031       1.1  mrg 
   1032       1.1  mrg _Reference_:
   1033   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.3.4.
   1034       1.1  mrg 
   1035       1.1  mrg 
   1036       1.1  mrg File: libgomp.info,  Node: omp_test_nest_lock,  Next: omp_unset_nest_lock,  Prev: omp_set_nest_lock,  Up: Runtime Library Routines
   1037       1.1  mrg 
   1038   1.1.1.8  mrg 2.37 'omp_test_nest_lock' - Test and set nested lock if available
   1039       1.1  mrg =================================================================
   1040       1.1  mrg 
   1041       1.1  mrg _Description_:
   1042   1.1.1.8  mrg      Before setting a nested lock, the lock variable must be initialized
   1043   1.1.1.8  mrg      by 'omp_init_nest_lock'.  Contrary to 'omp_set_nest_lock',
   1044   1.1.1.8  mrg      'omp_test_nest_lock' does not block if the lock is not available.
   1045   1.1.1.8  mrg      If the lock is already held by the current thread, the new nesting
   1046   1.1.1.8  mrg      count is returned.  Otherwise, the return value equals zero.
   1047       1.1  mrg 
   1048       1.1  mrg _C/C++_:
   1049   1.1.1.8  mrg      _Prototype_:   'int omp_test_nest_lock(omp_nest_lock_t *lock);'
   1050       1.1  mrg 
   1051       1.1  mrg _Fortran_:
   1052   1.1.1.8  mrg      _Interface_:   'logical function omp_test_nest_lock(nvar)'
   1053   1.1.1.8  mrg                     'integer(omp_nest_lock_kind), intent(inout) :: nvar'
   1054       1.1  mrg 
   1055       1.1  mrg _See also_:
   1056       1.1  mrg      *note omp_init_lock::, *note omp_set_lock::, *note omp_set_lock::
   1057       1.1  mrg 
   1058       1.1  mrg _Reference_:
   1059   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.3.6.
   1060       1.1  mrg 
   1061       1.1  mrg 
   1062       1.1  mrg File: libgomp.info,  Node: omp_unset_nest_lock,  Next: omp_destroy_nest_lock,  Prev: omp_test_nest_lock,  Up: Runtime Library Routines
   1063       1.1  mrg 
   1064   1.1.1.8  mrg 2.38 'omp_unset_nest_lock' - Unset nested lock
   1065       1.1  mrg ==============================================
   1066       1.1  mrg 
   1067       1.1  mrg _Description_:
   1068       1.1  mrg      A nested lock about to be unset must have been locked by
   1069   1.1.1.8  mrg      'omp_set_nested_lock' or 'omp_test_nested_lock' before.  In
   1070       1.1  mrg      addition, the lock must be held by the thread calling
   1071   1.1.1.8  mrg      'omp_unset_nested_lock'.  If the nesting count drops to zero, the
   1072   1.1.1.3  mrg      lock becomes unlocked.  If one ore more threads attempted to set
   1073   1.1.1.2  mrg      the lock before, one of them is chosen to, again, set the lock to
   1074       1.1  mrg      itself.
   1075       1.1  mrg 
   1076       1.1  mrg _C/C++_:
   1077   1.1.1.8  mrg      _Prototype_:   'void omp_unset_nest_lock(omp_nest_lock_t *lock);'
   1078       1.1  mrg 
   1079       1.1  mrg _Fortran_:
   1080   1.1.1.8  mrg      _Interface_:   'subroutine omp_unset_nest_lock(nvar)'
   1081   1.1.1.8  mrg                     'integer(omp_nest_lock_kind), intent(inout) :: nvar'
   1082       1.1  mrg 
   1083       1.1  mrg _See also_:
   1084       1.1  mrg      *note omp_set_nest_lock::
   1085       1.1  mrg 
   1086       1.1  mrg _Reference_:
   1087   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.3.5.
   1088       1.1  mrg 
   1089       1.1  mrg 
   1090       1.1  mrg File: libgomp.info,  Node: omp_destroy_nest_lock,  Next: omp_get_wtick,  Prev: omp_unset_nest_lock,  Up: Runtime Library Routines
   1091       1.1  mrg 
   1092   1.1.1.8  mrg 2.39 'omp_destroy_nest_lock' - Destroy nested lock
   1093       1.1  mrg ==================================================
   1094       1.1  mrg 
   1095       1.1  mrg _Description_:
   1096   1.1.1.3  mrg      Destroy a nested lock.  In order to be destroyed, a nested lock
   1097       1.1  mrg      must be in the unlocked state and its nesting count must equal
   1098       1.1  mrg      zero.
   1099       1.1  mrg 
   1100       1.1  mrg _C/C++_:
   1101   1.1.1.8  mrg      _Prototype_:   'void omp_destroy_nest_lock(omp_nest_lock_t *);'
   1102       1.1  mrg 
   1103       1.1  mrg _Fortran_:
   1104   1.1.1.8  mrg      _Interface_:   'subroutine omp_destroy_nest_lock(nvar)'
   1105   1.1.1.8  mrg                     'integer(omp_nest_lock_kind), intent(inout) :: nvar'
   1106       1.1  mrg 
   1107       1.1  mrg _See also_:
   1108       1.1  mrg      *note omp_init_lock::
   1109       1.1  mrg 
   1110       1.1  mrg _Reference_:
   1111   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.3.3.
   1112       1.1  mrg 
   1113       1.1  mrg 
   1114       1.1  mrg File: libgomp.info,  Node: omp_get_wtick,  Next: omp_get_wtime,  Prev: omp_destroy_nest_lock,  Up: Runtime Library Routines
   1115       1.1  mrg 
   1116   1.1.1.8  mrg 2.40 'omp_get_wtick' - Get timer precision
   1117       1.1  mrg ==========================================
   1118       1.1  mrg 
   1119       1.1  mrg _Description_:
   1120       1.1  mrg      Gets the timer precision, i.e., the number of seconds between two
   1121       1.1  mrg      successive clock ticks.
   1122       1.1  mrg 
   1123       1.1  mrg _C/C++_:
   1124   1.1.1.8  mrg      _Prototype_:   'double omp_get_wtick(void);'
   1125       1.1  mrg 
   1126       1.1  mrg _Fortran_:
   1127   1.1.1.8  mrg      _Interface_:   'double precision function omp_get_wtick()'
   1128       1.1  mrg 
   1129       1.1  mrg _See also_:
   1130       1.1  mrg      *note omp_get_wtime::
   1131       1.1  mrg 
   1132       1.1  mrg _Reference_:
   1133   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.4.2.
   1134       1.1  mrg 
   1135       1.1  mrg 
   1136       1.1  mrg File: libgomp.info,  Node: omp_get_wtime,  Prev: omp_get_wtick,  Up: Runtime Library Routines
   1137       1.1  mrg 
   1138   1.1.1.8  mrg 2.41 'omp_get_wtime' - Elapsed wall clock time
   1139       1.1  mrg ==============================================
   1140       1.1  mrg 
   1141       1.1  mrg _Description_:
   1142   1.1.1.3  mrg      Elapsed wall clock time in seconds.  The time is measured per
   1143   1.1.1.2  mrg      thread, no guarantee can be made that two distinct threads measure
   1144   1.1.1.2  mrg      the same time.  Time is measured from some "time in the past",
   1145   1.1.1.2  mrg      which is an arbitrary time guaranteed not to change during the
   1146   1.1.1.2  mrg      execution of the program.
   1147       1.1  mrg 
   1148       1.1  mrg _C/C++_:
   1149   1.1.1.8  mrg      _Prototype_:   'double omp_get_wtime(void);'
   1150       1.1  mrg 
   1151       1.1  mrg _Fortran_:
   1152   1.1.1.8  mrg      _Interface_:   'double precision function omp_get_wtime()'
   1153       1.1  mrg 
   1154       1.1  mrg _See also_:
   1155       1.1  mrg      *note omp_get_wtick::
   1156       1.1  mrg 
   1157       1.1  mrg _Reference_:
   1158   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 3.4.1.
   1159       1.1  mrg 
   1160       1.1  mrg 
   1161   1.1.1.5  mrg File: libgomp.info,  Node: Environment Variables,  Next: Enabling OpenACC,  Prev: Runtime Library Routines,  Up: Top
   1162       1.1  mrg 
   1163   1.1.1.9  mrg 3 OpenMP Environment Variables
   1164   1.1.1.9  mrg ******************************
   1165       1.1  mrg 
   1166   1.1.1.8  mrg The environment variables which beginning with 'OMP_' are defined by
   1167   1.1.1.5  mrg section 4 of the OpenMP specification in version 4.5, while those
   1168   1.1.1.8  mrg beginning with 'GOMP_' are GNU extensions.
   1169       1.1  mrg 
   1170       1.1  mrg * Menu:
   1171       1.1  mrg 
   1172   1.1.1.5  mrg * OMP_CANCELLATION::        Set whether cancellation is activated
   1173   1.1.1.5  mrg * OMP_DISPLAY_ENV::         Show OpenMP version and environment variables
   1174   1.1.1.5  mrg * OMP_DEFAULT_DEVICE::      Set the device used in target regions
   1175   1.1.1.5  mrg * OMP_DYNAMIC::             Dynamic adjustment of threads
   1176   1.1.1.5  mrg * OMP_MAX_ACTIVE_LEVELS::   Set the maximum number of nested parallel regions
   1177   1.1.1.5  mrg * OMP_MAX_TASK_PRIORITY::   Set the maximum task priority value
   1178   1.1.1.5  mrg * OMP_NESTED::              Nested parallel regions
   1179   1.1.1.5  mrg * OMP_NUM_THREADS::         Specifies the number of threads to use
   1180  1.1.1.11  mrg * OMP_PROC_BIND::           Whether threads may be moved between CPUs
   1181  1.1.1.11  mrg * OMP_PLACES::              Specifies on which CPUs the threads should be placed
   1182   1.1.1.5  mrg * OMP_STACKSIZE::           Set default thread stack size
   1183   1.1.1.5  mrg * OMP_SCHEDULE::            How threads are scheduled
   1184   1.1.1.5  mrg * OMP_THREAD_LIMIT::        Set the maximum number of threads
   1185   1.1.1.5  mrg * OMP_WAIT_POLICY::         How waiting threads are handled
   1186   1.1.1.5  mrg * GOMP_CPU_AFFINITY::       Bind threads to specific CPUs
   1187   1.1.1.5  mrg * GOMP_DEBUG::              Enable debugging output
   1188   1.1.1.5  mrg * GOMP_STACKSIZE::          Set default thread stack size
   1189   1.1.1.5  mrg * GOMP_SPINCOUNT::          Set the busy-wait spin count
   1190   1.1.1.5  mrg * GOMP_RTEMS_THREAD_POOLS:: Set the RTEMS specific thread pools
   1191       1.1  mrg 
   1192       1.1  mrg 
   1193   1.1.1.3  mrg File: libgomp.info,  Node: OMP_CANCELLATION,  Next: OMP_DISPLAY_ENV,  Up: Environment Variables
   1194   1.1.1.3  mrg 
   1195   1.1.1.8  mrg 3.1 'OMP_CANCELLATION' - Set whether cancellation is activated
   1196   1.1.1.3  mrg ==============================================================
   1197   1.1.1.3  mrg 
   1198   1.1.1.3  mrg _Description_:
   1199   1.1.1.8  mrg      If set to 'TRUE', the cancellation is activated.  If set to 'FALSE'
   1200   1.1.1.8  mrg      or if unset, cancellation is disabled and the 'cancel' construct is
   1201   1.1.1.8  mrg      ignored.
   1202   1.1.1.3  mrg 
   1203   1.1.1.3  mrg _See also_:
   1204   1.1.1.3  mrg      *note omp_get_cancellation::
   1205       1.1  mrg 
   1206   1.1.1.3  mrg _Reference_:
   1207   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.11
   1208   1.1.1.3  mrg 
   1209   1.1.1.3  mrg 
   1210   1.1.1.3  mrg File: libgomp.info,  Node: OMP_DISPLAY_ENV,  Next: OMP_DEFAULT_DEVICE,  Prev: OMP_CANCELLATION,  Up: Environment Variables
   1211   1.1.1.3  mrg 
   1212   1.1.1.8  mrg 3.2 'OMP_DISPLAY_ENV' - Show OpenMP version and environment variables
   1213   1.1.1.3  mrg =====================================================================
   1214   1.1.1.3  mrg 
   1215   1.1.1.3  mrg _Description_:
   1216   1.1.1.8  mrg      If set to 'TRUE', the OpenMP version number and the values
   1217   1.1.1.3  mrg      associated with the OpenMP environment variables are printed to
   1218   1.1.1.8  mrg      'stderr'.  If set to 'VERBOSE', it additionally shows the value of
   1219   1.1.1.3  mrg      the environment variables which are GNU extensions.  If undefined
   1220   1.1.1.8  mrg      or set to 'FALSE', this information will not be shown.
   1221   1.1.1.3  mrg 
   1222   1.1.1.3  mrg _Reference_:
   1223   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.12
   1224   1.1.1.3  mrg 
   1225   1.1.1.3  mrg 
   1226   1.1.1.3  mrg File: libgomp.info,  Node: OMP_DEFAULT_DEVICE,  Next: OMP_DYNAMIC,  Prev: OMP_DISPLAY_ENV,  Up: Environment Variables
   1227   1.1.1.3  mrg 
   1228   1.1.1.8  mrg 3.3 'OMP_DEFAULT_DEVICE' - Set the device used in target regions
   1229   1.1.1.3  mrg ================================================================
   1230   1.1.1.3  mrg 
   1231   1.1.1.3  mrg _Description_:
   1232   1.1.1.8  mrg      Set to choose the device which is used in a 'target' region, unless
   1233   1.1.1.8  mrg      the value is overridden by 'omp_set_default_device' or by a
   1234   1.1.1.8  mrg      'device' clause.  The value shall be the nonnegative device number.
   1235   1.1.1.8  mrg      If no device with the given device number exists, the code is
   1236   1.1.1.8  mrg      executed on the host.  If unset, device number 0 will be used.
   1237   1.1.1.3  mrg 
   1238   1.1.1.3  mrg _See also_:
   1239   1.1.1.3  mrg      *note omp_get_default_device::, *note omp_set_default_device::,
   1240   1.1.1.3  mrg 
   1241   1.1.1.3  mrg _Reference_:
   1242   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.13
   1243   1.1.1.3  mrg 
   1244   1.1.1.3  mrg 
   1245   1.1.1.3  mrg File: libgomp.info,  Node: OMP_DYNAMIC,  Next: OMP_MAX_ACTIVE_LEVELS,  Prev: OMP_DEFAULT_DEVICE,  Up: Environment Variables
   1246   1.1.1.3  mrg 
   1247   1.1.1.8  mrg 3.4 'OMP_DYNAMIC' - Dynamic adjustment of threads
   1248       1.1  mrg =================================================
   1249       1.1  mrg 
   1250       1.1  mrg _Description_:
   1251       1.1  mrg      Enable or disable the dynamic adjustment of the number of threads
   1252   1.1.1.3  mrg      within a team.  The value of this environment variable shall be
   1253   1.1.1.8  mrg      'TRUE' or 'FALSE'.  If undefined, dynamic adjustment is disabled by
   1254   1.1.1.8  mrg      default.
   1255       1.1  mrg 
   1256       1.1  mrg _See also_:
   1257       1.1  mrg      *note omp_set_dynamic::
   1258       1.1  mrg 
   1259       1.1  mrg _Reference_:
   1260   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.3
   1261       1.1  mrg 
   1262       1.1  mrg 
   1263   1.1.1.5  mrg File: libgomp.info,  Node: OMP_MAX_ACTIVE_LEVELS,  Next: OMP_MAX_TASK_PRIORITY,  Prev: OMP_DYNAMIC,  Up: Environment Variables
   1264       1.1  mrg 
   1265   1.1.1.8  mrg 3.5 'OMP_MAX_ACTIVE_LEVELS' - Set the maximum number of nested parallel regions
   1266       1.1  mrg ===============================================================================
   1267       1.1  mrg 
   1268       1.1  mrg _Description_:
   1269   1.1.1.2  mrg      Specifies the initial value for the maximum number of nested
   1270   1.1.1.3  mrg      parallel regions.  The value of this variable shall be a positive
   1271       1.1  mrg      integer.  If undefined, the number of active levels is unlimited.
   1272       1.1  mrg 
   1273       1.1  mrg _See also_:
   1274       1.1  mrg      *note omp_set_max_active_levels::
   1275       1.1  mrg 
   1276       1.1  mrg _Reference_:
   1277   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.9
   1278       1.1  mrg 
   1279       1.1  mrg 
   1280   1.1.1.5  mrg File: libgomp.info,  Node: OMP_MAX_TASK_PRIORITY,  Next: OMP_NESTED,  Prev: OMP_MAX_ACTIVE_LEVELS,  Up: Environment Variables
   1281   1.1.1.5  mrg 
   1282   1.1.1.8  mrg 3.6 'OMP_MAX_TASK_PRIORITY' - Set the maximum priority
   1283   1.1.1.5  mrg ======================================================
   1284   1.1.1.5  mrg 
   1285   1.1.1.8  mrg number that can be set for a task.
   1286   1.1.1.5  mrg _Description_:
   1287   1.1.1.8  mrg      Specifies the initial value for the maximum priority value that can
   1288   1.1.1.8  mrg      be set for a task.  The value of this variable shall be a
   1289   1.1.1.5  mrg      non-negative integer, and zero is allowed.  If undefined, the
   1290   1.1.1.5  mrg      default priority is 0.
   1291   1.1.1.5  mrg 
   1292   1.1.1.5  mrg _See also_:
   1293   1.1.1.5  mrg      *note omp_get_max_task_priority::
   1294       1.1  mrg 
   1295   1.1.1.5  mrg _Reference_:
   1296   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.14
   1297   1.1.1.5  mrg 
   1298   1.1.1.5  mrg 
   1299   1.1.1.5  mrg File: libgomp.info,  Node: OMP_NESTED,  Next: OMP_NUM_THREADS,  Prev: OMP_MAX_TASK_PRIORITY,  Up: Environment Variables
   1300   1.1.1.5  mrg 
   1301   1.1.1.8  mrg 3.7 'OMP_NESTED' - Nested parallel regions
   1302       1.1  mrg ==========================================
   1303       1.1  mrg 
   1304       1.1  mrg _Description_:
   1305       1.1  mrg      Enable or disable nested parallel regions, i.e., whether team
   1306   1.1.1.3  mrg      members are allowed to create new teams.  The value of this
   1307   1.1.1.8  mrg      environment variable shall be 'TRUE' or 'FALSE'.  If undefined,
   1308       1.1  mrg      nested parallel regions are disabled by default.
   1309       1.1  mrg 
   1310       1.1  mrg _See also_:
   1311       1.1  mrg      *note omp_set_nested::
   1312       1.1  mrg 
   1313       1.1  mrg _Reference_:
   1314   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.6
   1315       1.1  mrg 
   1316       1.1  mrg 
   1317   1.1.1.3  mrg File: libgomp.info,  Node: OMP_NUM_THREADS,  Next: OMP_PROC_BIND,  Prev: OMP_NESTED,  Up: Environment Variables
   1318       1.1  mrg 
   1319   1.1.1.8  mrg 3.8 'OMP_NUM_THREADS' - Specifies the number of threads to use
   1320       1.1  mrg ==============================================================
   1321       1.1  mrg 
   1322       1.1  mrg _Description_:
   1323   1.1.1.8  mrg      Specifies the default number of threads to use in parallel regions.
   1324   1.1.1.8  mrg      The value of this variable shall be a comma-separated list of
   1325   1.1.1.8  mrg      positive integers; the value specified the number of threads to use
   1326   1.1.1.8  mrg      for the corresponding nested level.  If undefined one thread per
   1327   1.1.1.8  mrg      CPU is used.
   1328       1.1  mrg 
   1329       1.1  mrg _See also_:
   1330       1.1  mrg      *note omp_set_num_threads::
   1331       1.1  mrg 
   1332       1.1  mrg _Reference_:
   1333   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.2
   1334       1.1  mrg 
   1335       1.1  mrg 
   1336   1.1.1.3  mrg File: libgomp.info,  Node: OMP_PROC_BIND,  Next: OMP_PLACES,  Prev: OMP_NUM_THREADS,  Up: Environment Variables
   1337       1.1  mrg 
   1338  1.1.1.11  mrg 3.9 'OMP_PROC_BIND' - Whether threads may be moved between CPUs
   1339  1.1.1.11  mrg ===============================================================
   1340       1.1  mrg 
   1341       1.1  mrg _Description_:
   1342   1.1.1.3  mrg      Specifies whether threads may be moved between processors.  If set
   1343  1.1.1.11  mrg      to 'TRUE', OpenMP threads should not be moved; if set to 'FALSE'
   1344   1.1.1.3  mrg      they may be moved.  Alternatively, a comma separated list with the
   1345   1.1.1.8  mrg      values 'MASTER', 'CLOSE' and 'SPREAD' can be used to specify the
   1346   1.1.1.3  mrg      thread affinity policy for the corresponding nesting level.  With
   1347   1.1.1.8  mrg      'MASTER' the worker threads are in the same place partition as the
   1348   1.1.1.8  mrg      master thread.  With 'CLOSE' those are kept close to the master
   1349   1.1.1.8  mrg      thread in contiguous place partitions.  And with 'SPREAD' a sparse
   1350   1.1.1.3  mrg      distribution across the place partitions is used.
   1351   1.1.1.3  mrg 
   1352   1.1.1.8  mrg      When undefined, 'OMP_PROC_BIND' defaults to 'TRUE' when
   1353   1.1.1.8  mrg      'OMP_PLACES' or 'GOMP_CPU_AFFINITY' is set and 'FALSE' otherwise.
   1354       1.1  mrg 
   1355       1.1  mrg _See also_:
   1356   1.1.1.3  mrg      *note OMP_PLACES::, *note GOMP_CPU_AFFINITY::, *note
   1357   1.1.1.3  mrg      omp_get_proc_bind::
   1358   1.1.1.3  mrg 
   1359   1.1.1.3  mrg _Reference_:
   1360   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.4
   1361   1.1.1.3  mrg 
   1362   1.1.1.3  mrg 
   1363   1.1.1.3  mrg File: libgomp.info,  Node: OMP_PLACES,  Next: OMP_STACKSIZE,  Prev: OMP_PROC_BIND,  Up: Environment Variables
   1364   1.1.1.3  mrg 
   1365  1.1.1.11  mrg 3.10 'OMP_PLACES' - Specifies on which CPUs the threads should be placed
   1366  1.1.1.11  mrg ========================================================================
   1367   1.1.1.3  mrg 
   1368   1.1.1.3  mrg _Description_:
   1369   1.1.1.8  mrg      The thread placement can be either specified using an abstract name
   1370   1.1.1.8  mrg      or by an explicit list of the places.  The abstract names
   1371   1.1.1.8  mrg      'threads', 'cores' and 'sockets' can be optionally followed by a
   1372   1.1.1.3  mrg      positive number in parentheses, which denotes the how many places
   1373   1.1.1.8  mrg      shall be created.  With 'threads' each place corresponds to a
   1374   1.1.1.8  mrg      single hardware thread; 'cores' to a single core with the
   1375   1.1.1.8  mrg      corresponding number of hardware threads; and with 'sockets' the
   1376   1.1.1.3  mrg      place corresponds to a single socket.  The resulting placement can
   1377   1.1.1.8  mrg      be shown by setting the 'OMP_DISPLAY_ENV' environment variable.
   1378   1.1.1.3  mrg 
   1379   1.1.1.3  mrg      Alternatively, the placement can be specified explicitly as
   1380   1.1.1.3  mrg      comma-separated list of places.  A place is specified by set of
   1381   1.1.1.3  mrg      nonnegative numbers in curly braces, denoting the denoting the
   1382   1.1.1.3  mrg      hardware threads.  The hardware threads belonging to a place can
   1383   1.1.1.3  mrg      either be specified as comma-separated list of nonnegative thread
   1384   1.1.1.3  mrg      numbers or using an interval.  Multiple places can also be either
   1385   1.1.1.3  mrg      specified by a comma-separated list of places or by an interval.
   1386   1.1.1.3  mrg      To specify an interval, a colon followed by the count is placed
   1387   1.1.1.3  mrg      after after the hardware thread number or the place.  Optionally,
   1388   1.1.1.3  mrg      the length can be followed by a colon and the stride number -
   1389   1.1.1.3  mrg      otherwise a unit stride is assumed.  For instance, the following
   1390   1.1.1.8  mrg      specifies the same places list: '"{0,1,2}, {3,4,6}, {7,8,9},
   1391   1.1.1.8  mrg      {10,11,12}"'; '"{0:3}, {3:3}, {7:3}, {10:3}"'; and '"{0:2}:4:3"'.
   1392   1.1.1.3  mrg 
   1393   1.1.1.8  mrg      If 'OMP_PLACES' and 'GOMP_CPU_AFFINITY' are unset and
   1394   1.1.1.8  mrg      'OMP_PROC_BIND' is either unset or 'false', threads may be moved
   1395   1.1.1.3  mrg      between CPUs following no placement policy.
   1396   1.1.1.3  mrg 
   1397   1.1.1.3  mrg _See also_:
   1398   1.1.1.3  mrg      *note OMP_PROC_BIND::, *note GOMP_CPU_AFFINITY::, *note
   1399   1.1.1.3  mrg      omp_get_proc_bind::, *note OMP_DISPLAY_ENV::
   1400       1.1  mrg 
   1401       1.1  mrg _Reference_:
   1402   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.5
   1403       1.1  mrg 
   1404       1.1  mrg 
   1405   1.1.1.3  mrg File: libgomp.info,  Node: OMP_STACKSIZE,  Next: OMP_SCHEDULE,  Prev: OMP_PLACES,  Up: Environment Variables
   1406       1.1  mrg 
   1407   1.1.1.8  mrg 3.11 'OMP_STACKSIZE' - Set default thread stack size
   1408   1.1.1.3  mrg ====================================================
   1409       1.1  mrg 
   1410       1.1  mrg _Description_:
   1411       1.1  mrg      Set the default thread stack size in kilobytes, unless the number
   1412   1.1.1.8  mrg      is suffixed by 'B', 'K', 'M' or 'G', in which case the size is,
   1413   1.1.1.8  mrg      respectively, in bytes, kilobytes, megabytes or gigabytes.  This is
   1414   1.1.1.8  mrg      different from 'pthread_attr_setstacksize' which gets the number of
   1415   1.1.1.8  mrg      bytes as an argument.  If the stack size cannot be set due to
   1416   1.1.1.8  mrg      system constraints, an error is reported and the initial stack size
   1417   1.1.1.8  mrg      is left unchanged.  If undefined, the stack size is system
   1418   1.1.1.8  mrg      dependent.
   1419       1.1  mrg 
   1420       1.1  mrg _Reference_:
   1421   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.7
   1422       1.1  mrg 
   1423       1.1  mrg 
   1424   1.1.1.3  mrg File: libgomp.info,  Node: OMP_SCHEDULE,  Next: OMP_THREAD_LIMIT,  Prev: OMP_STACKSIZE,  Up: Environment Variables
   1425       1.1  mrg 
   1426   1.1.1.8  mrg 3.12 'OMP_SCHEDULE' - How threads are scheduled
   1427   1.1.1.3  mrg ===============================================
   1428       1.1  mrg 
   1429       1.1  mrg _Description_:
   1430   1.1.1.8  mrg      Allows to specify 'schedule type' and 'chunk size'.  The value of
   1431   1.1.1.8  mrg      the variable shall have the form: 'type[,chunk]' where 'type' is
   1432   1.1.1.8  mrg      one of 'static', 'dynamic', 'guided' or 'auto' The optional 'chunk'
   1433   1.1.1.8  mrg      size shall be a positive integer.  If undefined, dynamic scheduling
   1434   1.1.1.8  mrg      and a chunk size of 1 is used.
   1435       1.1  mrg 
   1436       1.1  mrg _See also_:
   1437   1.1.1.3  mrg      *note omp_set_schedule::
   1438       1.1  mrg 
   1439       1.1  mrg _Reference_:
   1440   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Sections
   1441   1.1.1.5  mrg      2.7.1.1 and 4.1
   1442       1.1  mrg 
   1443       1.1  mrg 
   1444   1.1.1.3  mrg File: libgomp.info,  Node: OMP_THREAD_LIMIT,  Next: OMP_WAIT_POLICY,  Prev: OMP_SCHEDULE,  Up: Environment Variables
   1445       1.1  mrg 
   1446   1.1.1.8  mrg 3.13 'OMP_THREAD_LIMIT' - Set the maximum number of threads
   1447   1.1.1.3  mrg ===========================================================
   1448       1.1  mrg 
   1449       1.1  mrg _Description_:
   1450   1.1.1.3  mrg      Specifies the number of threads to use for the whole program.  The
   1451   1.1.1.3  mrg      value of this variable shall be a positive integer.  If undefined,
   1452   1.1.1.3  mrg      the number of threads is not limited.
   1453   1.1.1.3  mrg 
   1454   1.1.1.3  mrg _See also_:
   1455   1.1.1.3  mrg      *note OMP_NUM_THREADS::, *note omp_get_thread_limit::
   1456       1.1  mrg 
   1457       1.1  mrg _Reference_:
   1458   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.10
   1459       1.1  mrg 
   1460       1.1  mrg 
   1461   1.1.1.3  mrg File: libgomp.info,  Node: OMP_WAIT_POLICY,  Next: GOMP_CPU_AFFINITY,  Prev: OMP_THREAD_LIMIT,  Up: Environment Variables
   1462       1.1  mrg 
   1463   1.1.1.8  mrg 3.14 'OMP_WAIT_POLICY' - How waiting threads are handled
   1464   1.1.1.3  mrg ========================================================
   1465   1.1.1.2  mrg 
   1466   1.1.1.2  mrg _Description_:
   1467   1.1.1.3  mrg      Specifies whether waiting threads should be active or passive.  If
   1468   1.1.1.8  mrg      the value is 'PASSIVE', waiting threads should not consume CPU
   1469   1.1.1.8  mrg      power while waiting; while the value is 'ACTIVE' specifies that
   1470   1.1.1.3  mrg      they should.  If undefined, threads wait actively for a short time
   1471   1.1.1.3  mrg      before waiting passively.
   1472   1.1.1.2  mrg 
   1473   1.1.1.2  mrg _See also_:
   1474   1.1.1.3  mrg      *note GOMP_SPINCOUNT::
   1475   1.1.1.2  mrg 
   1476   1.1.1.2  mrg _Reference_:
   1477   1.1.1.9  mrg      OpenMP specification v4.5 (https://www.openmp.org), Section 4.8
   1478   1.1.1.2  mrg 
   1479   1.1.1.2  mrg 
   1480   1.1.1.3  mrg File: libgomp.info,  Node: GOMP_CPU_AFFINITY,  Next: GOMP_DEBUG,  Prev: OMP_WAIT_POLICY,  Up: Environment Variables
   1481   1.1.1.2  mrg 
   1482   1.1.1.8  mrg 3.15 'GOMP_CPU_AFFINITY' - Bind threads to specific CPUs
   1483   1.1.1.2  mrg ========================================================
   1484       1.1  mrg 
   1485       1.1  mrg _Description_:
   1486   1.1.1.3  mrg      Binds threads to specific CPUs.  The variable should contain a
   1487   1.1.1.3  mrg      space-separated or comma-separated list of CPUs.  This list may
   1488   1.1.1.2  mrg      contain different kinds of entries: either single CPU numbers in
   1489   1.1.1.2  mrg      any order, a range of CPUs (M-N) or a range with some stride
   1490   1.1.1.8  mrg      (M-N:S). CPU numbers are zero based.  For example,
   1491   1.1.1.8  mrg      'GOMP_CPU_AFFINITY="0 3 1-2 4-15:2"' will bind the initial thread
   1492   1.1.1.2  mrg      to CPU 0, the second to CPU 3, the third to CPU 1, the fourth to
   1493   1.1.1.2  mrg      CPU 2, the fifth to CPU 4, the sixth through tenth to CPUs 6, 8,
   1494   1.1.1.2  mrg      10, 12, and 14 respectively and then start assigning back from the
   1495   1.1.1.8  mrg      beginning of the list.  'GOMP_CPU_AFFINITY=0' binds all threads to
   1496   1.1.1.2  mrg      CPU 0.
   1497       1.1  mrg 
   1498   1.1.1.3  mrg      There is no libgomp library routine to determine whether a CPU
   1499   1.1.1.3  mrg      affinity specification is in effect.  As a workaround,
   1500   1.1.1.8  mrg      language-specific library functions, e.g., 'getenv' in C or
   1501   1.1.1.8  mrg      'GET_ENVIRONMENT_VARIABLE' in Fortran, may be used to query the
   1502   1.1.1.8  mrg      setting of the 'GOMP_CPU_AFFINITY' environment variable.  A defined
   1503   1.1.1.8  mrg      CPU affinity on startup cannot be changed or disabled during the
   1504   1.1.1.8  mrg      runtime of the application.
   1505   1.1.1.8  mrg 
   1506   1.1.1.8  mrg      If both 'GOMP_CPU_AFFINITY' and 'OMP_PROC_BIND' are set,
   1507   1.1.1.8  mrg      'OMP_PROC_BIND' has a higher precedence.  If neither has been set
   1508   1.1.1.8  mrg      and 'OMP_PROC_BIND' is unset, or when 'OMP_PROC_BIND' is set to
   1509   1.1.1.8  mrg      'FALSE', the host system will handle the assignment of threads to
   1510   1.1.1.3  mrg      CPUs.
   1511       1.1  mrg 
   1512   1.1.1.2  mrg _See also_:
   1513   1.1.1.3  mrg      *note OMP_PLACES::, *note OMP_PROC_BIND::
   1514   1.1.1.3  mrg 
   1515   1.1.1.3  mrg 
   1516   1.1.1.3  mrg File: libgomp.info,  Node: GOMP_DEBUG,  Next: GOMP_STACKSIZE,  Prev: GOMP_CPU_AFFINITY,  Up: Environment Variables
   1517   1.1.1.3  mrg 
   1518   1.1.1.8  mrg 3.16 'GOMP_DEBUG' - Enable debugging output
   1519   1.1.1.3  mrg ===========================================
   1520   1.1.1.3  mrg 
   1521   1.1.1.3  mrg _Description_:
   1522   1.1.1.8  mrg      Enable debugging output.  The variable should be set to '0'
   1523   1.1.1.8  mrg      (disabled, also the default if not set), or '1' (enabled).
   1524   1.1.1.3  mrg 
   1525   1.1.1.3  mrg      If enabled, some debugging output will be printed during execution.
   1526   1.1.1.3  mrg      This is currently not specified in more detail, and subject to
   1527   1.1.1.3  mrg      change.
   1528   1.1.1.2  mrg 
   1529       1.1  mrg 
   1530   1.1.1.3  mrg File: libgomp.info,  Node: GOMP_STACKSIZE,  Next: GOMP_SPINCOUNT,  Prev: GOMP_DEBUG,  Up: Environment Variables
   1531       1.1  mrg 
   1532   1.1.1.8  mrg 3.17 'GOMP_STACKSIZE' - Set default thread stack size
   1533       1.1  mrg =====================================================
   1534       1.1  mrg 
   1535       1.1  mrg _Description_:
   1536   1.1.1.3  mrg      Set the default thread stack size in kilobytes.  This is different
   1537   1.1.1.8  mrg      from 'pthread_attr_setstacksize' which gets the number of bytes as
   1538   1.1.1.3  mrg      an argument.  If the stack size cannot be set due to system
   1539   1.1.1.2  mrg      constraints, an error is reported and the initial stack size is
   1540   1.1.1.3  mrg      left unchanged.  If undefined, the stack size is system dependent.
   1541       1.1  mrg 
   1542       1.1  mrg _See also_:
   1543   1.1.1.2  mrg      *note OMP_STACKSIZE::
   1544       1.1  mrg 
   1545       1.1  mrg _Reference_:
   1546       1.1  mrg      GCC Patches Mailinglist
   1547  1.1.1.10  mrg      (https://gcc.gnu.org/ml/gcc-patches/2006-06/msg00493.html), GCC
   1548       1.1  mrg      Patches Mailinglist
   1549  1.1.1.10  mrg      (https://gcc.gnu.org/ml/gcc-patches/2006-06/msg00496.html)
   1550       1.1  mrg 
   1551       1.1  mrg 
   1552   1.1.1.5  mrg File: libgomp.info,  Node: GOMP_SPINCOUNT,  Next: GOMP_RTEMS_THREAD_POOLS,  Prev: GOMP_STACKSIZE,  Up: Environment Variables
   1553   1.1.1.3  mrg 
   1554   1.1.1.8  mrg 3.18 'GOMP_SPINCOUNT' - Set the busy-wait spin count
   1555   1.1.1.3  mrg ====================================================
   1556   1.1.1.3  mrg 
   1557   1.1.1.3  mrg _Description_:
   1558   1.1.1.3  mrg      Determines how long a threads waits actively with consuming CPU
   1559   1.1.1.3  mrg      power before waiting passively without consuming CPU power.  The
   1560   1.1.1.8  mrg      value may be either 'INFINITE', 'INFINITY' to always wait actively
   1561   1.1.1.3  mrg      or an integer which gives the number of spins of the busy-wait
   1562   1.1.1.3  mrg      loop.  The integer may optionally be followed by the following
   1563   1.1.1.8  mrg      suffixes acting as multiplication factors: 'k' (kilo, thousand),
   1564   1.1.1.8  mrg      'M' (mega, million), 'G' (giga, billion), or 'T' (tera, trillion).
   1565   1.1.1.8  mrg      If undefined, 0 is used when 'OMP_WAIT_POLICY' is 'PASSIVE',
   1566   1.1.1.8  mrg      300,000 is used when 'OMP_WAIT_POLICY' is undefined and 30 billion
   1567   1.1.1.8  mrg      is used when 'OMP_WAIT_POLICY' is 'ACTIVE'.  If there are more
   1568   1.1.1.8  mrg      OpenMP threads than available CPUs, 1000 and 100 spins are used for
   1569   1.1.1.8  mrg      'OMP_WAIT_POLICY' being 'ACTIVE' or undefined, respectively; unless
   1570   1.1.1.8  mrg      the 'GOMP_SPINCOUNT' is lower or 'OMP_WAIT_POLICY' is 'PASSIVE'.
   1571   1.1.1.3  mrg 
   1572   1.1.1.3  mrg _See also_:
   1573   1.1.1.3  mrg      *note OMP_WAIT_POLICY::
   1574   1.1.1.3  mrg 
   1575   1.1.1.3  mrg 
   1576   1.1.1.5  mrg File: libgomp.info,  Node: GOMP_RTEMS_THREAD_POOLS,  Prev: GOMP_SPINCOUNT,  Up: Environment Variables
   1577   1.1.1.5  mrg 
   1578   1.1.1.8  mrg 3.19 'GOMP_RTEMS_THREAD_POOLS' - Set the RTEMS specific thread pools
   1579   1.1.1.5  mrg ====================================================================
   1580   1.1.1.5  mrg 
   1581   1.1.1.5  mrg _Description_:
   1582   1.1.1.5  mrg      This environment variable is only used on the RTEMS real-time
   1583   1.1.1.5  mrg      operating system.  It determines the scheduler instance specific
   1584   1.1.1.8  mrg      thread pools.  The format for 'GOMP_RTEMS_THREAD_POOLS' is a list
   1585   1.1.1.8  mrg      of optional '<thread-pool-count>[$<priority>]@<scheduler-name>'
   1586   1.1.1.8  mrg      configurations separated by ':' where:
   1587   1.1.1.8  mrg         * '<thread-pool-count>' is the thread pool count for this
   1588   1.1.1.5  mrg           scheduler instance.
   1589   1.1.1.8  mrg         * '$<priority>' is an optional priority for the worker threads
   1590   1.1.1.8  mrg           of a thread pool according to 'pthread_setschedparam'.  In
   1591   1.1.1.5  mrg           case a priority value is omitted, then a worker thread will
   1592   1.1.1.5  mrg           inherit the priority of the OpenMP master thread that created
   1593   1.1.1.5  mrg           it.  The priority of the worker thread is not changed after
   1594   1.1.1.5  mrg           creation, even if a new OpenMP master thread using the worker
   1595   1.1.1.5  mrg           has a different priority.
   1596   1.1.1.8  mrg         * '@<scheduler-name>' is the scheduler instance name according
   1597   1.1.1.5  mrg           to the RTEMS application configuration.
   1598   1.1.1.5  mrg      In case no thread pool configuration is specified for a scheduler
   1599   1.1.1.8  mrg      instance, then each OpenMP master thread of this scheduler instance
   1600   1.1.1.8  mrg      will use its own dynamically allocated thread pool.  To limit the
   1601   1.1.1.8  mrg      worker thread count of the thread pools, each OpenMP master thread
   1602   1.1.1.8  mrg      must call 'omp_set_num_threads'.
   1603   1.1.1.5  mrg _Example_:
   1604   1.1.1.8  mrg      Lets suppose we have three scheduler instances 'IO', 'WRK0', and
   1605   1.1.1.8  mrg      'WRK1' with 'GOMP_RTEMS_THREAD_POOLS' set to '"1@WRK0:3$4@WRK1"'.
   1606   1.1.1.5  mrg      Then there are no thread pool restrictions for scheduler instance
   1607   1.1.1.8  mrg      'IO'.  In the scheduler instance 'WRK0' there is one thread pool
   1608   1.1.1.5  mrg      available.  Since no priority is specified for this scheduler
   1609   1.1.1.5  mrg      instance, the worker thread inherits the priority of the OpenMP
   1610   1.1.1.8  mrg      master thread that created it.  In the scheduler instance 'WRK1'
   1611   1.1.1.8  mrg      there are three thread pools available and their worker threads run
   1612   1.1.1.8  mrg      at priority four.
   1613   1.1.1.5  mrg 
   1614   1.1.1.5  mrg 
   1615   1.1.1.5  mrg File: libgomp.info,  Node: Enabling OpenACC,  Next: OpenACC Runtime Library Routines,  Prev: Environment Variables,  Up: Top
   1616   1.1.1.5  mrg 
   1617   1.1.1.5  mrg 4 Enabling OpenACC
   1618   1.1.1.5  mrg ******************
   1619   1.1.1.5  mrg 
   1620   1.1.1.5  mrg To activate the OpenACC extensions for C/C++ and Fortran, the
   1621   1.1.1.8  mrg compile-time flag '-fopenacc' must be specified.  This enables the
   1622  1.1.1.10  mrg OpenACC directive '#pragma acc' in C/C++ and '!$acc' directives in free
   1623   1.1.1.8  mrg form, 'c$acc', '*$acc' and '!$acc' directives in fixed form, '!$'
   1624   1.1.1.8  mrg conditional compilation sentinels in free form and 'c$', '*$' and '!$'
   1625   1.1.1.5  mrg sentinels in fixed form, for Fortran.  The flag also arranges for
   1626   1.1.1.5  mrg automatic linking of the OpenACC runtime library (*note OpenACC Runtime
   1627   1.1.1.5  mrg Library Routines::).
   1628   1.1.1.5  mrg 
   1629  1.1.1.10  mrg    See <https://gcc.gnu.org/wiki/OpenACC> for more information.
   1630  1.1.1.10  mrg 
   1631   1.1.1.5  mrg    A complete description of all OpenACC directives accepted may be
   1632   1.1.1.8  mrg found in the OpenACC (https://www.openacc.org) Application Programming
   1633  1.1.1.10  mrg Interface manual, version 2.6.
   1634   1.1.1.5  mrg 
   1635   1.1.1.5  mrg 
   1636   1.1.1.5  mrg File: libgomp.info,  Node: OpenACC Runtime Library Routines,  Next: OpenACC Environment Variables,  Prev: Enabling OpenACC,  Up: Top
   1637   1.1.1.5  mrg 
   1638   1.1.1.5  mrg 5 OpenACC Runtime Library Routines
   1639   1.1.1.5  mrg **********************************
   1640   1.1.1.5  mrg 
   1641   1.1.1.5  mrg The runtime routines described here are defined by section 3 of the
   1642  1.1.1.10  mrg OpenACC specifications in version 2.6.  They have C linkage, and do not
   1643   1.1.1.8  mrg throw exceptions.  Generally, they are available only for the host, with
   1644   1.1.1.8  mrg the exception of 'acc_on_device', which is available for both the host
   1645   1.1.1.8  mrg and the acceleration device.
   1646   1.1.1.5  mrg 
   1647   1.1.1.5  mrg * Menu:
   1648   1.1.1.5  mrg 
   1649   1.1.1.5  mrg * acc_get_num_devices::         Get number of devices for the given device
   1650   1.1.1.5  mrg                                 type.
   1651   1.1.1.5  mrg * acc_set_device_type::         Set type of device accelerator to use.
   1652   1.1.1.5  mrg * acc_get_device_type::         Get type of device accelerator to be used.
   1653   1.1.1.5  mrg * acc_set_device_num::          Set device number to use.
   1654   1.1.1.5  mrg * acc_get_device_num::          Get device number to be used.
   1655  1.1.1.10  mrg * acc_get_property::            Get device property.
   1656   1.1.1.5  mrg * acc_async_test::              Tests for completion of a specific asynchronous
   1657   1.1.1.5  mrg                                 operation.
   1658  1.1.1.10  mrg * acc_async_test_all::          Tests for completion of all asynchronous
   1659   1.1.1.5  mrg                                 operations.
   1660   1.1.1.5  mrg * acc_wait::                    Wait for completion of a specific asynchronous
   1661   1.1.1.5  mrg                                 operation.
   1662  1.1.1.10  mrg * acc_wait_all::                Waits for completion of all asynchronous
   1663   1.1.1.5  mrg                                 operations.
   1664   1.1.1.5  mrg * acc_wait_all_async::          Wait for completion of all asynchronous
   1665   1.1.1.5  mrg                                 operations.
   1666   1.1.1.5  mrg * acc_wait_async::              Wait for completion of asynchronous operations.
   1667   1.1.1.5  mrg * acc_init::                    Initialize runtime for a specific device type.
   1668   1.1.1.5  mrg * acc_shutdown::                Shuts down the runtime for a specific device
   1669   1.1.1.5  mrg                                 type.
   1670   1.1.1.5  mrg * acc_on_device::               Whether executing on a particular device
   1671   1.1.1.5  mrg * acc_malloc::                  Allocate device memory.
   1672   1.1.1.5  mrg * acc_free::                    Free device memory.
   1673   1.1.1.5  mrg * acc_copyin::                  Allocate device memory and copy host memory to
   1674   1.1.1.5  mrg                                 it.
   1675   1.1.1.5  mrg * acc_present_or_copyin::       If the data is not present on the device,
   1676   1.1.1.5  mrg                                 allocate device memory and copy from host
   1677   1.1.1.5  mrg                                 memory.
   1678   1.1.1.5  mrg * acc_create::                  Allocate device memory and map it to host
   1679   1.1.1.5  mrg                                 memory.
   1680   1.1.1.5  mrg * acc_present_or_create::       If the data is not present on the device,
   1681   1.1.1.5  mrg                                 allocate device memory and map it to host
   1682   1.1.1.5  mrg                                 memory.
   1683   1.1.1.5  mrg * acc_copyout::                 Copy device memory to host memory.
   1684   1.1.1.5  mrg * acc_delete::                  Free device memory.
   1685   1.1.1.5  mrg * acc_update_device::           Update device memory from mapped host memory.
   1686   1.1.1.5  mrg * acc_update_self::             Update host memory from mapped device memory.
   1687   1.1.1.5  mrg * acc_map_data::                Map previously allocated device memory to host
   1688   1.1.1.5  mrg                                 memory.
   1689   1.1.1.5  mrg * acc_unmap_data::              Unmap device memory from host memory.
   1690   1.1.1.5  mrg * acc_deviceptr::               Get device pointer associated with specific
   1691   1.1.1.5  mrg                                 host address.
   1692   1.1.1.5  mrg * acc_hostptr::                 Get host pointer associated with specific
   1693   1.1.1.5  mrg                                 device address.
   1694  1.1.1.10  mrg * acc_is_present::              Indicate whether host variable / array is
   1695   1.1.1.5  mrg                                 present on device.
   1696   1.1.1.5  mrg * acc_memcpy_to_device::        Copy host memory to device memory.
   1697   1.1.1.5  mrg * acc_memcpy_from_device::      Copy device memory to host memory.
   1698  1.1.1.10  mrg * acc_attach::                  Let device pointer point to device-pointer target.
   1699  1.1.1.10  mrg * acc_detach::                  Let device pointer point to host-pointer target.
   1700   1.1.1.5  mrg 
   1701   1.1.1.5  mrg API routines for target platforms.
   1702   1.1.1.5  mrg 
   1703   1.1.1.5  mrg * acc_get_current_cuda_device:: Get CUDA device handle.
   1704   1.1.1.5  mrg * acc_get_current_cuda_context::Get CUDA context handle.
   1705   1.1.1.5  mrg * acc_get_cuda_stream::         Get CUDA stream handle.
   1706   1.1.1.5  mrg * acc_set_cuda_stream::         Set CUDA stream handle.
   1707   1.1.1.5  mrg 
   1708  1.1.1.10  mrg API routines for the OpenACC Profiling Interface.
   1709  1.1.1.10  mrg 
   1710  1.1.1.10  mrg * acc_prof_register::           Register callbacks.
   1711  1.1.1.10  mrg * acc_prof_unregister::         Unregister callbacks.
   1712  1.1.1.10  mrg * acc_prof_lookup::             Obtain inquiry functions.
   1713  1.1.1.10  mrg * acc_register_library::        Library registration.
   1714  1.1.1.10  mrg 
   1715   1.1.1.5  mrg 
   1716   1.1.1.5  mrg File: libgomp.info,  Node: acc_get_num_devices,  Next: acc_set_device_type,  Up: OpenACC Runtime Library Routines
   1717   1.1.1.5  mrg 
   1718   1.1.1.8  mrg 5.1 'acc_get_num_devices' - Get number of devices for given device type
   1719   1.1.1.5  mrg =======================================================================
   1720   1.1.1.5  mrg 
   1721   1.1.1.5  mrg _Description_
   1722   1.1.1.5  mrg      This function returns a value indicating the number of devices
   1723   1.1.1.5  mrg      available for the device type specified in DEVICETYPE.
   1724   1.1.1.5  mrg 
   1725   1.1.1.5  mrg _C/C++_:
   1726   1.1.1.8  mrg      _Prototype_:   'int acc_get_num_devices(acc_device_t devicetype);'
   1727   1.1.1.5  mrg 
   1728   1.1.1.5  mrg _Fortran_:
   1729   1.1.1.8  mrg      _Interface_:   'integer function acc_get_num_devices(devicetype)'
   1730   1.1.1.8  mrg                     'integer(kind=acc_device_kind) devicetype'
   1731   1.1.1.5  mrg 
   1732   1.1.1.5  mrg _Reference_:
   1733  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   1734   1.1.1.5  mrg      3.2.1.
   1735   1.1.1.5  mrg 
   1736   1.1.1.5  mrg 
   1737   1.1.1.5  mrg File: libgomp.info,  Node: acc_set_device_type,  Next: acc_get_device_type,  Prev: acc_get_num_devices,  Up: OpenACC Runtime Library Routines
   1738   1.1.1.5  mrg 
   1739   1.1.1.8  mrg 5.2 'acc_set_device_type' - Set type of device accelerator to use.
   1740   1.1.1.5  mrg ==================================================================
   1741   1.1.1.5  mrg 
   1742   1.1.1.5  mrg _Description_
   1743  1.1.1.10  mrg      This function indicates to the runtime library which device type,
   1744   1.1.1.5  mrg      specified in DEVICETYPE, to use when executing a parallel or
   1745   1.1.1.5  mrg      kernels region.
   1746   1.1.1.5  mrg 
   1747   1.1.1.5  mrg _C/C++_:
   1748   1.1.1.8  mrg      _Prototype_:   'acc_set_device_type(acc_device_t devicetype);'
   1749   1.1.1.5  mrg 
   1750   1.1.1.5  mrg _Fortran_:
   1751   1.1.1.8  mrg      _Interface_:   'subroutine acc_set_device_type(devicetype)'
   1752   1.1.1.8  mrg                     'integer(kind=acc_device_kind) devicetype'
   1753   1.1.1.5  mrg 
   1754   1.1.1.5  mrg _Reference_:
   1755  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   1756   1.1.1.5  mrg      3.2.2.
   1757   1.1.1.5  mrg 
   1758   1.1.1.5  mrg 
   1759   1.1.1.5  mrg File: libgomp.info,  Node: acc_get_device_type,  Next: acc_set_device_num,  Prev: acc_set_device_type,  Up: OpenACC Runtime Library Routines
   1760   1.1.1.5  mrg 
   1761   1.1.1.8  mrg 5.3 'acc_get_device_type' - Get type of device accelerator to be used.
   1762   1.1.1.5  mrg ======================================================================
   1763   1.1.1.5  mrg 
   1764   1.1.1.5  mrg _Description_
   1765   1.1.1.5  mrg      This function returns what device type will be used when executing
   1766   1.1.1.5  mrg      a parallel or kernels region.
   1767   1.1.1.5  mrg 
   1768  1.1.1.10  mrg      This function returns 'acc_device_none' if 'acc_get_device_type' is
   1769  1.1.1.10  mrg      called from 'acc_ev_device_init_start', 'acc_ev_device_init_end'
   1770  1.1.1.10  mrg      callbacks of the OpenACC Profiling Interface (*note OpenACC
   1771  1.1.1.10  mrg      Profiling Interface::), that is, if the device is currently being
   1772  1.1.1.10  mrg      initialized.
   1773  1.1.1.10  mrg 
   1774   1.1.1.5  mrg _C/C++_:
   1775   1.1.1.8  mrg      _Prototype_:   'acc_device_t acc_get_device_type(void);'
   1776   1.1.1.5  mrg 
   1777   1.1.1.5  mrg _Fortran_:
   1778   1.1.1.8  mrg      _Interface_:   'function acc_get_device_type(void)'
   1779   1.1.1.8  mrg                     'integer(kind=acc_device_kind) acc_get_device_type'
   1780   1.1.1.5  mrg 
   1781   1.1.1.5  mrg _Reference_:
   1782  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   1783   1.1.1.5  mrg      3.2.3.
   1784   1.1.1.5  mrg 
   1785   1.1.1.5  mrg 
   1786   1.1.1.5  mrg File: libgomp.info,  Node: acc_set_device_num,  Next: acc_get_device_num,  Prev: acc_get_device_type,  Up: OpenACC Runtime Library Routines
   1787   1.1.1.5  mrg 
   1788   1.1.1.8  mrg 5.4 'acc_set_device_num' - Set device number to use.
   1789   1.1.1.5  mrg ====================================================
   1790   1.1.1.5  mrg 
   1791   1.1.1.5  mrg _Description_
   1792   1.1.1.5  mrg      This function will indicate to the runtime which device number,
   1793  1.1.1.10  mrg      specified by DEVICENUM, associated with the specified device type
   1794   1.1.1.5  mrg      DEVICETYPE.
   1795   1.1.1.5  mrg 
   1796   1.1.1.5  mrg _C/C++_:
   1797  1.1.1.10  mrg      _Prototype_:   'acc_set_device_num(int devicenum, acc_device_t
   1798  1.1.1.10  mrg                     devicetype);'
   1799   1.1.1.5  mrg 
   1800   1.1.1.5  mrg _Fortran_:
   1801   1.1.1.8  mrg      _Interface_:   'subroutine acc_set_device_num(devicenum, devicetype)'
   1802   1.1.1.8  mrg                     'integer devicenum'
   1803   1.1.1.8  mrg                     'integer(kind=acc_device_kind) devicetype'
   1804   1.1.1.5  mrg 
   1805   1.1.1.5  mrg _Reference_:
   1806  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   1807   1.1.1.5  mrg      3.2.4.
   1808   1.1.1.5  mrg 
   1809   1.1.1.5  mrg 
   1810  1.1.1.10  mrg File: libgomp.info,  Node: acc_get_device_num,  Next: acc_get_property,  Prev: acc_set_device_num,  Up: OpenACC Runtime Library Routines
   1811   1.1.1.5  mrg 
   1812   1.1.1.8  mrg 5.5 'acc_get_device_num' - Get device number to be used.
   1813   1.1.1.5  mrg ========================================================
   1814   1.1.1.5  mrg 
   1815   1.1.1.5  mrg _Description_
   1816   1.1.1.5  mrg      This function returns which device number associated with the
   1817   1.1.1.5  mrg      specified device type DEVICETYPE, will be used when executing a
   1818   1.1.1.5  mrg      parallel or kernels region.
   1819   1.1.1.5  mrg 
   1820   1.1.1.5  mrg _C/C++_:
   1821   1.1.1.8  mrg      _Prototype_:   'int acc_get_device_num(acc_device_t devicetype);'
   1822   1.1.1.5  mrg 
   1823   1.1.1.5  mrg _Fortran_:
   1824   1.1.1.8  mrg      _Interface_:   'function acc_get_device_num(devicetype)'
   1825   1.1.1.8  mrg                     'integer(kind=acc_device_kind) devicetype'
   1826   1.1.1.8  mrg                     'integer acc_get_device_num'
   1827   1.1.1.5  mrg 
   1828   1.1.1.5  mrg _Reference_:
   1829  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   1830   1.1.1.5  mrg      3.2.5.
   1831   1.1.1.5  mrg 
   1832   1.1.1.5  mrg 
   1833  1.1.1.10  mrg File: libgomp.info,  Node: acc_get_property,  Next: acc_async_test,  Prev: acc_get_device_num,  Up: OpenACC Runtime Library Routines
   1834  1.1.1.10  mrg 
   1835  1.1.1.10  mrg 5.6 'acc_get_property' - Get device property.
   1836  1.1.1.10  mrg =============================================
   1837  1.1.1.10  mrg 
   1838  1.1.1.10  mrg _Description_
   1839  1.1.1.10  mrg      These routines return the value of the specified PROPERTY for the
   1840  1.1.1.10  mrg      device being queried according to DEVICENUM and DEVICETYPE.
   1841  1.1.1.10  mrg      Integer-valued and string-valued properties are returned by
   1842  1.1.1.10  mrg      'acc_get_property' and 'acc_get_property_string' respectively.  The
   1843  1.1.1.10  mrg      Fortran 'acc_get_property_string' subroutine returns the string
   1844  1.1.1.10  mrg      retrieved in its fourth argument while the remaining entry points
   1845  1.1.1.10  mrg      are functions, which pass the return value as their result.
   1846  1.1.1.10  mrg 
   1847  1.1.1.10  mrg      Note for Fortran, only: the OpenACC technical committee corrected
   1848  1.1.1.10  mrg      and, hence, modified the interface introduced in OpenACC 2.6.  The
   1849  1.1.1.10  mrg      kind-value parameter 'acc_device_property' has been renamed to
   1850  1.1.1.10  mrg      'acc_device_property_kind' for consistency and the return type of
   1851  1.1.1.10  mrg      the 'acc_get_property' function is now a 'c_size_t' integer instead
   1852  1.1.1.10  mrg      of a 'acc_device_property' integer.  The parameter
   1853  1.1.1.10  mrg      'acc_device_property' will continue to be provided, but might be
   1854  1.1.1.10  mrg      removed in a future version of GCC.
   1855  1.1.1.10  mrg 
   1856  1.1.1.10  mrg _C/C++_:
   1857  1.1.1.10  mrg      _Prototype_:   'size_t acc_get_property(int devicenum, acc_device_t
   1858  1.1.1.10  mrg                     devicetype, acc_device_property_t property);'
   1859  1.1.1.10  mrg      _Prototype_:   'const char *acc_get_property_string(int devicenum,
   1860  1.1.1.10  mrg                     acc_device_t devicetype, acc_device_property_t
   1861  1.1.1.10  mrg                     property);'
   1862  1.1.1.10  mrg 
   1863  1.1.1.10  mrg _Fortran_:
   1864  1.1.1.10  mrg      _Interface_:   'function acc_get_property(devicenum, devicetype,
   1865  1.1.1.10  mrg                     property)'
   1866  1.1.1.10  mrg      _Interface_:   'subroutine acc_get_property_string(devicenum,
   1867  1.1.1.10  mrg                     devicetype, property, string)'
   1868  1.1.1.10  mrg                     'use ISO_C_Binding, only: c_size_t'
   1869  1.1.1.10  mrg                     'integer devicenum'
   1870  1.1.1.10  mrg                     'integer(kind=acc_device_kind) devicetype'
   1871  1.1.1.10  mrg                     'integer(kind=acc_device_property_kind) property'
   1872  1.1.1.10  mrg                     'integer(kind=c_size_t) acc_get_property'
   1873  1.1.1.10  mrg                     'character(*) string'
   1874  1.1.1.10  mrg 
   1875  1.1.1.10  mrg _Reference_:
   1876  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   1877  1.1.1.10  mrg      3.2.6.
   1878   1.1.1.5  mrg 
   1879  1.1.1.10  mrg 
   1880  1.1.1.10  mrg File: libgomp.info,  Node: acc_async_test,  Next: acc_async_test_all,  Prev: acc_get_property,  Up: OpenACC Runtime Library Routines
   1881  1.1.1.10  mrg 
   1882  1.1.1.10  mrg 5.7 'acc_async_test' - Test for completion of a specific asynchronous operation.
   1883   1.1.1.5  mrg ================================================================================
   1884   1.1.1.5  mrg 
   1885   1.1.1.5  mrg _Description_
   1886  1.1.1.10  mrg      This function tests for completion of the asynchronous operation
   1887   1.1.1.8  mrg      specified in ARG.  In C/C++, a non-zero value will be returned to
   1888   1.1.1.8  mrg      indicate the specified asynchronous operation has completed.  While
   1889  1.1.1.10  mrg      Fortran will return a 'true'.  If the asynchronous operation has
   1890   1.1.1.8  mrg      not completed, C/C++ returns a zero and Fortran returns a 'false'.
   1891   1.1.1.5  mrg 
   1892   1.1.1.5  mrg _C/C++_:
   1893   1.1.1.8  mrg      _Prototype_:   'int acc_async_test(int arg);'
   1894   1.1.1.5  mrg 
   1895   1.1.1.5  mrg _Fortran_:
   1896   1.1.1.8  mrg      _Interface_:   'function acc_async_test(arg)'
   1897   1.1.1.8  mrg                     'integer(kind=acc_handle_kind) arg'
   1898   1.1.1.8  mrg                     'logical acc_async_test'
   1899   1.1.1.5  mrg 
   1900   1.1.1.5  mrg _Reference_:
   1901  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   1902  1.1.1.10  mrg      3.2.9.
   1903   1.1.1.5  mrg 
   1904   1.1.1.5  mrg 
   1905   1.1.1.5  mrg File: libgomp.info,  Node: acc_async_test_all,  Next: acc_wait,  Prev: acc_async_test,  Up: OpenACC Runtime Library Routines
   1906   1.1.1.5  mrg 
   1907  1.1.1.10  mrg 5.8 'acc_async_test_all' - Tests for completion of all asynchronous operations.
   1908   1.1.1.5  mrg ===============================================================================
   1909   1.1.1.5  mrg 
   1910   1.1.1.5  mrg _Description_
   1911  1.1.1.10  mrg      This function tests for completion of all asynchronous operations.
   1912   1.1.1.5  mrg      In C/C++, a non-zero value will be returned to indicate all
   1913   1.1.1.8  mrg      asynchronous operations have completed.  While Fortran will return
   1914   1.1.1.8  mrg      a 'true'.  If any asynchronous operation has not completed, C/C++
   1915   1.1.1.8  mrg      returns a zero and Fortran returns a 'false'.
   1916   1.1.1.5  mrg 
   1917   1.1.1.5  mrg _C/C++_:
   1918   1.1.1.8  mrg      _Prototype_:   'int acc_async_test_all(void);'
   1919   1.1.1.5  mrg 
   1920   1.1.1.5  mrg _Fortran_:
   1921   1.1.1.8  mrg      _Interface_:   'function acc_async_test()'
   1922   1.1.1.8  mrg                     'logical acc_get_device_num'
   1923   1.1.1.5  mrg 
   1924   1.1.1.5  mrg _Reference_:
   1925  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   1926  1.1.1.10  mrg      3.2.10.
   1927   1.1.1.5  mrg 
   1928   1.1.1.5  mrg 
   1929   1.1.1.5  mrg File: libgomp.info,  Node: acc_wait,  Next: acc_wait_all,  Prev: acc_async_test_all,  Up: OpenACC Runtime Library Routines
   1930   1.1.1.5  mrg 
   1931  1.1.1.10  mrg 5.9 'acc_wait' - Wait for completion of a specific asynchronous operation.
   1932   1.1.1.5  mrg ==========================================================================
   1933   1.1.1.5  mrg 
   1934   1.1.1.5  mrg _Description_
   1935   1.1.1.5  mrg      This function waits for completion of the asynchronous operation
   1936   1.1.1.5  mrg      specified in ARG.
   1937   1.1.1.5  mrg 
   1938   1.1.1.5  mrg _C/C++_:
   1939   1.1.1.8  mrg      _Prototype_:   'acc_wait(arg);'
   1940   1.1.1.8  mrg      _Prototype     'acc_async_wait(arg);'
   1941   1.1.1.8  mrg      (OpenACC 1.0
   1942   1.1.1.8  mrg      compatibility)_:
   1943   1.1.1.5  mrg 
   1944   1.1.1.5  mrg _Fortran_:
   1945   1.1.1.8  mrg      _Interface_:   'subroutine acc_wait(arg)'
   1946   1.1.1.8  mrg                     'integer(acc_handle_kind) arg'
   1947   1.1.1.8  mrg      _Interface     'subroutine acc_async_wait(arg)'
   1948   1.1.1.8  mrg      (OpenACC 1.0
   1949   1.1.1.8  mrg      compatibility)_:
   1950   1.1.1.8  mrg                     'integer(acc_handle_kind) arg'
   1951   1.1.1.5  mrg 
   1952   1.1.1.5  mrg _Reference_:
   1953  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   1954  1.1.1.10  mrg      3.2.11.
   1955   1.1.1.5  mrg 
   1956   1.1.1.5  mrg 
   1957   1.1.1.5  mrg File: libgomp.info,  Node: acc_wait_all,  Next: acc_wait_all_async,  Prev: acc_wait,  Up: OpenACC Runtime Library Routines
   1958   1.1.1.5  mrg 
   1959  1.1.1.10  mrg 5.10 'acc_wait_all' - Waits for completion of all asynchronous operations.
   1960  1.1.1.10  mrg ==========================================================================
   1961   1.1.1.5  mrg 
   1962   1.1.1.5  mrg _Description_
   1963   1.1.1.5  mrg      This function waits for the completion of all asynchronous
   1964   1.1.1.5  mrg      operations.
   1965   1.1.1.5  mrg 
   1966   1.1.1.5  mrg _C/C++_:
   1967   1.1.1.8  mrg      _Prototype_:   'acc_wait_all(void);'
   1968   1.1.1.8  mrg      _Prototype     'acc_async_wait_all(void);'
   1969   1.1.1.8  mrg      (OpenACC 1.0
   1970   1.1.1.8  mrg      compatibility)_:
   1971   1.1.1.5  mrg 
   1972   1.1.1.5  mrg _Fortran_:
   1973   1.1.1.8  mrg      _Interface_:   'subroutine acc_wait_all()'
   1974   1.1.1.8  mrg      _Interface     'subroutine acc_async_wait_all()'
   1975   1.1.1.8  mrg      (OpenACC 1.0
   1976   1.1.1.8  mrg      compatibility)_:
   1977   1.1.1.5  mrg 
   1978   1.1.1.5  mrg _Reference_:
   1979  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   1980  1.1.1.10  mrg      3.2.13.
   1981   1.1.1.5  mrg 
   1982   1.1.1.5  mrg 
   1983   1.1.1.5  mrg File: libgomp.info,  Node: acc_wait_all_async,  Next: acc_wait_async,  Prev: acc_wait_all,  Up: OpenACC Runtime Library Routines
   1984   1.1.1.5  mrg 
   1985  1.1.1.10  mrg 5.11 'acc_wait_all_async' - Wait for completion of all asynchronous operations.
   1986   1.1.1.5  mrg ===============================================================================
   1987   1.1.1.5  mrg 
   1988   1.1.1.5  mrg _Description_
   1989   1.1.1.5  mrg      This function enqueues a wait operation on the queue ASYNC for any
   1990   1.1.1.5  mrg      and all asynchronous operations that have been previously enqueued
   1991   1.1.1.5  mrg      on any queue.
   1992   1.1.1.5  mrg 
   1993   1.1.1.5  mrg _C/C++_:
   1994   1.1.1.8  mrg      _Prototype_:   'acc_wait_all_async(int async);'
   1995   1.1.1.5  mrg 
   1996   1.1.1.5  mrg _Fortran_:
   1997   1.1.1.8  mrg      _Interface_:   'subroutine acc_wait_all_async(async)'
   1998   1.1.1.8  mrg                     'integer(acc_handle_kind) async'
   1999   1.1.1.5  mrg 
   2000   1.1.1.5  mrg _Reference_:
   2001  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2002  1.1.1.10  mrg      3.2.14.
   2003   1.1.1.5  mrg 
   2004   1.1.1.5  mrg 
   2005   1.1.1.5  mrg File: libgomp.info,  Node: acc_wait_async,  Next: acc_init,  Prev: acc_wait_all_async,  Up: OpenACC Runtime Library Routines
   2006   1.1.1.5  mrg 
   2007  1.1.1.10  mrg 5.12 'acc_wait_async' - Wait for completion of asynchronous operations.
   2008   1.1.1.5  mrg =======================================================================
   2009   1.1.1.5  mrg 
   2010   1.1.1.5  mrg _Description_
   2011   1.1.1.5  mrg      This function enqueues a wait operation on queue ASYNC for any and
   2012   1.1.1.5  mrg      all asynchronous operations enqueued on queue ARG.
   2013   1.1.1.5  mrg 
   2014   1.1.1.5  mrg _C/C++_:
   2015   1.1.1.8  mrg      _Prototype_:   'acc_wait_async(int arg, int async);'
   2016   1.1.1.5  mrg 
   2017   1.1.1.5  mrg _Fortran_:
   2018   1.1.1.8  mrg      _Interface_:   'subroutine acc_wait_async(arg, async)'
   2019   1.1.1.8  mrg                     'integer(acc_handle_kind) arg, async'
   2020   1.1.1.5  mrg 
   2021   1.1.1.5  mrg _Reference_:
   2022  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2023  1.1.1.10  mrg      3.2.12.
   2024   1.1.1.5  mrg 
   2025   1.1.1.5  mrg 
   2026   1.1.1.5  mrg File: libgomp.info,  Node: acc_init,  Next: acc_shutdown,  Prev: acc_wait_async,  Up: OpenACC Runtime Library Routines
   2027   1.1.1.5  mrg 
   2028  1.1.1.10  mrg 5.13 'acc_init' - Initialize runtime for a specific device type.
   2029   1.1.1.5  mrg ================================================================
   2030   1.1.1.5  mrg 
   2031   1.1.1.5  mrg _Description_
   2032   1.1.1.8  mrg      This function initializes the runtime for the device type specified
   2033   1.1.1.8  mrg      in DEVICETYPE.
   2034   1.1.1.5  mrg 
   2035   1.1.1.5  mrg _C/C++_:
   2036   1.1.1.8  mrg      _Prototype_:   'acc_init(acc_device_t devicetype);'
   2037   1.1.1.5  mrg 
   2038   1.1.1.5  mrg _Fortran_:
   2039   1.1.1.8  mrg      _Interface_:   'subroutine acc_init(devicetype)'
   2040   1.1.1.8  mrg                     'integer(acc_device_kind) devicetype'
   2041   1.1.1.5  mrg 
   2042   1.1.1.5  mrg _Reference_:
   2043  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2044  1.1.1.10  mrg      3.2.7.
   2045   1.1.1.5  mrg 
   2046   1.1.1.5  mrg 
   2047   1.1.1.5  mrg File: libgomp.info,  Node: acc_shutdown,  Next: acc_on_device,  Prev: acc_init,  Up: OpenACC Runtime Library Routines
   2048   1.1.1.5  mrg 
   2049  1.1.1.10  mrg 5.14 'acc_shutdown' - Shuts down the runtime for a specific device type.
   2050   1.1.1.5  mrg ========================================================================
   2051   1.1.1.5  mrg 
   2052   1.1.1.5  mrg _Description_
   2053   1.1.1.5  mrg      This function shuts down the runtime for the device type specified
   2054   1.1.1.5  mrg      in DEVICETYPE.
   2055   1.1.1.5  mrg 
   2056   1.1.1.5  mrg _C/C++_:
   2057   1.1.1.8  mrg      _Prototype_:   'acc_shutdown(acc_device_t devicetype);'
   2058   1.1.1.5  mrg 
   2059   1.1.1.5  mrg _Fortran_:
   2060   1.1.1.8  mrg      _Interface_:   'subroutine acc_shutdown(devicetype)'
   2061   1.1.1.8  mrg                     'integer(acc_device_kind) devicetype'
   2062   1.1.1.5  mrg 
   2063   1.1.1.5  mrg _Reference_:
   2064  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2065  1.1.1.10  mrg      3.2.8.
   2066   1.1.1.5  mrg 
   2067   1.1.1.5  mrg 
   2068   1.1.1.5  mrg File: libgomp.info,  Node: acc_on_device,  Next: acc_malloc,  Prev: acc_shutdown,  Up: OpenACC Runtime Library Routines
   2069   1.1.1.5  mrg 
   2070  1.1.1.10  mrg 5.15 'acc_on_device' - Whether executing on a particular device
   2071   1.1.1.5  mrg ===============================================================
   2072   1.1.1.5  mrg 
   2073   1.1.1.5  mrg _Description_:
   2074   1.1.1.5  mrg      This function returns whether the program is executing on a
   2075   1.1.1.8  mrg      particular device specified in DEVICETYPE.  In C/C++ a non-zero
   2076  1.1.1.10  mrg      value is returned to indicate the device is executing on the
   2077   1.1.1.8  mrg      specified device type.  In Fortran, 'true' will be returned.  If
   2078   1.1.1.5  mrg      the program is not executing on the specified device type C/C++
   2079   1.1.1.8  mrg      will return a zero, while Fortran will return 'false'.
   2080   1.1.1.5  mrg 
   2081   1.1.1.5  mrg _C/C++_:
   2082   1.1.1.8  mrg      _Prototype_:   'acc_on_device(acc_device_t devicetype);'
   2083   1.1.1.5  mrg 
   2084   1.1.1.5  mrg _Fortran_:
   2085   1.1.1.8  mrg      _Interface_:   'function acc_on_device(devicetype)'
   2086   1.1.1.8  mrg                     'integer(acc_device_kind) devicetype'
   2087   1.1.1.8  mrg                     'logical acc_on_device'
   2088   1.1.1.5  mrg 
   2089   1.1.1.5  mrg _Reference_:
   2090  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2091  1.1.1.10  mrg      3.2.17.
   2092   1.1.1.5  mrg 
   2093   1.1.1.5  mrg 
   2094   1.1.1.5  mrg File: libgomp.info,  Node: acc_malloc,  Next: acc_free,  Prev: acc_on_device,  Up: OpenACC Runtime Library Routines
   2095   1.1.1.5  mrg 
   2096  1.1.1.10  mrg 5.16 'acc_malloc' - Allocate device memory.
   2097   1.1.1.5  mrg ===========================================
   2098   1.1.1.5  mrg 
   2099   1.1.1.5  mrg _Description_
   2100   1.1.1.8  mrg      This function allocates LEN bytes of device memory.  It returns the
   2101   1.1.1.5  mrg      device address of the allocated memory.
   2102   1.1.1.5  mrg 
   2103   1.1.1.5  mrg _C/C++_:
   2104   1.1.1.8  mrg      _Prototype_:   'd_void* acc_malloc(size_t len);'
   2105   1.1.1.5  mrg 
   2106   1.1.1.5  mrg _Reference_:
   2107  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2108  1.1.1.10  mrg      3.2.18.
   2109   1.1.1.5  mrg 
   2110   1.1.1.5  mrg 
   2111   1.1.1.5  mrg File: libgomp.info,  Node: acc_free,  Next: acc_copyin,  Prev: acc_malloc,  Up: OpenACC Runtime Library Routines
   2112   1.1.1.5  mrg 
   2113  1.1.1.10  mrg 5.17 'acc_free' - Free device memory.
   2114   1.1.1.5  mrg =====================================
   2115   1.1.1.5  mrg 
   2116   1.1.1.5  mrg _Description_
   2117   1.1.1.8  mrg      Free previously allocated device memory at the device address 'a'.
   2118   1.1.1.5  mrg 
   2119   1.1.1.5  mrg _C/C++_:
   2120   1.1.1.8  mrg      _Prototype_:   'acc_free(d_void *a);'
   2121   1.1.1.5  mrg 
   2122   1.1.1.5  mrg _Reference_:
   2123  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2124  1.1.1.10  mrg      3.2.19.
   2125   1.1.1.5  mrg 
   2126   1.1.1.5  mrg 
   2127   1.1.1.5  mrg File: libgomp.info,  Node: acc_copyin,  Next: acc_present_or_copyin,  Prev: acc_free,  Up: OpenACC Runtime Library Routines
   2128   1.1.1.5  mrg 
   2129  1.1.1.10  mrg 5.18 'acc_copyin' - Allocate device memory and copy host memory to it.
   2130   1.1.1.5  mrg ======================================================================
   2131   1.1.1.5  mrg 
   2132   1.1.1.5  mrg _Description_
   2133   1.1.1.5  mrg      In C/C++, this function allocates LEN bytes of device memory and
   2134   1.1.1.8  mrg      maps it to the specified host address in A.  The device address of
   2135   1.1.1.5  mrg      the newly allocated device memory is returned.
   2136   1.1.1.5  mrg 
   2137   1.1.1.8  mrg      In Fortran, two (2) forms are supported.  In the first form, A
   2138   1.1.1.8  mrg      specifies a contiguous array section.  The second form A specifies
   2139   1.1.1.8  mrg      a variable or array element and LEN specifies the length in bytes.
   2140   1.1.1.5  mrg 
   2141   1.1.1.5  mrg _C/C++_:
   2142   1.1.1.8  mrg      _Prototype_:   'void *acc_copyin(h_void *a, size_t len);'
   2143  1.1.1.10  mrg      _Prototype_:   'void *acc_copyin_async(h_void *a, size_t len, int
   2144  1.1.1.10  mrg                     async);'
   2145   1.1.1.5  mrg 
   2146   1.1.1.5  mrg _Fortran_:
   2147   1.1.1.8  mrg      _Interface_:   'subroutine acc_copyin(a)'
   2148   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2149   1.1.1.8  mrg      _Interface_:   'subroutine acc_copyin(a, len)'
   2150   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2151   1.1.1.8  mrg                     'integer len'
   2152  1.1.1.10  mrg      _Interface_:   'subroutine acc_copyin_async(a, async)'
   2153  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2154  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2155  1.1.1.10  mrg      _Interface_:   'subroutine acc_copyin_async(a, len, async)'
   2156  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2157  1.1.1.10  mrg                     'integer len'
   2158  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2159   1.1.1.5  mrg 
   2160   1.1.1.5  mrg _Reference_:
   2161  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2162  1.1.1.10  mrg      3.2.20.
   2163   1.1.1.5  mrg 
   2164   1.1.1.5  mrg 
   2165   1.1.1.5  mrg File: libgomp.info,  Node: acc_present_or_copyin,  Next: acc_create,  Prev: acc_copyin,  Up: OpenACC Runtime Library Routines
   2166   1.1.1.5  mrg 
   2167  1.1.1.10  mrg 5.19 'acc_present_or_copyin' - If the data is not present on the device, allocate device memory and copy from host memory.
   2168   1.1.1.5  mrg ==========================================================================================================================
   2169   1.1.1.5  mrg 
   2170   1.1.1.5  mrg _Description_
   2171  1.1.1.10  mrg      This function tests if the host data specified by A and of length
   2172   1.1.1.8  mrg      LEN is present or not.  If it is not present, then device memory
   2173   1.1.1.8  mrg      will be allocated and the host memory copied.  The device address
   2174   1.1.1.8  mrg      of the newly allocated device memory is returned.
   2175   1.1.1.5  mrg 
   2176   1.1.1.8  mrg      In Fortran, two (2) forms are supported.  In the first form, A
   2177   1.1.1.8  mrg      specifies a contiguous array section.  The second form A specifies
   2178   1.1.1.5  mrg      a variable or array element and LEN specifies the length in bytes.
   2179   1.1.1.5  mrg 
   2180  1.1.1.10  mrg      Note that 'acc_present_or_copyin' and 'acc_pcopyin' exist for
   2181  1.1.1.10  mrg      backward compatibility with OpenACC 2.0; use *note acc_copyin::
   2182  1.1.1.10  mrg      instead.
   2183  1.1.1.10  mrg 
   2184   1.1.1.5  mrg _C/C++_:
   2185   1.1.1.8  mrg      _Prototype_:   'void *acc_present_or_copyin(h_void *a, size_t len);'
   2186   1.1.1.8  mrg      _Prototype_:   'void *acc_pcopyin(h_void *a, size_t len);'
   2187   1.1.1.5  mrg 
   2188   1.1.1.5  mrg _Fortran_:
   2189   1.1.1.8  mrg      _Interface_:   'subroutine acc_present_or_copyin(a)'
   2190   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2191   1.1.1.8  mrg      _Interface_:   'subroutine acc_present_or_copyin(a, len)'
   2192   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2193   1.1.1.8  mrg                     'integer len'
   2194   1.1.1.8  mrg      _Interface_:   'subroutine acc_pcopyin(a)'
   2195   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2196   1.1.1.8  mrg      _Interface_:   'subroutine acc_pcopyin(a, len)'
   2197   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2198   1.1.1.8  mrg                     'integer len'
   2199   1.1.1.5  mrg 
   2200   1.1.1.5  mrg _Reference_:
   2201  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2202  1.1.1.10  mrg      3.2.20.
   2203   1.1.1.5  mrg 
   2204   1.1.1.5  mrg 
   2205   1.1.1.5  mrg File: libgomp.info,  Node: acc_create,  Next: acc_present_or_create,  Prev: acc_present_or_copyin,  Up: OpenACC Runtime Library Routines
   2206   1.1.1.5  mrg 
   2207  1.1.1.10  mrg 5.20 'acc_create' - Allocate device memory and map it to host memory.
   2208   1.1.1.5  mrg =====================================================================
   2209   1.1.1.5  mrg 
   2210   1.1.1.5  mrg _Description_
   2211   1.1.1.5  mrg      This function allocates device memory and maps it to host memory
   2212   1.1.1.8  mrg      specified by the host address A with a length of LEN bytes.  In
   2213   1.1.1.5  mrg      C/C++, the function returns the device address of the allocated
   2214   1.1.1.5  mrg      device memory.
   2215   1.1.1.5  mrg 
   2216   1.1.1.8  mrg      In Fortran, two (2) forms are supported.  In the first form, A
   2217   1.1.1.8  mrg      specifies a contiguous array section.  The second form A specifies
   2218   1.1.1.5  mrg      a variable or array element and LEN specifies the length in bytes.
   2219   1.1.1.5  mrg 
   2220   1.1.1.5  mrg _C/C++_:
   2221   1.1.1.8  mrg      _Prototype_:   'void *acc_create(h_void *a, size_t len);'
   2222  1.1.1.10  mrg      _Prototype_:   'void *acc_create_async(h_void *a, size_t len, int
   2223  1.1.1.10  mrg                     async);'
   2224   1.1.1.5  mrg 
   2225   1.1.1.5  mrg _Fortran_:
   2226   1.1.1.8  mrg      _Interface_:   'subroutine acc_create(a)'
   2227   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2228   1.1.1.8  mrg      _Interface_:   'subroutine acc_create(a, len)'
   2229   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2230   1.1.1.8  mrg                     'integer len'
   2231  1.1.1.10  mrg      _Interface_:   'subroutine acc_create_async(a, async)'
   2232  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2233  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2234  1.1.1.10  mrg      _Interface_:   'subroutine acc_create_async(a, len, async)'
   2235  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2236  1.1.1.10  mrg                     'integer len'
   2237  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2238   1.1.1.5  mrg 
   2239   1.1.1.5  mrg _Reference_:
   2240  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2241  1.1.1.10  mrg      3.2.21.
   2242   1.1.1.5  mrg 
   2243   1.1.1.5  mrg 
   2244   1.1.1.5  mrg File: libgomp.info,  Node: acc_present_or_create,  Next: acc_copyout,  Prev: acc_create,  Up: OpenACC Runtime Library Routines
   2245   1.1.1.5  mrg 
   2246  1.1.1.10  mrg 5.21 'acc_present_or_create' - If the data is not present on the device, allocate device memory and map it to host memory.
   2247   1.1.1.5  mrg ==========================================================================================================================
   2248       1.1  mrg 
   2249   1.1.1.5  mrg _Description_
   2250  1.1.1.10  mrg      This function tests if the host data specified by A and of length
   2251   1.1.1.8  mrg      LEN is present or not.  If it is not present, then device memory
   2252   1.1.1.8  mrg      will be allocated and mapped to host memory.  In C/C++, the device
   2253   1.1.1.5  mrg      address of the newly allocated device memory is returned.
   2254   1.1.1.5  mrg 
   2255   1.1.1.8  mrg      In Fortran, two (2) forms are supported.  In the first form, A
   2256   1.1.1.8  mrg      specifies a contiguous array section.  The second form A specifies
   2257   1.1.1.5  mrg      a variable or array element and LEN specifies the length in bytes.
   2258   1.1.1.5  mrg 
   2259  1.1.1.10  mrg      Note that 'acc_present_or_create' and 'acc_pcreate' exist for
   2260  1.1.1.10  mrg      backward compatibility with OpenACC 2.0; use *note acc_create::
   2261  1.1.1.10  mrg      instead.
   2262  1.1.1.10  mrg 
   2263   1.1.1.5  mrg _C/C++_:
   2264   1.1.1.8  mrg      _Prototype_:   'void *acc_present_or_create(h_void *a, size_t len)'
   2265   1.1.1.8  mrg      _Prototype_:   'void *acc_pcreate(h_void *a, size_t len)'
   2266   1.1.1.5  mrg 
   2267   1.1.1.5  mrg _Fortran_:
   2268   1.1.1.8  mrg      _Interface_:   'subroutine acc_present_or_create(a)'
   2269   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2270   1.1.1.8  mrg      _Interface_:   'subroutine acc_present_or_create(a, len)'
   2271   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2272   1.1.1.8  mrg                     'integer len'
   2273   1.1.1.8  mrg      _Interface_:   'subroutine acc_pcreate(a)'
   2274   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2275   1.1.1.8  mrg      _Interface_:   'subroutine acc_pcreate(a, len)'
   2276   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2277   1.1.1.8  mrg                     'integer len'
   2278   1.1.1.5  mrg 
   2279   1.1.1.5  mrg _Reference_:
   2280  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2281  1.1.1.10  mrg      3.2.21.
   2282   1.1.1.5  mrg 
   2283   1.1.1.5  mrg 
   2284   1.1.1.5  mrg File: libgomp.info,  Node: acc_copyout,  Next: acc_delete,  Prev: acc_present_or_create,  Up: OpenACC Runtime Library Routines
   2285   1.1.1.5  mrg 
   2286  1.1.1.10  mrg 5.22 'acc_copyout' - Copy device memory to host memory.
   2287   1.1.1.5  mrg =======================================================
   2288   1.1.1.5  mrg 
   2289   1.1.1.5  mrg _Description_
   2290   1.1.1.5  mrg      This function copies mapped device memory to host memory which is
   2291   1.1.1.5  mrg      specified by host address A for a length LEN bytes in C/C++.
   2292   1.1.1.5  mrg 
   2293   1.1.1.8  mrg      In Fortran, two (2) forms are supported.  In the first form, A
   2294   1.1.1.8  mrg      specifies a contiguous array section.  The second form A specifies
   2295   1.1.1.5  mrg      a variable or array element and LEN specifies the length in bytes.
   2296   1.1.1.5  mrg 
   2297   1.1.1.5  mrg _C/C++_:
   2298   1.1.1.8  mrg      _Prototype_:   'acc_copyout(h_void *a, size_t len);'
   2299  1.1.1.10  mrg      _Prototype_:   'acc_copyout_async(h_void *a, size_t len, int async);'
   2300  1.1.1.10  mrg      _Prototype_:   'acc_copyout_finalize(h_void *a, size_t len);'
   2301  1.1.1.10  mrg      _Prototype_:   'acc_copyout_finalize_async(h_void *a, size_t len, int
   2302  1.1.1.10  mrg                     async);'
   2303   1.1.1.5  mrg 
   2304   1.1.1.5  mrg _Fortran_:
   2305   1.1.1.8  mrg      _Interface_:   'subroutine acc_copyout(a)'
   2306   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2307   1.1.1.8  mrg      _Interface_:   'subroutine acc_copyout(a, len)'
   2308   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2309   1.1.1.8  mrg                     'integer len'
   2310  1.1.1.10  mrg      _Interface_:   'subroutine acc_copyout_async(a, async)'
   2311  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2312  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2313  1.1.1.10  mrg      _Interface_:   'subroutine acc_copyout_async(a, len, async)'
   2314  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2315  1.1.1.10  mrg                     'integer len'
   2316  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2317  1.1.1.10  mrg      _Interface_:   'subroutine acc_copyout_finalize(a)'
   2318  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2319  1.1.1.10  mrg      _Interface_:   'subroutine acc_copyout_finalize(a, len)'
   2320  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2321  1.1.1.10  mrg                     'integer len'
   2322  1.1.1.10  mrg      _Interface_:   'subroutine acc_copyout_finalize_async(a, async)'
   2323  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2324  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2325  1.1.1.10  mrg      _Interface_:   'subroutine acc_copyout_finalize_async(a, len, async)'
   2326  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2327  1.1.1.10  mrg                     'integer len'
   2328  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2329   1.1.1.5  mrg 
   2330   1.1.1.5  mrg _Reference_:
   2331  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2332  1.1.1.10  mrg      3.2.22.
   2333   1.1.1.5  mrg 
   2334   1.1.1.5  mrg 
   2335   1.1.1.5  mrg File: libgomp.info,  Node: acc_delete,  Next: acc_update_device,  Prev: acc_copyout,  Up: OpenACC Runtime Library Routines
   2336   1.1.1.5  mrg 
   2337  1.1.1.10  mrg 5.23 'acc_delete' - Free device memory.
   2338   1.1.1.5  mrg =======================================
   2339   1.1.1.5  mrg 
   2340   1.1.1.5  mrg _Description_
   2341   1.1.1.5  mrg      This function frees previously allocated device memory specified by
   2342   1.1.1.5  mrg      the device address A and the length of LEN bytes.
   2343   1.1.1.5  mrg 
   2344   1.1.1.8  mrg      In Fortran, two (2) forms are supported.  In the first form, A
   2345   1.1.1.8  mrg      specifies a contiguous array section.  The second form A specifies
   2346   1.1.1.5  mrg      a variable or array element and LEN specifies the length in bytes.
   2347   1.1.1.5  mrg 
   2348   1.1.1.5  mrg _C/C++_:
   2349   1.1.1.8  mrg      _Prototype_:   'acc_delete(h_void *a, size_t len);'
   2350  1.1.1.10  mrg      _Prototype_:   'acc_delete_async(h_void *a, size_t len, int async);'
   2351  1.1.1.10  mrg      _Prototype_:   'acc_delete_finalize(h_void *a, size_t len);'
   2352  1.1.1.10  mrg      _Prototype_:   'acc_delete_finalize_async(h_void *a, size_t len, int
   2353  1.1.1.10  mrg                     async);'
   2354   1.1.1.5  mrg 
   2355   1.1.1.5  mrg _Fortran_:
   2356   1.1.1.8  mrg      _Interface_:   'subroutine acc_delete(a)'
   2357   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2358   1.1.1.8  mrg      _Interface_:   'subroutine acc_delete(a, len)'
   2359   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2360   1.1.1.8  mrg                     'integer len'
   2361  1.1.1.10  mrg      _Interface_:   'subroutine acc_delete_async(a, async)'
   2362  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2363  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2364  1.1.1.10  mrg      _Interface_:   'subroutine acc_delete_async(a, len, async)'
   2365  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2366  1.1.1.10  mrg                     'integer len'
   2367  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2368  1.1.1.10  mrg      _Interface_:   'subroutine acc_delete_finalize(a)'
   2369  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2370  1.1.1.10  mrg      _Interface_:   'subroutine acc_delete_finalize(a, len)'
   2371  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2372  1.1.1.10  mrg                     'integer len'
   2373  1.1.1.10  mrg      _Interface_:   'subroutine acc_delete_async_finalize(a, async)'
   2374  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2375  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2376  1.1.1.10  mrg      _Interface_:   'subroutine acc_delete_async_finalize(a, len, async)'
   2377  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2378  1.1.1.10  mrg                     'integer len'
   2379  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2380   1.1.1.5  mrg 
   2381   1.1.1.5  mrg _Reference_:
   2382  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2383  1.1.1.10  mrg      3.2.23.
   2384   1.1.1.5  mrg 
   2385   1.1.1.5  mrg 
   2386   1.1.1.5  mrg File: libgomp.info,  Node: acc_update_device,  Next: acc_update_self,  Prev: acc_delete,  Up: OpenACC Runtime Library Routines
   2387   1.1.1.5  mrg 
   2388  1.1.1.10  mrg 5.24 'acc_update_device' - Update device memory from mapped host memory.
   2389   1.1.1.5  mrg ========================================================================
   2390   1.1.1.5  mrg 
   2391   1.1.1.5  mrg _Description_
   2392   1.1.1.5  mrg      This function updates the device copy from the previously mapped
   2393   1.1.1.5  mrg      host memory.  The host memory is specified with the host address A
   2394   1.1.1.5  mrg      and a length of LEN bytes.
   2395   1.1.1.5  mrg 
   2396   1.1.1.8  mrg      In Fortran, two (2) forms are supported.  In the first form, A
   2397   1.1.1.8  mrg      specifies a contiguous array section.  The second form A specifies
   2398   1.1.1.5  mrg      a variable or array element and LEN specifies the length in bytes.
   2399   1.1.1.5  mrg 
   2400   1.1.1.5  mrg _C/C++_:
   2401   1.1.1.8  mrg      _Prototype_:   'acc_update_device(h_void *a, size_t len);'
   2402  1.1.1.10  mrg      _Prototype_:   'acc_update_device(h_void *a, size_t len, async);'
   2403   1.1.1.5  mrg 
   2404   1.1.1.5  mrg _Fortran_:
   2405   1.1.1.8  mrg      _Interface_:   'subroutine acc_update_device(a)'
   2406   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2407   1.1.1.8  mrg      _Interface_:   'subroutine acc_update_device(a, len)'
   2408   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2409   1.1.1.8  mrg                     'integer len'
   2410  1.1.1.10  mrg      _Interface_:   'subroutine acc_update_device_async(a, async)'
   2411  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2412  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2413  1.1.1.10  mrg      _Interface_:   'subroutine acc_update_device_async(a, len, async)'
   2414  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2415  1.1.1.10  mrg                     'integer len'
   2416  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2417   1.1.1.5  mrg 
   2418   1.1.1.5  mrg _Reference_:
   2419  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2420  1.1.1.10  mrg      3.2.24.
   2421   1.1.1.5  mrg 
   2422   1.1.1.5  mrg 
   2423   1.1.1.5  mrg File: libgomp.info,  Node: acc_update_self,  Next: acc_map_data,  Prev: acc_update_device,  Up: OpenACC Runtime Library Routines
   2424   1.1.1.5  mrg 
   2425  1.1.1.10  mrg 5.25 'acc_update_self' - Update host memory from mapped device memory.
   2426   1.1.1.5  mrg ======================================================================
   2427   1.1.1.5  mrg 
   2428   1.1.1.5  mrg _Description_
   2429   1.1.1.5  mrg      This function updates the host copy from the previously mapped
   2430   1.1.1.5  mrg      device memory.  The host memory is specified with the host address
   2431   1.1.1.5  mrg      A and a length of LEN bytes.
   2432   1.1.1.5  mrg 
   2433   1.1.1.8  mrg      In Fortran, two (2) forms are supported.  In the first form, A
   2434   1.1.1.8  mrg      specifies a contiguous array section.  The second form A specifies
   2435   1.1.1.5  mrg      a variable or array element and LEN specifies the length in bytes.
   2436   1.1.1.5  mrg 
   2437   1.1.1.5  mrg _C/C++_:
   2438   1.1.1.8  mrg      _Prototype_:   'acc_update_self(h_void *a, size_t len);'
   2439  1.1.1.10  mrg      _Prototype_:   'acc_update_self_async(h_void *a, size_t len, int
   2440  1.1.1.10  mrg                     async);'
   2441   1.1.1.5  mrg 
   2442   1.1.1.5  mrg _Fortran_:
   2443   1.1.1.8  mrg      _Interface_:   'subroutine acc_update_self(a)'
   2444   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2445   1.1.1.8  mrg      _Interface_:   'subroutine acc_update_self(a, len)'
   2446   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2447   1.1.1.8  mrg                     'integer len'
   2448  1.1.1.10  mrg      _Interface_:   'subroutine acc_update_self_async(a, async)'
   2449  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2450  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2451  1.1.1.10  mrg      _Interface_:   'subroutine acc_update_self_async(a, len, async)'
   2452  1.1.1.10  mrg                     'type, dimension(:[,:]...) :: a'
   2453  1.1.1.10  mrg                     'integer len'
   2454  1.1.1.10  mrg                     'integer(acc_handle_kind) :: async'
   2455   1.1.1.5  mrg 
   2456   1.1.1.5  mrg _Reference_:
   2457  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2458  1.1.1.10  mrg      3.2.25.
   2459   1.1.1.5  mrg 
   2460   1.1.1.5  mrg 
   2461   1.1.1.5  mrg File: libgomp.info,  Node: acc_map_data,  Next: acc_unmap_data,  Prev: acc_update_self,  Up: OpenACC Runtime Library Routines
   2462   1.1.1.5  mrg 
   2463  1.1.1.10  mrg 5.26 'acc_map_data' - Map previously allocated device memory to host memory.
   2464   1.1.1.5  mrg ============================================================================
   2465   1.1.1.5  mrg 
   2466   1.1.1.5  mrg _Description_
   2467   1.1.1.5  mrg      This function maps previously allocated device and host memory.
   2468   1.1.1.8  mrg      The device memory is specified with the device address D.  The host
   2469   1.1.1.5  mrg      memory is specified with the host address H and a length of LEN.
   2470   1.1.1.5  mrg 
   2471   1.1.1.5  mrg _C/C++_:
   2472   1.1.1.8  mrg      _Prototype_:   'acc_map_data(h_void *h, d_void *d, size_t len);'
   2473   1.1.1.5  mrg 
   2474   1.1.1.5  mrg _Reference_:
   2475  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2476  1.1.1.10  mrg      3.2.26.
   2477   1.1.1.5  mrg 
   2478   1.1.1.5  mrg 
   2479   1.1.1.5  mrg File: libgomp.info,  Node: acc_unmap_data,  Next: acc_deviceptr,  Prev: acc_map_data,  Up: OpenACC Runtime Library Routines
   2480   1.1.1.5  mrg 
   2481  1.1.1.10  mrg 5.27 'acc_unmap_data' - Unmap device memory from host memory.
   2482   1.1.1.5  mrg =============================================================
   2483   1.1.1.5  mrg 
   2484   1.1.1.5  mrg _Description_
   2485   1.1.1.8  mrg      This function unmaps previously mapped device and host memory.  The
   2486   1.1.1.5  mrg      latter specified by H.
   2487   1.1.1.5  mrg 
   2488   1.1.1.5  mrg _C/C++_:
   2489   1.1.1.8  mrg      _Prototype_:   'acc_unmap_data(h_void *h);'
   2490   1.1.1.5  mrg 
   2491   1.1.1.5  mrg _Reference_:
   2492  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2493  1.1.1.10  mrg      3.2.27.
   2494   1.1.1.5  mrg 
   2495   1.1.1.5  mrg 
   2496   1.1.1.5  mrg File: libgomp.info,  Node: acc_deviceptr,  Next: acc_hostptr,  Prev: acc_unmap_data,  Up: OpenACC Runtime Library Routines
   2497   1.1.1.5  mrg 
   2498  1.1.1.10  mrg 5.28 'acc_deviceptr' - Get device pointer associated with specific host address.
   2499   1.1.1.5  mrg ================================================================================
   2500   1.1.1.5  mrg 
   2501   1.1.1.5  mrg _Description_
   2502   1.1.1.5  mrg      This function returns the device address that has been mapped to
   2503   1.1.1.5  mrg      the host address specified by H.
   2504   1.1.1.5  mrg 
   2505   1.1.1.5  mrg _C/C++_:
   2506   1.1.1.8  mrg      _Prototype_:   'void *acc_deviceptr(h_void *h);'
   2507   1.1.1.5  mrg 
   2508   1.1.1.5  mrg _Reference_:
   2509  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2510  1.1.1.10  mrg      3.2.28.
   2511   1.1.1.5  mrg 
   2512   1.1.1.5  mrg 
   2513   1.1.1.5  mrg File: libgomp.info,  Node: acc_hostptr,  Next: acc_is_present,  Prev: acc_deviceptr,  Up: OpenACC Runtime Library Routines
   2514   1.1.1.5  mrg 
   2515  1.1.1.10  mrg 5.29 'acc_hostptr' - Get host pointer associated with specific device address.
   2516   1.1.1.5  mrg ==============================================================================
   2517   1.1.1.5  mrg 
   2518   1.1.1.5  mrg _Description_
   2519   1.1.1.5  mrg      This function returns the host address that has been mapped to the
   2520   1.1.1.5  mrg      device address specified by D.
   2521   1.1.1.5  mrg 
   2522   1.1.1.5  mrg _C/C++_:
   2523   1.1.1.8  mrg      _Prototype_:   'void *acc_hostptr(d_void *d);'
   2524   1.1.1.5  mrg 
   2525   1.1.1.5  mrg _Reference_:
   2526  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2527  1.1.1.10  mrg      3.2.29.
   2528   1.1.1.5  mrg 
   2529   1.1.1.5  mrg 
   2530   1.1.1.5  mrg File: libgomp.info,  Node: acc_is_present,  Next: acc_memcpy_to_device,  Prev: acc_hostptr,  Up: OpenACC Runtime Library Routines
   2531   1.1.1.5  mrg 
   2532  1.1.1.10  mrg 5.30 'acc_is_present' - Indicate whether host variable / array is present on device.
   2533   1.1.1.5  mrg ====================================================================================
   2534   1.1.1.5  mrg 
   2535   1.1.1.5  mrg _Description_
   2536   1.1.1.8  mrg      This function indicates whether the specified host address in A and
   2537   1.1.1.8  mrg      a length of LEN bytes is present on the device.  In C/C++, a
   2538   1.1.1.5  mrg      non-zero value is returned to indicate the presence of the mapped
   2539   1.1.1.8  mrg      memory on the device.  A zero is returned to indicate the memory is
   2540   1.1.1.5  mrg      not mapped on the device.
   2541   1.1.1.5  mrg 
   2542   1.1.1.8  mrg      In Fortran, two (2) forms are supported.  In the first form, A
   2543   1.1.1.8  mrg      specifies a contiguous array section.  The second form A specifies
   2544   1.1.1.5  mrg      a variable or array element and LEN specifies the length in bytes.
   2545   1.1.1.8  mrg      If the host memory is mapped to device memory, then a 'true' is
   2546   1.1.1.8  mrg      returned.  Otherwise, a 'false' is return to indicate the mapped
   2547   1.1.1.5  mrg      memory is not present.
   2548   1.1.1.5  mrg 
   2549   1.1.1.5  mrg _C/C++_:
   2550   1.1.1.8  mrg      _Prototype_:   'int acc_is_present(h_void *a, size_t len);'
   2551   1.1.1.5  mrg 
   2552   1.1.1.5  mrg _Fortran_:
   2553   1.1.1.8  mrg      _Interface_:   'function acc_is_present(a)'
   2554   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2555   1.1.1.8  mrg                     'logical acc_is_present'
   2556   1.1.1.8  mrg      _Interface_:   'function acc_is_present(a, len)'
   2557   1.1.1.8  mrg                     'type, dimension(:[,:]...) :: a'
   2558   1.1.1.8  mrg                     'integer len'
   2559   1.1.1.8  mrg                     'logical acc_is_present'
   2560   1.1.1.5  mrg 
   2561   1.1.1.5  mrg _Reference_:
   2562  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2563  1.1.1.10  mrg      3.2.30.
   2564   1.1.1.5  mrg 
   2565   1.1.1.5  mrg 
   2566   1.1.1.5  mrg File: libgomp.info,  Node: acc_memcpy_to_device,  Next: acc_memcpy_from_device,  Prev: acc_is_present,  Up: OpenACC Runtime Library Routines
   2567   1.1.1.5  mrg 
   2568  1.1.1.10  mrg 5.31 'acc_memcpy_to_device' - Copy host memory to device memory.
   2569   1.1.1.5  mrg ================================================================
   2570   1.1.1.5  mrg 
   2571   1.1.1.5  mrg _Description_
   2572   1.1.1.5  mrg      This function copies host memory specified by host address of SRC
   2573   1.1.1.5  mrg      to device memory specified by the device address DEST for a length
   2574   1.1.1.5  mrg      of BYTES bytes.
   2575   1.1.1.5  mrg 
   2576   1.1.1.5  mrg _C/C++_:
   2577   1.1.1.8  mrg      _Prototype_:   'acc_memcpy_to_device(d_void *dest, h_void *src, size_t
   2578   1.1.1.8  mrg                     bytes);'
   2579   1.1.1.5  mrg 
   2580   1.1.1.5  mrg _Reference_:
   2581  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2582  1.1.1.10  mrg      3.2.31.
   2583   1.1.1.5  mrg 
   2584   1.1.1.5  mrg 
   2585  1.1.1.10  mrg File: libgomp.info,  Node: acc_memcpy_from_device,  Next: acc_attach,  Prev: acc_memcpy_to_device,  Up: OpenACC Runtime Library Routines
   2586   1.1.1.5  mrg 
   2587  1.1.1.10  mrg 5.32 'acc_memcpy_from_device' - Copy device memory to host memory.
   2588   1.1.1.5  mrg ==================================================================
   2589   1.1.1.5  mrg 
   2590   1.1.1.5  mrg _Description_
   2591   1.1.1.5  mrg      This function copies host memory specified by host address of SRC
   2592   1.1.1.5  mrg      from device memory specified by the device address DEST for a
   2593   1.1.1.5  mrg      length of BYTES bytes.
   2594   1.1.1.5  mrg 
   2595   1.1.1.5  mrg _C/C++_:
   2596   1.1.1.8  mrg      _Prototype_:   'acc_memcpy_from_device(d_void *dest, h_void *src,
   2597   1.1.1.8  mrg                     size_t bytes);'
   2598   1.1.1.5  mrg 
   2599   1.1.1.5  mrg _Reference_:
   2600  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2601  1.1.1.10  mrg      3.2.32.
   2602  1.1.1.10  mrg 
   2603  1.1.1.10  mrg 
   2604  1.1.1.10  mrg File: libgomp.info,  Node: acc_attach,  Next: acc_detach,  Prev: acc_memcpy_from_device,  Up: OpenACC Runtime Library Routines
   2605  1.1.1.10  mrg 
   2606  1.1.1.10  mrg 5.33 'acc_attach' - Let device pointer point to device-pointer target.
   2607  1.1.1.10  mrg ======================================================================
   2608  1.1.1.10  mrg 
   2609  1.1.1.10  mrg _Description_
   2610  1.1.1.10  mrg      This function updates a pointer on the device from pointing to a
   2611  1.1.1.10  mrg      host-pointer address to pointing to the corresponding device data.
   2612  1.1.1.10  mrg 
   2613  1.1.1.10  mrg _C/C++_:
   2614  1.1.1.10  mrg      _Prototype_:   'acc_attach(h_void **ptr);'
   2615  1.1.1.10  mrg      _Prototype_:   'acc_attach_async(h_void **ptr, int async);'
   2616  1.1.1.10  mrg 
   2617  1.1.1.10  mrg _Reference_:
   2618  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2619  1.1.1.10  mrg      3.2.34.
   2620  1.1.1.10  mrg 
   2621  1.1.1.10  mrg 
   2622  1.1.1.10  mrg File: libgomp.info,  Node: acc_detach,  Next: acc_get_current_cuda_device,  Prev: acc_attach,  Up: OpenACC Runtime Library Routines
   2623  1.1.1.10  mrg 
   2624  1.1.1.10  mrg 5.34 'acc_detach' - Let device pointer point to host-pointer target.
   2625  1.1.1.10  mrg ====================================================================
   2626  1.1.1.10  mrg 
   2627  1.1.1.10  mrg _Description_
   2628  1.1.1.10  mrg      This function updates a pointer on the device from pointing to a
   2629  1.1.1.10  mrg      device-pointer address to pointing to the corresponding host data.
   2630  1.1.1.10  mrg 
   2631  1.1.1.10  mrg _C/C++_:
   2632  1.1.1.10  mrg      _Prototype_:   'acc_detach(h_void **ptr);'
   2633  1.1.1.10  mrg      _Prototype_:   'acc_detach_async(h_void **ptr, int async);'
   2634  1.1.1.10  mrg      _Prototype_:   'acc_detach_finalize(h_void **ptr);'
   2635  1.1.1.10  mrg      _Prototype_:   'acc_detach_finalize_async(h_void **ptr, int async);'
   2636  1.1.1.10  mrg 
   2637  1.1.1.10  mrg _Reference_:
   2638  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2639  1.1.1.10  mrg      3.2.35.
   2640   1.1.1.5  mrg 
   2641   1.1.1.5  mrg 
   2642  1.1.1.10  mrg File: libgomp.info,  Node: acc_get_current_cuda_device,  Next: acc_get_current_cuda_context,  Prev: acc_detach,  Up: OpenACC Runtime Library Routines
   2643   1.1.1.5  mrg 
   2644  1.1.1.10  mrg 5.35 'acc_get_current_cuda_device' - Get CUDA device handle.
   2645   1.1.1.5  mrg ============================================================
   2646   1.1.1.5  mrg 
   2647   1.1.1.5  mrg _Description_
   2648   1.1.1.8  mrg      This function returns the CUDA device handle.  This handle is the
   2649   1.1.1.5  mrg      same as used by the CUDA Runtime or Driver API's.
   2650   1.1.1.5  mrg 
   2651   1.1.1.5  mrg _C/C++_:
   2652   1.1.1.8  mrg      _Prototype_:   'void *acc_get_current_cuda_device(void);'
   2653   1.1.1.5  mrg 
   2654   1.1.1.5  mrg _Reference_:
   2655  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2656   1.1.1.5  mrg      A.2.1.1.
   2657   1.1.1.5  mrg 
   2658   1.1.1.5  mrg 
   2659   1.1.1.5  mrg File: libgomp.info,  Node: acc_get_current_cuda_context,  Next: acc_get_cuda_stream,  Prev: acc_get_current_cuda_device,  Up: OpenACC Runtime Library Routines
   2660   1.1.1.5  mrg 
   2661  1.1.1.10  mrg 5.36 'acc_get_current_cuda_context' - Get CUDA context handle.
   2662   1.1.1.5  mrg ==============================================================
   2663   1.1.1.5  mrg 
   2664   1.1.1.5  mrg _Description_
   2665   1.1.1.8  mrg      This function returns the CUDA context handle.  This handle is the
   2666   1.1.1.5  mrg      same as used by the CUDA Runtime or Driver API's.
   2667   1.1.1.5  mrg 
   2668   1.1.1.5  mrg _C/C++_:
   2669   1.1.1.9  mrg      _Prototype_:   'void *acc_get_current_cuda_context(void);'
   2670   1.1.1.5  mrg 
   2671   1.1.1.5  mrg _Reference_:
   2672  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2673   1.1.1.5  mrg      A.2.1.2.
   2674   1.1.1.5  mrg 
   2675   1.1.1.5  mrg 
   2676   1.1.1.5  mrg File: libgomp.info,  Node: acc_get_cuda_stream,  Next: acc_set_cuda_stream,  Prev: acc_get_current_cuda_context,  Up: OpenACC Runtime Library Routines
   2677   1.1.1.5  mrg 
   2678  1.1.1.10  mrg 5.37 'acc_get_cuda_stream' - Get CUDA stream handle.
   2679   1.1.1.5  mrg ====================================================
   2680   1.1.1.5  mrg 
   2681   1.1.1.5  mrg _Description_
   2682   1.1.1.9  mrg      This function returns the CUDA stream handle for the queue ASYNC.
   2683   1.1.1.9  mrg      This handle is the same as used by the CUDA Runtime or Driver
   2684   1.1.1.9  mrg      API's.
   2685   1.1.1.5  mrg 
   2686   1.1.1.5  mrg _C/C++_:
   2687   1.1.1.9  mrg      _Prototype_:   'void *acc_get_cuda_stream(int async);'
   2688   1.1.1.5  mrg 
   2689   1.1.1.5  mrg _Reference_:
   2690  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2691   1.1.1.5  mrg      A.2.1.3.
   2692   1.1.1.5  mrg 
   2693   1.1.1.5  mrg 
   2694  1.1.1.10  mrg File: libgomp.info,  Node: acc_set_cuda_stream,  Next: acc_prof_register,  Prev: acc_get_cuda_stream,  Up: OpenACC Runtime Library Routines
   2695   1.1.1.5  mrg 
   2696  1.1.1.10  mrg 5.38 'acc_set_cuda_stream' - Set CUDA stream handle.
   2697   1.1.1.5  mrg ====================================================
   2698   1.1.1.5  mrg 
   2699   1.1.1.5  mrg _Description_
   2700   1.1.1.5  mrg      This function associates the stream handle specified by STREAM with
   2701   1.1.1.9  mrg      the queue ASYNC.
   2702   1.1.1.9  mrg 
   2703   1.1.1.9  mrg      This cannot be used to change the stream handle associated with
   2704   1.1.1.9  mrg      'acc_async_sync'.
   2705   1.1.1.9  mrg 
   2706   1.1.1.9  mrg      The return value is not specified.
   2707   1.1.1.5  mrg 
   2708   1.1.1.5  mrg _C/C++_:
   2709   1.1.1.9  mrg      _Prototype_:   'int acc_set_cuda_stream(int async, void *stream);'
   2710   1.1.1.5  mrg 
   2711   1.1.1.5  mrg _Reference_:
   2712  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section
   2713   1.1.1.5  mrg      A.2.1.4.
   2714   1.1.1.5  mrg 
   2715   1.1.1.5  mrg 
   2716  1.1.1.10  mrg File: libgomp.info,  Node: acc_prof_register,  Next: acc_prof_unregister,  Prev: acc_set_cuda_stream,  Up: OpenACC Runtime Library Routines
   2717  1.1.1.10  mrg 
   2718  1.1.1.10  mrg 5.39 'acc_prof_register' - Register callbacks.
   2719  1.1.1.10  mrg ==============================================
   2720  1.1.1.10  mrg 
   2721  1.1.1.10  mrg _Description_:
   2722  1.1.1.10  mrg      This function registers callbacks.
   2723  1.1.1.10  mrg 
   2724  1.1.1.10  mrg _C/C++_:
   2725  1.1.1.10  mrg      _Prototype_:   'void acc_prof_register (acc_event_t, acc_prof_callback,
   2726  1.1.1.10  mrg                     acc_register_t);'
   2727  1.1.1.10  mrg 
   2728  1.1.1.10  mrg _See also_:
   2729  1.1.1.10  mrg      *note OpenACC Profiling Interface::
   2730  1.1.1.10  mrg 
   2731  1.1.1.10  mrg _Reference_:
   2732  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section 5.3.
   2733  1.1.1.10  mrg 
   2734  1.1.1.10  mrg 
   2735  1.1.1.10  mrg File: libgomp.info,  Node: acc_prof_unregister,  Next: acc_prof_lookup,  Prev: acc_prof_register,  Up: OpenACC Runtime Library Routines
   2736  1.1.1.10  mrg 
   2737  1.1.1.10  mrg 5.40 'acc_prof_unregister' - Unregister callbacks.
   2738  1.1.1.10  mrg ==================================================
   2739  1.1.1.10  mrg 
   2740  1.1.1.10  mrg _Description_:
   2741  1.1.1.10  mrg      This function unregisters callbacks.
   2742  1.1.1.10  mrg 
   2743  1.1.1.10  mrg _C/C++_:
   2744  1.1.1.10  mrg      _Prototype_:   'void acc_prof_unregister (acc_event_t,
   2745  1.1.1.10  mrg                     acc_prof_callback, acc_register_t);'
   2746  1.1.1.10  mrg 
   2747  1.1.1.10  mrg _See also_:
   2748  1.1.1.10  mrg      *note OpenACC Profiling Interface::
   2749  1.1.1.10  mrg 
   2750  1.1.1.10  mrg _Reference_:
   2751  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section 5.3.
   2752  1.1.1.10  mrg 
   2753  1.1.1.10  mrg 
   2754  1.1.1.10  mrg File: libgomp.info,  Node: acc_prof_lookup,  Next: acc_register_library,  Prev: acc_prof_unregister,  Up: OpenACC Runtime Library Routines
   2755  1.1.1.10  mrg 
   2756  1.1.1.10  mrg 5.41 'acc_prof_lookup' - Obtain inquiry functions.
   2757  1.1.1.10  mrg ==================================================
   2758  1.1.1.10  mrg 
   2759  1.1.1.10  mrg _Description_:
   2760  1.1.1.10  mrg      Function to obtain inquiry functions.
   2761  1.1.1.10  mrg 
   2762  1.1.1.10  mrg _C/C++_:
   2763  1.1.1.10  mrg      _Prototype_:   'acc_query_fn acc_prof_lookup (const char *);'
   2764  1.1.1.10  mrg 
   2765  1.1.1.10  mrg _See also_:
   2766  1.1.1.10  mrg      *note OpenACC Profiling Interface::
   2767  1.1.1.10  mrg 
   2768  1.1.1.10  mrg _Reference_:
   2769  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section 5.3.
   2770  1.1.1.10  mrg 
   2771  1.1.1.10  mrg 
   2772  1.1.1.10  mrg File: libgomp.info,  Node: acc_register_library,  Prev: acc_prof_lookup,  Up: OpenACC Runtime Library Routines
   2773  1.1.1.10  mrg 
   2774  1.1.1.10  mrg 5.42 'acc_register_library' - Library registration.
   2775  1.1.1.10  mrg ===================================================
   2776  1.1.1.10  mrg 
   2777  1.1.1.10  mrg _Description_:
   2778  1.1.1.10  mrg      Function for library registration.
   2779  1.1.1.10  mrg 
   2780  1.1.1.10  mrg _C/C++_:
   2781  1.1.1.10  mrg      _Prototype_:   'void acc_register_library (acc_prof_reg, acc_prof_reg,
   2782  1.1.1.10  mrg                     acc_prof_lookup_func);'
   2783  1.1.1.10  mrg 
   2784  1.1.1.10  mrg _See also_:
   2785  1.1.1.10  mrg      *note OpenACC Profiling Interface::, *note ACC_PROFLIB::
   2786  1.1.1.10  mrg 
   2787  1.1.1.10  mrg _Reference_:
   2788  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section 5.3.
   2789  1.1.1.10  mrg 
   2790  1.1.1.10  mrg 
   2791   1.1.1.5  mrg File: libgomp.info,  Node: OpenACC Environment Variables,  Next: CUDA Streams Usage,  Prev: OpenACC Runtime Library Routines,  Up: Top
   2792   1.1.1.5  mrg 
   2793   1.1.1.5  mrg 6 OpenACC Environment Variables
   2794   1.1.1.5  mrg *******************************
   2795   1.1.1.5  mrg 
   2796   1.1.1.8  mrg The variables 'ACC_DEVICE_TYPE' and 'ACC_DEVICE_NUM' are defined by
   2797   1.1.1.5  mrg section 4 of the OpenACC specification in version 2.0.  The variable
   2798  1.1.1.10  mrg 'ACC_PROFLIB' is defined by section 4 of the OpenACC specification in
   2799  1.1.1.10  mrg version 2.6.  The variable 'GCC_ACC_NOTIFY' is used for diagnostic
   2800  1.1.1.10  mrg purposes.
   2801   1.1.1.5  mrg 
   2802   1.1.1.5  mrg * Menu:
   2803   1.1.1.5  mrg 
   2804   1.1.1.5  mrg * ACC_DEVICE_TYPE::
   2805   1.1.1.5  mrg * ACC_DEVICE_NUM::
   2806  1.1.1.10  mrg * ACC_PROFLIB::
   2807   1.1.1.5  mrg * GCC_ACC_NOTIFY::
   2808   1.1.1.5  mrg 
   2809   1.1.1.5  mrg 
   2810   1.1.1.5  mrg File: libgomp.info,  Node: ACC_DEVICE_TYPE,  Next: ACC_DEVICE_NUM,  Up: OpenACC Environment Variables
   2811   1.1.1.5  mrg 
   2812   1.1.1.8  mrg 6.1 'ACC_DEVICE_TYPE'
   2813   1.1.1.5  mrg =====================
   2814   1.1.1.5  mrg 
   2815   1.1.1.5  mrg _Reference_:
   2816  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section 4.1.
   2817   1.1.1.5  mrg 
   2818   1.1.1.5  mrg 
   2819  1.1.1.10  mrg File: libgomp.info,  Node: ACC_DEVICE_NUM,  Next: ACC_PROFLIB,  Prev: ACC_DEVICE_TYPE,  Up: OpenACC Environment Variables
   2820   1.1.1.5  mrg 
   2821   1.1.1.8  mrg 6.2 'ACC_DEVICE_NUM'
   2822   1.1.1.5  mrg ====================
   2823   1.1.1.5  mrg 
   2824   1.1.1.5  mrg _Reference_:
   2825  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section 4.2.
   2826  1.1.1.10  mrg 
   2827  1.1.1.10  mrg 
   2828  1.1.1.10  mrg File: libgomp.info,  Node: ACC_PROFLIB,  Next: GCC_ACC_NOTIFY,  Prev: ACC_DEVICE_NUM,  Up: OpenACC Environment Variables
   2829  1.1.1.10  mrg 
   2830  1.1.1.10  mrg 6.3 'ACC_PROFLIB'
   2831  1.1.1.10  mrg =================
   2832  1.1.1.10  mrg 
   2833  1.1.1.10  mrg _See also_:
   2834  1.1.1.10  mrg      *note acc_register_library::, *note OpenACC Profiling Interface::
   2835  1.1.1.10  mrg 
   2836  1.1.1.10  mrg _Reference_:
   2837  1.1.1.10  mrg      OpenACC specification v2.6 (https://www.openacc.org), section 4.3.
   2838   1.1.1.5  mrg 
   2839   1.1.1.5  mrg 
   2840  1.1.1.10  mrg File: libgomp.info,  Node: GCC_ACC_NOTIFY,  Prev: ACC_PROFLIB,  Up: OpenACC Environment Variables
   2841   1.1.1.5  mrg 
   2842  1.1.1.10  mrg 6.4 'GCC_ACC_NOTIFY'
   2843   1.1.1.5  mrg ====================
   2844   1.1.1.5  mrg 
   2845   1.1.1.5  mrg _Description_:
   2846   1.1.1.5  mrg      Print debug information pertaining to the accelerator.
   2847   1.1.1.5  mrg 
   2848   1.1.1.5  mrg 
   2849   1.1.1.5  mrg File: libgomp.info,  Node: CUDA Streams Usage,  Next: OpenACC Library Interoperability,  Prev: OpenACC Environment Variables,  Up: Top
   2850   1.1.1.5  mrg 
   2851   1.1.1.5  mrg 7 CUDA Streams Usage
   2852   1.1.1.5  mrg ********************
   2853   1.1.1.5  mrg 
   2854   1.1.1.8  mrg This applies to the 'nvptx' plugin only.
   2855   1.1.1.5  mrg 
   2856   1.1.1.5  mrg    The library provides elements that perform asynchronous movement of
   2857   1.1.1.5  mrg data and asynchronous operation of computing constructs.  This
   2858   1.1.1.5  mrg asynchronous functionality is implemented by making use of CUDA
   2859   1.1.1.5  mrg streams(1).
   2860   1.1.1.5  mrg 
   2861  1.1.1.10  mrg    The primary means by that the asynchronous functionality is accessed
   2862   1.1.1.5  mrg is through the use of those OpenACC directives which make use of the
   2863   1.1.1.8  mrg 'async' and 'wait' clauses.  When the 'async' clause is first used with
   2864   1.1.1.8  mrg a directive, it creates a CUDA stream.  If an 'async-argument' is used
   2865   1.1.1.8  mrg with the 'async' clause, then the stream is associated with the
   2866   1.1.1.8  mrg specified 'async-argument'.
   2867   1.1.1.5  mrg 
   2868   1.1.1.5  mrg    Following the creation of an association between a CUDA stream and
   2869   1.1.1.8  mrg the 'async-argument' of an 'async' clause, both the 'wait' clause and
   2870   1.1.1.8  mrg the 'wait' directive can be used.  When either the clause or directive
   2871   1.1.1.5  mrg is used after stream creation, it creates a rendezvous point whereby
   2872   1.1.1.5  mrg execution waits until all operations associated with the
   2873   1.1.1.8  mrg 'async-argument', that is, stream, have completed.
   2874   1.1.1.5  mrg 
   2875   1.1.1.5  mrg    Normally, the management of the streams that are created as a result
   2876   1.1.1.8  mrg of using the 'async' clause, is done without any intervention by the
   2877   1.1.1.8  mrg caller.  This implies the association between the 'async-argument' and
   2878   1.1.1.5  mrg the CUDA stream will be maintained for the lifetime of the program.
   2879   1.1.1.5  mrg However, this association can be changed through the use of the library
   2880   1.1.1.8  mrg function 'acc_set_cuda_stream'.  When the function 'acc_set_cuda_stream'
   2881   1.1.1.8  mrg is called, the CUDA stream that was originally associated with the
   2882   1.1.1.8  mrg 'async' clause will be destroyed.  Caution should be taken when changing
   2883   1.1.1.8  mrg the association as subsequent references to the 'async-argument' refer
   2884   1.1.1.8  mrg to a different CUDA stream.
   2885   1.1.1.5  mrg 
   2886   1.1.1.5  mrg    ---------- Footnotes ----------
   2887   1.1.1.5  mrg 
   2888   1.1.1.5  mrg    (1) See "Stream Management" in "CUDA Driver API", TRM-06703-001,
   2889   1.1.1.5  mrg Version 5.5, for additional information
   2890   1.1.1.5  mrg 
   2891   1.1.1.5  mrg 
   2892  1.1.1.10  mrg File: libgomp.info,  Node: OpenACC Library Interoperability,  Next: OpenACC Profiling Interface,  Prev: CUDA Streams Usage,  Up: Top
   2893   1.1.1.5  mrg 
   2894   1.1.1.5  mrg 8 OpenACC Library Interoperability
   2895   1.1.1.5  mrg **********************************
   2896   1.1.1.5  mrg 
   2897   1.1.1.5  mrg 8.1 Introduction
   2898   1.1.1.5  mrg ================
   2899   1.1.1.5  mrg 
   2900   1.1.1.5  mrg The OpenACC library uses the CUDA Driver API, and may interact with
   2901   1.1.1.8  mrg programs that use the Runtime library directly, or another library based
   2902   1.1.1.8  mrg on the Runtime library, e.g., CUBLAS(1). This chapter describes the use
   2903   1.1.1.8  mrg cases and what changes are required in order to use both the OpenACC
   2904   1.1.1.8  mrg library and the CUBLAS and Runtime libraries within a program.
   2905   1.1.1.5  mrg 
   2906   1.1.1.5  mrg 8.2 First invocation: NVIDIA CUBLAS library API
   2907   1.1.1.5  mrg ===============================================
   2908   1.1.1.5  mrg 
   2909   1.1.1.5  mrg In this first use case (see below), a function in the CUBLAS library is
   2910   1.1.1.8  mrg called prior to any of the functions in the OpenACC library.  More
   2911   1.1.1.8  mrg specifically, the function 'cublasCreate()'.
   2912   1.1.1.5  mrg 
   2913   1.1.1.5  mrg    When invoked, the function initializes the library and allocates the
   2914   1.1.1.5  mrg hardware resources on the host and the device on behalf of the caller.
   2915   1.1.1.5  mrg Once the initialization and allocation has completed, a handle is
   2916   1.1.1.8  mrg returned to the caller.  The OpenACC library also requires
   2917   1.1.1.8  mrg initialization and allocation of hardware resources.  Since the CUBLAS
   2918   1.1.1.8  mrg library has already allocated the hardware resources for the device, all
   2919   1.1.1.8  mrg that is left to do is to initialize the OpenACC library and acquire the
   2920   1.1.1.8  mrg hardware resources on the host.
   2921   1.1.1.5  mrg 
   2922   1.1.1.5  mrg    Prior to calling the OpenACC function that initializes the library
   2923   1.1.1.8  mrg and allocate the host hardware resources, you need to acquire the device
   2924   1.1.1.8  mrg number that was allocated during the call to 'cublasCreate()'.  The
   2925   1.1.1.8  mrg invoking of the runtime library function 'cudaGetDevice()' accomplishes
   2926   1.1.1.8  mrg this.  Once acquired, the device number is passed along with the device
   2927   1.1.1.8  mrg type as parameters to the OpenACC library function
   2928   1.1.1.8  mrg 'acc_set_device_num()'.
   2929   1.1.1.8  mrg 
   2930   1.1.1.8  mrg    Once the call to 'acc_set_device_num()' has completed, the OpenACC
   2931   1.1.1.8  mrg library uses the context that was created during the call to
   2932   1.1.1.8  mrg 'cublasCreate()'.  In other words, both libraries will be sharing the
   2933   1.1.1.5  mrg same context.
   2934   1.1.1.5  mrg 
   2935   1.1.1.5  mrg          /* Create the handle */
   2936   1.1.1.5  mrg          s = cublasCreate(&h);
   2937   1.1.1.5  mrg          if (s != CUBLAS_STATUS_SUCCESS)
   2938   1.1.1.5  mrg          {
   2939   1.1.1.5  mrg              fprintf(stderr, "cublasCreate failed %d\n", s);
   2940   1.1.1.5  mrg              exit(EXIT_FAILURE);
   2941   1.1.1.5  mrg          }
   2942   1.1.1.5  mrg 
   2943   1.1.1.5  mrg          /* Get the device number */
   2944   1.1.1.5  mrg          e = cudaGetDevice(&dev);
   2945   1.1.1.5  mrg          if (e != cudaSuccess)
   2946   1.1.1.5  mrg          {
   2947   1.1.1.5  mrg              fprintf(stderr, "cudaGetDevice failed %d\n", e);
   2948   1.1.1.5  mrg              exit(EXIT_FAILURE);
   2949   1.1.1.5  mrg          }
   2950   1.1.1.5  mrg 
   2951   1.1.1.5  mrg          /* Initialize OpenACC library and use device 'dev' */
   2952   1.1.1.5  mrg          acc_set_device_num(dev, acc_device_nvidia);
   2953   1.1.1.8  mrg 
   2954   1.1.1.8  mrg                               Use Case 1
   2955   1.1.1.5  mrg 
   2956   1.1.1.5  mrg 8.3 First invocation: OpenACC library API
   2957   1.1.1.5  mrg =========================================
   2958   1.1.1.5  mrg 
   2959   1.1.1.5  mrg In this second use case (see below), a function in the OpenACC library
   2960   1.1.1.8  mrg is called prior to any of the functions in the CUBLAS library.  More
   2961   1.1.1.8  mrg specificially, the function 'acc_set_device_num()'.
   2962   1.1.1.5  mrg 
   2963   1.1.1.8  mrg    In the use case presented here, the function 'acc_set_device_num()'
   2964   1.1.1.5  mrg is used to both initialize the OpenACC library and allocate the hardware
   2965   1.1.1.8  mrg resources on the host and the device.  In the call to the function, the
   2966   1.1.1.8  mrg call parameters specify which device to use and what device type to use,
   2967   1.1.1.8  mrg i.e., 'acc_device_nvidia'.  It should be noted that this is but one
   2968   1.1.1.5  mrg method to initialize the OpenACC library and allocate the appropriate
   2969   1.1.1.8  mrg hardware resources.  Other methods are available through the use of
   2970   1.1.1.5  mrg environment variables and these will be discussed in the next section.
   2971   1.1.1.5  mrg 
   2972   1.1.1.8  mrg    Once the call to 'acc_set_device_num()' has completed, other OpenACC
   2973   1.1.1.5  mrg functions can be called as seen with multiple calls being made to
   2974   1.1.1.8  mrg 'acc_copyin()'.  In addition, calls can be made to functions in the
   2975   1.1.1.8  mrg CUBLAS library.  In the use case a call to 'cublasCreate()' is made
   2976   1.1.1.8  mrg subsequent to the calls to 'acc_copyin()'.  As seen in the previous use
   2977   1.1.1.8  mrg case, a call to 'cublasCreate()' initializes the CUBLAS library and
   2978   1.1.1.5  mrg allocates the hardware resources on the host and the device.  However,
   2979   1.1.1.8  mrg since the device has already been allocated, 'cublasCreate()' will only
   2980   1.1.1.5  mrg initialize the CUBLAS library and allocate the appropriate hardware
   2981   1.1.1.8  mrg resources on the host.  The context that was created as part of the
   2982   1.1.1.5  mrg OpenACC initialization is shared with the CUBLAS library, similarly to
   2983   1.1.1.5  mrg the first use case.
   2984   1.1.1.5  mrg 
   2985   1.1.1.5  mrg          dev = 0;
   2986   1.1.1.5  mrg 
   2987   1.1.1.5  mrg          acc_set_device_num(dev, acc_device_nvidia);
   2988   1.1.1.5  mrg 
   2989   1.1.1.5  mrg          /* Copy the first set to the device */
   2990   1.1.1.5  mrg          d_X = acc_copyin(&h_X[0], N * sizeof (float));
   2991   1.1.1.5  mrg          if (d_X == NULL)
   2992   1.1.1.5  mrg          {
   2993   1.1.1.5  mrg              fprintf(stderr, "copyin error h_X\n");
   2994   1.1.1.5  mrg              exit(EXIT_FAILURE);
   2995   1.1.1.5  mrg          }
   2996   1.1.1.5  mrg 
   2997   1.1.1.5  mrg          /* Copy the second set to the device */
   2998   1.1.1.5  mrg          d_Y = acc_copyin(&h_Y1[0], N * sizeof (float));
   2999   1.1.1.5  mrg          if (d_Y == NULL)
   3000   1.1.1.5  mrg          {
   3001   1.1.1.5  mrg              fprintf(stderr, "copyin error h_Y1\n");
   3002   1.1.1.5  mrg              exit(EXIT_FAILURE);
   3003   1.1.1.5  mrg          }
   3004   1.1.1.5  mrg 
   3005   1.1.1.5  mrg          /* Create the handle */
   3006   1.1.1.5  mrg          s = cublasCreate(&h);
   3007   1.1.1.5  mrg          if (s != CUBLAS_STATUS_SUCCESS)
   3008   1.1.1.5  mrg          {
   3009   1.1.1.5  mrg              fprintf(stderr, "cublasCreate failed %d\n", s);
   3010   1.1.1.5  mrg              exit(EXIT_FAILURE);
   3011   1.1.1.5  mrg          }
   3012   1.1.1.5  mrg 
   3013   1.1.1.5  mrg          /* Perform saxpy using CUBLAS library function */
   3014   1.1.1.5  mrg          s = cublasSaxpy(h, N, &alpha, d_X, 1, d_Y, 1);
   3015   1.1.1.5  mrg          if (s != CUBLAS_STATUS_SUCCESS)
   3016   1.1.1.5  mrg          {
   3017   1.1.1.5  mrg              fprintf(stderr, "cublasSaxpy failed %d\n", s);
   3018   1.1.1.5  mrg              exit(EXIT_FAILURE);
   3019   1.1.1.5  mrg          }
   3020   1.1.1.5  mrg 
   3021   1.1.1.5  mrg          /* Copy the results from the device */
   3022   1.1.1.5  mrg          acc_memcpy_from_device(&h_Y1[0], d_Y, N * sizeof (float));
   3023   1.1.1.8  mrg 
   3024   1.1.1.8  mrg                               Use Case 2
   3025   1.1.1.5  mrg 
   3026   1.1.1.5  mrg 8.4 OpenACC library and environment variables
   3027   1.1.1.5  mrg =============================================
   3028   1.1.1.5  mrg 
   3029   1.1.1.5  mrg There are two environment variables associated with the OpenACC library
   3030   1.1.1.5  mrg that may be used to control the device type and device number:
   3031  1.1.1.10  mrg 'ACC_DEVICE_TYPE' and 'ACC_DEVICE_NUM', respectively.  These two
   3032  1.1.1.10  mrg environment variables can be used as an alternative to calling
   3033   1.1.1.8  mrg 'acc_set_device_num()'.  As seen in the second use case, the device type
   3034   1.1.1.8  mrg and device number were specified using 'acc_set_device_num()'.  If
   3035   1.1.1.5  mrg however, the aforementioned environment variables were set, then the
   3036   1.1.1.8  mrg call to 'acc_set_device_num()' would not be required.
   3037   1.1.1.5  mrg 
   3038   1.1.1.8  mrg    The use of the environment variables is only relevant when an OpenACC
   3039   1.1.1.8  mrg function is called prior to a call to 'cudaCreate()'.  If 'cudaCreate()'
   3040   1.1.1.8  mrg is called prior to a call to an OpenACC function, then you must call
   3041   1.1.1.8  mrg 'acc_set_device_num()'(2)
   3042   1.1.1.5  mrg 
   3043   1.1.1.5  mrg    ---------- Footnotes ----------
   3044   1.1.1.5  mrg 
   3045   1.1.1.5  mrg    (1) See section 2.26, "Interactions with the CUDA Driver API" in
   3046   1.1.1.5  mrg "CUDA Runtime API", Version 5.5, and section 2.27, "VDPAU
   3047   1.1.1.8  mrg Interoperability", in "CUDA Driver API", TRM-06703-001, Version 5.5, for
   3048   1.1.1.8  mrg additional information on library interoperability.
   3049   1.1.1.5  mrg 
   3050   1.1.1.8  mrg    (2) More complete information about 'ACC_DEVICE_TYPE' and
   3051   1.1.1.8  mrg 'ACC_DEVICE_NUM' can be found in sections 4.1 and 4.2 of the OpenACC
   3052   1.1.1.8  mrg (https://www.openacc.org) Application Programming Interface, Version
   3053  1.1.1.10  mrg 2.6.
   3054   1.1.1.5  mrg 
   3055   1.1.1.5  mrg 
   3056  1.1.1.10  mrg File: libgomp.info,  Node: OpenACC Profiling Interface,  Next: The libgomp ABI,  Prev: OpenACC Library Interoperability,  Up: Top
   3057   1.1.1.5  mrg 
   3058  1.1.1.10  mrg 9 OpenACC Profiling Interface
   3059  1.1.1.10  mrg *****************************
   3060  1.1.1.10  mrg 
   3061  1.1.1.10  mrg 9.1 Implementation Status and Implementation-Defined Behavior
   3062  1.1.1.10  mrg =============================================================
   3063  1.1.1.10  mrg 
   3064  1.1.1.10  mrg We're implementing the OpenACC Profiling Interface as defined by the
   3065  1.1.1.10  mrg OpenACC 2.6 specification.  We're clarifying some aspects here as
   3066  1.1.1.10  mrg _implementation-defined behavior_, while they're still under discussion
   3067  1.1.1.10  mrg within the OpenACC Technical Committee.
   3068  1.1.1.10  mrg 
   3069  1.1.1.10  mrg    This implementation is tuned to keep the performance impact as low as
   3070  1.1.1.10  mrg possible for the (very common) case that the Profiling Interface is not
   3071  1.1.1.10  mrg enabled.  This is relevant, as the Profiling Interface affects all the
   3072  1.1.1.10  mrg _hot_ code paths (in the target code, not in the offloaded code).  Users
   3073  1.1.1.10  mrg of the OpenACC Profiling Interface can be expected to understand that
   3074  1.1.1.10  mrg performance will be impacted to some degree once the Profiling Interface
   3075  1.1.1.10  mrg has gotten enabled: for example, because of the _runtime_ (libgomp)
   3076  1.1.1.10  mrg calling into a third-party _library_ for every event that has been
   3077  1.1.1.10  mrg registered.
   3078  1.1.1.10  mrg 
   3079  1.1.1.10  mrg    We're not yet accounting for the fact that 'OpenACC events may occur
   3080  1.1.1.10  mrg during event processing'.  We just handle one case specially, as
   3081  1.1.1.10  mrg required by CUDA 9.0 'nvprof', that 'acc_get_device_type' (*note
   3082  1.1.1.10  mrg acc_get_device_type::)) may be called from 'acc_ev_device_init_start',
   3083  1.1.1.10  mrg 'acc_ev_device_init_end' callbacks.
   3084  1.1.1.10  mrg 
   3085  1.1.1.10  mrg    We're not yet implementing initialization via a
   3086  1.1.1.10  mrg 'acc_register_library' function that is either statically linked in, or
   3087  1.1.1.10  mrg dynamically via 'LD_PRELOAD'.  Initialization via 'acc_register_library'
   3088  1.1.1.10  mrg functions dynamically loaded via the 'ACC_PROFLIB' environment variable
   3089  1.1.1.10  mrg does work, as does directly calling 'acc_prof_register',
   3090  1.1.1.10  mrg 'acc_prof_unregister', 'acc_prof_lookup'.
   3091  1.1.1.10  mrg 
   3092  1.1.1.10  mrg    As currently there are no inquiry functions defined, calls to
   3093  1.1.1.10  mrg 'acc_prof_lookup' will always return 'NULL'.
   3094  1.1.1.10  mrg 
   3095  1.1.1.10  mrg    There aren't separate _start_, _stop_ events defined for the event
   3096  1.1.1.10  mrg types 'acc_ev_create', 'acc_ev_delete', 'acc_ev_alloc', 'acc_ev_free'.
   3097  1.1.1.10  mrg It's not clear if these should be triggered before or after the actual
   3098  1.1.1.10  mrg device-specific call is made.  We trigger them after.
   3099  1.1.1.10  mrg 
   3100  1.1.1.10  mrg    Remarks about data provided to callbacks:
   3101  1.1.1.10  mrg 
   3102  1.1.1.10  mrg 'acc_prof_info.event_type'
   3103  1.1.1.10  mrg      It's not clear if for _nested_ event callbacks (for example,
   3104  1.1.1.10  mrg      'acc_ev_enqueue_launch_start' as part of a parent compute
   3105  1.1.1.10  mrg      construct), this should be set for the nested event
   3106  1.1.1.10  mrg      ('acc_ev_enqueue_launch_start'), or if the value of the parent
   3107  1.1.1.10  mrg      construct should remain ('acc_ev_compute_construct_start').  In
   3108  1.1.1.10  mrg      this implementation, the value will generally correspond to the
   3109  1.1.1.10  mrg      innermost nested event type.
   3110  1.1.1.10  mrg 
   3111  1.1.1.10  mrg 'acc_prof_info.device_type'
   3112  1.1.1.10  mrg 
   3113  1.1.1.10  mrg         * For 'acc_ev_compute_construct_start', and in presence of an
   3114  1.1.1.10  mrg           'if' clause with _false_ argument, this will still refer to
   3115  1.1.1.10  mrg           the offloading device type.  It's not clear if that's the
   3116  1.1.1.10  mrg           expected behavior.
   3117  1.1.1.10  mrg 
   3118  1.1.1.10  mrg         * Complementary to the item before, for
   3119  1.1.1.10  mrg           'acc_ev_compute_construct_end', this is set to
   3120  1.1.1.10  mrg           'acc_device_host' in presence of an 'if' clause with _false_
   3121  1.1.1.10  mrg           argument.  It's not clear if that's the expected behavior.
   3122  1.1.1.10  mrg 
   3123  1.1.1.10  mrg 'acc_prof_info.thread_id'
   3124  1.1.1.10  mrg      Always '-1'; not yet implemented.
   3125  1.1.1.10  mrg 
   3126  1.1.1.10  mrg 'acc_prof_info.async'
   3127  1.1.1.10  mrg 
   3128  1.1.1.10  mrg         * Not yet implemented correctly for
   3129  1.1.1.10  mrg           'acc_ev_compute_construct_start'.
   3130  1.1.1.10  mrg 
   3131  1.1.1.10  mrg         * In a compute construct, for host-fallback
   3132  1.1.1.10  mrg           execution/'acc_device_host' it will always be
   3133  1.1.1.10  mrg           'acc_async_sync'.  It's not clear if that's the expected
   3134  1.1.1.10  mrg           behavior.
   3135  1.1.1.10  mrg 
   3136  1.1.1.10  mrg         * For 'acc_ev_device_init_start' and 'acc_ev_device_init_end',
   3137  1.1.1.10  mrg           it will always be 'acc_async_sync'.  It's not clear if that's
   3138  1.1.1.10  mrg           the expected behavior.
   3139  1.1.1.10  mrg 
   3140  1.1.1.10  mrg 'acc_prof_info.async_queue'
   3141  1.1.1.10  mrg      There is no 'limited number of asynchronous queues' in libgomp.
   3142  1.1.1.10  mrg      This will always have the same value as 'acc_prof_info.async'.
   3143  1.1.1.10  mrg 
   3144  1.1.1.10  mrg 'acc_prof_info.src_file'
   3145  1.1.1.10  mrg      Always 'NULL'; not yet implemented.
   3146  1.1.1.10  mrg 
   3147  1.1.1.10  mrg 'acc_prof_info.func_name'
   3148  1.1.1.10  mrg      Always 'NULL'; not yet implemented.
   3149  1.1.1.10  mrg 
   3150  1.1.1.10  mrg 'acc_prof_info.line_no'
   3151  1.1.1.10  mrg      Always '-1'; not yet implemented.
   3152  1.1.1.10  mrg 
   3153  1.1.1.10  mrg 'acc_prof_info.end_line_no'
   3154  1.1.1.10  mrg      Always '-1'; not yet implemented.
   3155  1.1.1.10  mrg 
   3156  1.1.1.10  mrg 'acc_prof_info.func_line_no'
   3157  1.1.1.10  mrg      Always '-1'; not yet implemented.
   3158  1.1.1.10  mrg 
   3159  1.1.1.10  mrg 'acc_prof_info.func_end_line_no'
   3160  1.1.1.10  mrg      Always '-1'; not yet implemented.
   3161  1.1.1.10  mrg 
   3162  1.1.1.10  mrg 'acc_event_info.event_type', 'acc_event_info.*.event_type'
   3163  1.1.1.10  mrg      Relating to 'acc_prof_info.event_type' discussed above, in this
   3164  1.1.1.10  mrg      implementation, this will always be the same value as
   3165  1.1.1.10  mrg      'acc_prof_info.event_type'.
   3166  1.1.1.10  mrg 
   3167  1.1.1.10  mrg 'acc_event_info.*.parent_construct'
   3168  1.1.1.10  mrg 
   3169  1.1.1.10  mrg         * Will be 'acc_construct_parallel' for all OpenACC compute
   3170  1.1.1.10  mrg           constructs as well as many OpenACC Runtime API calls; should
   3171  1.1.1.10  mrg           be the one matching the actual construct, or
   3172  1.1.1.10  mrg           'acc_construct_runtime_api', respectively.
   3173  1.1.1.10  mrg 
   3174  1.1.1.10  mrg         * Will be 'acc_construct_enter_data' or
   3175  1.1.1.10  mrg           'acc_construct_exit_data' when processing variable mappings
   3176  1.1.1.10  mrg           specified in OpenACC _declare_ directives; should be
   3177  1.1.1.10  mrg           'acc_construct_declare'.
   3178  1.1.1.10  mrg 
   3179  1.1.1.10  mrg         * For implicit 'acc_ev_device_init_start',
   3180  1.1.1.10  mrg           'acc_ev_device_init_end', and explicit as well as implicit
   3181  1.1.1.10  mrg           'acc_ev_alloc', 'acc_ev_free', 'acc_ev_enqueue_upload_start',
   3182  1.1.1.10  mrg           'acc_ev_enqueue_upload_end', 'acc_ev_enqueue_download_start',
   3183  1.1.1.10  mrg           and 'acc_ev_enqueue_download_end', will be
   3184  1.1.1.10  mrg           'acc_construct_parallel'; should reflect the real parent
   3185  1.1.1.10  mrg           construct.
   3186  1.1.1.10  mrg 
   3187  1.1.1.10  mrg 'acc_event_info.*.implicit'
   3188  1.1.1.10  mrg      For 'acc_ev_alloc', 'acc_ev_free', 'acc_ev_enqueue_upload_start',
   3189  1.1.1.10  mrg      'acc_ev_enqueue_upload_end', 'acc_ev_enqueue_download_start', and
   3190  1.1.1.10  mrg      'acc_ev_enqueue_download_end', this currently will be '1' also for
   3191  1.1.1.10  mrg      explicit usage.
   3192  1.1.1.10  mrg 
   3193  1.1.1.10  mrg 'acc_event_info.data_event.var_name'
   3194  1.1.1.10  mrg      Always 'NULL'; not yet implemented.
   3195  1.1.1.10  mrg 
   3196  1.1.1.10  mrg 'acc_event_info.data_event.host_ptr'
   3197  1.1.1.10  mrg      For 'acc_ev_alloc', and 'acc_ev_free', this is always 'NULL'.
   3198  1.1.1.10  mrg 
   3199  1.1.1.10  mrg 'typedef union acc_api_info'
   3200  1.1.1.10  mrg      ... as printed in '5.2.3. Third Argument: API-Specific
   3201  1.1.1.10  mrg      Information'.  This should obviously be 'typedef _struct_
   3202  1.1.1.10  mrg      acc_api_info'.
   3203  1.1.1.10  mrg 
   3204  1.1.1.10  mrg 'acc_api_info.device_api'
   3205  1.1.1.10  mrg      Possibly not yet implemented correctly for
   3206  1.1.1.10  mrg      'acc_ev_compute_construct_start', 'acc_ev_device_init_start',
   3207  1.1.1.10  mrg      'acc_ev_device_init_end': will always be 'acc_device_api_none' for
   3208  1.1.1.10  mrg      these event types.  For 'acc_ev_enter_data_start', it will be
   3209  1.1.1.10  mrg      'acc_device_api_none' in some cases.
   3210  1.1.1.10  mrg 
   3211  1.1.1.10  mrg 'acc_api_info.device_type'
   3212  1.1.1.10  mrg      Always the same as 'acc_prof_info.device_type'.
   3213  1.1.1.10  mrg 
   3214  1.1.1.10  mrg 'acc_api_info.vendor'
   3215  1.1.1.10  mrg      Always '-1'; not yet implemented.
   3216  1.1.1.10  mrg 
   3217  1.1.1.10  mrg 'acc_api_info.device_handle'
   3218  1.1.1.10  mrg      Always 'NULL'; not yet implemented.
   3219  1.1.1.10  mrg 
   3220  1.1.1.10  mrg 'acc_api_info.context_handle'
   3221  1.1.1.10  mrg      Always 'NULL'; not yet implemented.
   3222  1.1.1.10  mrg 
   3223  1.1.1.10  mrg 'acc_api_info.async_handle'
   3224  1.1.1.10  mrg      Always 'NULL'; not yet implemented.
   3225  1.1.1.10  mrg 
   3226  1.1.1.10  mrg    Remarks about certain event types:
   3227  1.1.1.10  mrg 
   3228  1.1.1.10  mrg 'acc_ev_device_init_start', 'acc_ev_device_init_end'
   3229  1.1.1.10  mrg 
   3230  1.1.1.10  mrg         * Whan a compute construct triggers implicit
   3231  1.1.1.10  mrg           'acc_ev_device_init_start' and 'acc_ev_device_init_end'
   3232  1.1.1.10  mrg           events, they currently aren't _nested within_ the
   3233  1.1.1.10  mrg           corresponding 'acc_ev_compute_construct_start' and
   3234  1.1.1.10  mrg           'acc_ev_compute_construct_end', but they're currently observed
   3235  1.1.1.10  mrg           _before_ 'acc_ev_compute_construct_start'.  It's not clear
   3236  1.1.1.10  mrg           what to do: the standard asks us provide a lot of details to
   3237  1.1.1.10  mrg           the 'acc_ev_compute_construct_start' callback, without
   3238  1.1.1.10  mrg           (implicitly) initializing a device before?
   3239  1.1.1.10  mrg 
   3240  1.1.1.10  mrg         * Callbacks for these event types will not be invoked for calls
   3241  1.1.1.10  mrg           to the 'acc_set_device_type' and 'acc_set_device_num'
   3242  1.1.1.10  mrg           functions.  It's not clear if they should be.
   3243  1.1.1.10  mrg 
   3244  1.1.1.10  mrg 'acc_ev_enter_data_start', 'acc_ev_enter_data_end', 'acc_ev_exit_data_start', 'acc_ev_exit_data_end'
   3245  1.1.1.10  mrg 
   3246  1.1.1.10  mrg         * Callbacks for these event types will also be invoked for
   3247  1.1.1.10  mrg           OpenACC _host_data_ constructs.  It's not clear if they should
   3248  1.1.1.10  mrg           be.
   3249  1.1.1.10  mrg 
   3250  1.1.1.10  mrg         * Callbacks for these event types will also be invoked when
   3251  1.1.1.10  mrg           processing variable mappings specified in OpenACC _declare_
   3252  1.1.1.10  mrg           directives.  It's not clear if they should be.
   3253  1.1.1.10  mrg 
   3254  1.1.1.10  mrg    Callbacks for the following event types will be invoked, but dispatch
   3255  1.1.1.10  mrg and information provided therein has not yet been thoroughly reviewed:
   3256  1.1.1.10  mrg 
   3257  1.1.1.10  mrg    * 'acc_ev_alloc'
   3258  1.1.1.10  mrg    * 'acc_ev_free'
   3259  1.1.1.10  mrg    * 'acc_ev_update_start', 'acc_ev_update_end'
   3260  1.1.1.10  mrg    * 'acc_ev_enqueue_upload_start', 'acc_ev_enqueue_upload_end'
   3261  1.1.1.10  mrg    * 'acc_ev_enqueue_download_start', 'acc_ev_enqueue_download_end'
   3262  1.1.1.10  mrg 
   3263  1.1.1.10  mrg    During device initialization, and finalization, respectively,
   3264  1.1.1.10  mrg callbacks for the following event types will not yet be invoked:
   3265  1.1.1.10  mrg 
   3266  1.1.1.10  mrg    * 'acc_ev_alloc'
   3267  1.1.1.10  mrg    * 'acc_ev_free'
   3268  1.1.1.10  mrg 
   3269  1.1.1.10  mrg    Callbacks for the following event types have not yet been
   3270  1.1.1.10  mrg implemented, so currently won't be invoked:
   3271  1.1.1.10  mrg 
   3272  1.1.1.10  mrg    * 'acc_ev_device_shutdown_start', 'acc_ev_device_shutdown_end'
   3273  1.1.1.10  mrg    * 'acc_ev_runtime_shutdown'
   3274  1.1.1.10  mrg    * 'acc_ev_create', 'acc_ev_delete'
   3275  1.1.1.10  mrg    * 'acc_ev_wait_start', 'acc_ev_wait_end'
   3276  1.1.1.10  mrg 
   3277  1.1.1.10  mrg    For the following runtime library functions, not all expected
   3278  1.1.1.10  mrg callbacks will be invoked (mostly concerning implicit device
   3279  1.1.1.10  mrg initialization):
   3280  1.1.1.10  mrg 
   3281  1.1.1.10  mrg    * 'acc_get_num_devices'
   3282  1.1.1.10  mrg    * 'acc_set_device_type'
   3283  1.1.1.10  mrg    * 'acc_get_device_type'
   3284  1.1.1.10  mrg    * 'acc_set_device_num'
   3285  1.1.1.10  mrg    * 'acc_get_device_num'
   3286  1.1.1.10  mrg    * 'acc_init'
   3287  1.1.1.10  mrg    * 'acc_shutdown'
   3288  1.1.1.10  mrg 
   3289  1.1.1.10  mrg    Aside from implicit device initialization, for the following runtime
   3290  1.1.1.10  mrg library functions, no callbacks will be invoked for shared-memory
   3291  1.1.1.10  mrg offloading devices (it's not clear if they should be):
   3292  1.1.1.10  mrg 
   3293  1.1.1.10  mrg    * 'acc_malloc'
   3294  1.1.1.10  mrg    * 'acc_free'
   3295  1.1.1.10  mrg    * 'acc_copyin', 'acc_present_or_copyin', 'acc_copyin_async'
   3296  1.1.1.10  mrg    * 'acc_create', 'acc_present_or_create', 'acc_create_async'
   3297  1.1.1.10  mrg    * 'acc_copyout', 'acc_copyout_async', 'acc_copyout_finalize',
   3298  1.1.1.10  mrg      'acc_copyout_finalize_async'
   3299  1.1.1.10  mrg    * 'acc_delete', 'acc_delete_async', 'acc_delete_finalize',
   3300  1.1.1.10  mrg      'acc_delete_finalize_async'
   3301  1.1.1.10  mrg    * 'acc_update_device', 'acc_update_device_async'
   3302  1.1.1.10  mrg    * 'acc_update_self', 'acc_update_self_async'
   3303  1.1.1.10  mrg    * 'acc_map_data', 'acc_unmap_data'
   3304  1.1.1.10  mrg    * 'acc_memcpy_to_device', 'acc_memcpy_to_device_async'
   3305  1.1.1.10  mrg    * 'acc_memcpy_from_device', 'acc_memcpy_from_device_async'
   3306  1.1.1.10  mrg 
   3307  1.1.1.10  mrg 
   3308  1.1.1.10  mrg File: libgomp.info,  Node: The libgomp ABI,  Next: Reporting Bugs,  Prev: OpenACC Profiling Interface,  Up: Top
   3309  1.1.1.10  mrg 
   3310  1.1.1.10  mrg 10 The libgomp ABI
   3311  1.1.1.10  mrg ******************
   3312       1.1  mrg 
   3313   1.1.1.8  mrg The following sections present notes on the external ABI as presented by
   3314   1.1.1.8  mrg libgomp.  Only maintainers should need them.
   3315       1.1  mrg 
   3316       1.1  mrg * Menu:
   3317       1.1  mrg 
   3318       1.1  mrg * Implementing MASTER construct::
   3319       1.1  mrg * Implementing CRITICAL construct::
   3320       1.1  mrg * Implementing ATOMIC construct::
   3321       1.1  mrg * Implementing FLUSH construct::
   3322       1.1  mrg * Implementing BARRIER construct::
   3323       1.1  mrg * Implementing THREADPRIVATE construct::
   3324       1.1  mrg * Implementing PRIVATE clause::
   3325       1.1  mrg * Implementing FIRSTPRIVATE LASTPRIVATE COPYIN and COPYPRIVATE clauses::
   3326       1.1  mrg * Implementing REDUCTION clause::
   3327       1.1  mrg * Implementing PARALLEL construct::
   3328       1.1  mrg * Implementing FOR construct::
   3329       1.1  mrg * Implementing ORDERED construct::
   3330       1.1  mrg * Implementing SECTIONS construct::
   3331       1.1  mrg * Implementing SINGLE construct::
   3332   1.1.1.5  mrg * Implementing OpenACC's PARALLEL construct::
   3333       1.1  mrg 
   3334       1.1  mrg 
   3335       1.1  mrg File: libgomp.info,  Node: Implementing MASTER construct,  Next: Implementing CRITICAL construct,  Up: The libgomp ABI
   3336       1.1  mrg 
   3337  1.1.1.10  mrg 10.1 Implementing MASTER construct
   3338  1.1.1.10  mrg ==================================
   3339       1.1  mrg 
   3340       1.1  mrg      if (omp_get_thread_num () == 0)
   3341       1.1  mrg        block
   3342       1.1  mrg 
   3343       1.1  mrg    Alternately, we generate two copies of the parallel subfunction and
   3344   1.1.1.2  mrg only include this in the version run by the master thread.  Surely this
   3345   1.1.1.2  mrg is not worthwhile though...
   3346       1.1  mrg 
   3347       1.1  mrg 
   3348       1.1  mrg File: libgomp.info,  Node: Implementing CRITICAL construct,  Next: Implementing ATOMIC construct,  Prev: Implementing MASTER construct,  Up: The libgomp ABI
   3349       1.1  mrg 
   3350  1.1.1.10  mrg 10.2 Implementing CRITICAL construct
   3351  1.1.1.10  mrg ====================================
   3352       1.1  mrg 
   3353       1.1  mrg Without a specified name,
   3354       1.1  mrg 
   3355       1.1  mrg        void GOMP_critical_start (void);
   3356       1.1  mrg        void GOMP_critical_end (void);
   3357       1.1  mrg 
   3358       1.1  mrg    so that we don't get COPY relocations from libgomp to the main
   3359       1.1  mrg application.
   3360       1.1  mrg 
   3361       1.1  mrg    With a specified name, use omp_set_lock and omp_unset_lock with name
   3362       1.1  mrg being transformed into a variable declared like
   3363       1.1  mrg 
   3364       1.1  mrg        omp_lock_t gomp_critical_user_<name> __attribute__((common))
   3365       1.1  mrg 
   3366       1.1  mrg    Ideally the ABI would specify that all zero is a valid unlocked
   3367   1.1.1.2  mrg state, and so we wouldn't need to initialize this at startup.
   3368       1.1  mrg 
   3369       1.1  mrg 
   3370       1.1  mrg File: libgomp.info,  Node: Implementing ATOMIC construct,  Next: Implementing FLUSH construct,  Prev: Implementing CRITICAL construct,  Up: The libgomp ABI
   3371       1.1  mrg 
   3372  1.1.1.10  mrg 10.3 Implementing ATOMIC construct
   3373  1.1.1.10  mrg ==================================
   3374       1.1  mrg 
   3375   1.1.1.8  mrg The target should implement the '__sync' builtins.
   3376       1.1  mrg 
   3377       1.1  mrg    Failing that we could add
   3378       1.1  mrg 
   3379       1.1  mrg        void GOMP_atomic_enter (void)
   3380       1.1  mrg        void GOMP_atomic_exit (void)
   3381       1.1  mrg 
   3382       1.1  mrg    which reuses the regular lock code, but with yet another lock object
   3383       1.1  mrg private to the library.
   3384       1.1  mrg 
   3385       1.1  mrg 
   3386       1.1  mrg File: libgomp.info,  Node: Implementing FLUSH construct,  Next: Implementing BARRIER construct,  Prev: Implementing ATOMIC construct,  Up: The libgomp ABI
   3387       1.1  mrg 
   3388  1.1.1.10  mrg 10.4 Implementing FLUSH construct
   3389  1.1.1.10  mrg =================================
   3390       1.1  mrg 
   3391   1.1.1.8  mrg Expands to the '__sync_synchronize' builtin.
   3392       1.1  mrg 
   3393       1.1  mrg 
   3394       1.1  mrg File: libgomp.info,  Node: Implementing BARRIER construct,  Next: Implementing THREADPRIVATE construct,  Prev: Implementing FLUSH construct,  Up: The libgomp ABI
   3395       1.1  mrg 
   3396  1.1.1.10  mrg 10.5 Implementing BARRIER construct
   3397  1.1.1.10  mrg ===================================
   3398       1.1  mrg 
   3399       1.1  mrg        void GOMP_barrier (void)
   3400       1.1  mrg 
   3401       1.1  mrg 
   3402       1.1  mrg File: libgomp.info,  Node: Implementing THREADPRIVATE construct,  Next: Implementing PRIVATE clause,  Prev: Implementing BARRIER construct,  Up: The libgomp ABI
   3403       1.1  mrg 
   3404  1.1.1.10  mrg 10.6 Implementing THREADPRIVATE construct
   3405  1.1.1.10  mrg =========================================
   3406       1.1  mrg 
   3407   1.1.1.8  mrg In _most_ cases we can map this directly to '__thread'.  Except that OMP
   3408   1.1.1.8  mrg allows constructors for C++ objects.  We can either refuse to support
   3409   1.1.1.8  mrg this (how often is it used?)  or we can implement something akin to
   3410   1.1.1.8  mrg .ctors.
   3411       1.1  mrg 
   3412       1.1  mrg    Even more ideally, this ctor feature is handled by extensions to the
   3413       1.1  mrg main pthreads library.  Failing that, we can have a set of entry points
   3414       1.1  mrg to register ctor functions to be called.
   3415       1.1  mrg 
   3416       1.1  mrg 
   3417       1.1  mrg File: libgomp.info,  Node: Implementing PRIVATE clause,  Next: Implementing FIRSTPRIVATE LASTPRIVATE COPYIN and COPYPRIVATE clauses,  Prev: Implementing THREADPRIVATE construct,  Up: The libgomp ABI
   3418       1.1  mrg 
   3419  1.1.1.10  mrg 10.7 Implementing PRIVATE clause
   3420  1.1.1.10  mrg ================================
   3421       1.1  mrg 
   3422       1.1  mrg In association with a PARALLEL, or within the lexical extent of a
   3423       1.1  mrg PARALLEL block, the variable becomes a local variable in the parallel
   3424       1.1  mrg subfunction.
   3425       1.1  mrg 
   3426       1.1  mrg    In association with FOR or SECTIONS blocks, create a new automatic
   3427       1.1  mrg variable within the current function.  This preserves the semantic of
   3428       1.1  mrg new variable creation.
   3429       1.1  mrg 
   3430       1.1  mrg 
   3431       1.1  mrg File: libgomp.info,  Node: Implementing FIRSTPRIVATE LASTPRIVATE COPYIN and COPYPRIVATE clauses,  Next: Implementing REDUCTION clause,  Prev: Implementing PRIVATE clause,  Up: The libgomp ABI
   3432       1.1  mrg 
   3433  1.1.1.10  mrg 10.8 Implementing FIRSTPRIVATE LASTPRIVATE COPYIN and COPYPRIVATE clauses
   3434  1.1.1.10  mrg =========================================================================
   3435       1.1  mrg 
   3436   1.1.1.2  mrg This seems simple enough for PARALLEL blocks.  Create a private struct
   3437   1.1.1.2  mrg for communicating between the parent and subfunction.  In the parent,
   3438   1.1.1.2  mrg copy in values for scalar and "small" structs; copy in addresses for
   3439   1.1.1.2  mrg others TREE_ADDRESSABLE types.  In the subfunction, copy the value into
   3440   1.1.1.2  mrg the local variable.
   3441       1.1  mrg 
   3442   1.1.1.8  mrg    It is not clear what to do with bare FOR or SECTION blocks.  The only
   3443   1.1.1.8  mrg thing I can figure is that we do something like:
   3444       1.1  mrg 
   3445       1.1  mrg      #pragma omp for firstprivate(x) lastprivate(y)
   3446       1.1  mrg      for (int i = 0; i < n; ++i)
   3447       1.1  mrg        body;
   3448       1.1  mrg 
   3449       1.1  mrg    which becomes
   3450       1.1  mrg 
   3451       1.1  mrg      {
   3452       1.1  mrg        int x = x, y;
   3453       1.1  mrg 
   3454       1.1  mrg        // for stuff
   3455       1.1  mrg 
   3456       1.1  mrg        if (i == n)
   3457       1.1  mrg          y = y;
   3458       1.1  mrg      }
   3459       1.1  mrg 
   3460       1.1  mrg    where the "x=x" and "y=y" assignments actually have different uids
   3461   1.1.1.8  mrg for the two variables, i.e.  not something you could write directly in
   3462   1.1.1.8  mrg C. Presumably this only makes sense if the "outer" x and y are global
   3463       1.1  mrg variables.
   3464       1.1  mrg 
   3465       1.1  mrg    COPYPRIVATE would work the same way, except the structure broadcast
   3466       1.1  mrg would have to happen via SINGLE machinery instead.
   3467       1.1  mrg 
   3468       1.1  mrg 
   3469       1.1  mrg File: libgomp.info,  Node: Implementing REDUCTION clause,  Next: Implementing PARALLEL construct,  Prev: Implementing FIRSTPRIVATE LASTPRIVATE COPYIN and COPYPRIVATE clauses,  Up: The libgomp ABI
   3470       1.1  mrg 
   3471  1.1.1.10  mrg 10.9 Implementing REDUCTION clause
   3472  1.1.1.10  mrg ==================================
   3473       1.1  mrg 
   3474       1.1  mrg The private struct mentioned in the previous section should have a
   3475   1.1.1.8  mrg pointer to an array of the type of the variable, indexed by the thread's
   3476   1.1.1.8  mrg TEAM_ID.  The thread stores its final value into the array, and after
   3477   1.1.1.8  mrg the barrier, the master thread iterates over the array to collect the
   3478   1.1.1.8  mrg values.
   3479       1.1  mrg 
   3480       1.1  mrg 
   3481       1.1  mrg File: libgomp.info,  Node: Implementing PARALLEL construct,  Next: Implementing FOR construct,  Prev: Implementing REDUCTION clause,  Up: The libgomp ABI
   3482       1.1  mrg 
   3483  1.1.1.10  mrg 10.10 Implementing PARALLEL construct
   3484  1.1.1.10  mrg =====================================
   3485       1.1  mrg 
   3486       1.1  mrg        #pragma omp parallel
   3487       1.1  mrg        {
   3488       1.1  mrg          body;
   3489       1.1  mrg        }
   3490       1.1  mrg 
   3491       1.1  mrg    becomes
   3492       1.1  mrg 
   3493       1.1  mrg        void subfunction (void *data)
   3494       1.1  mrg        {
   3495       1.1  mrg          use data;
   3496       1.1  mrg          body;
   3497       1.1  mrg        }
   3498       1.1  mrg 
   3499       1.1  mrg        setup data;
   3500       1.1  mrg        GOMP_parallel_start (subfunction, &data, num_threads);
   3501       1.1  mrg        subfunction (&data);
   3502       1.1  mrg        GOMP_parallel_end ();
   3503       1.1  mrg 
   3504       1.1  mrg        void GOMP_parallel_start (void (*fn)(void *), void *data, unsigned num_threads)
   3505       1.1  mrg 
   3506       1.1  mrg    The FN argument is the subfunction to be run in parallel.
   3507       1.1  mrg 
   3508       1.1  mrg    The DATA argument is a pointer to a structure used to communicate
   3509       1.1  mrg data in and out of the subfunction, as discussed above with respect to
   3510       1.1  mrg FIRSTPRIVATE et al.
   3511       1.1  mrg 
   3512       1.1  mrg    The NUM_THREADS argument is 1 if an IF clause is present and false,
   3513       1.1  mrg or the value of the NUM_THREADS clause, if present, or 0.
   3514       1.1  mrg 
   3515   1.1.1.8  mrg    The function needs to create the appropriate number of threads and/or
   3516   1.1.1.8  mrg launch them from the dock.  It needs to create the team structure and
   3517   1.1.1.8  mrg assign team ids.
   3518       1.1  mrg 
   3519       1.1  mrg        void GOMP_parallel_end (void)
   3520       1.1  mrg 
   3521       1.1  mrg    Tears down the team and returns us to the previous
   3522   1.1.1.8  mrg 'omp_in_parallel()' state.
   3523       1.1  mrg 
   3524       1.1  mrg 
   3525       1.1  mrg File: libgomp.info,  Node: Implementing FOR construct,  Next: Implementing ORDERED construct,  Prev: Implementing PARALLEL construct,  Up: The libgomp ABI
   3526       1.1  mrg 
   3527  1.1.1.10  mrg 10.11 Implementing FOR construct
   3528  1.1.1.10  mrg ================================
   3529       1.1  mrg 
   3530       1.1  mrg        #pragma omp parallel for
   3531       1.1  mrg        for (i = lb; i <= ub; i++)
   3532       1.1  mrg          body;
   3533       1.1  mrg 
   3534       1.1  mrg    becomes
   3535       1.1  mrg 
   3536       1.1  mrg        void subfunction (void *data)
   3537       1.1  mrg        {
   3538       1.1  mrg          long _s0, _e0;
   3539       1.1  mrg          while (GOMP_loop_static_next (&_s0, &_e0))
   3540       1.1  mrg          {
   3541       1.1  mrg            long _e1 = _e0, i;
   3542       1.1  mrg            for (i = _s0; i < _e1; i++)
   3543       1.1  mrg              body;
   3544       1.1  mrg          }
   3545       1.1  mrg          GOMP_loop_end_nowait ();
   3546       1.1  mrg        }
   3547       1.1  mrg 
   3548       1.1  mrg        GOMP_parallel_loop_static (subfunction, NULL, 0, lb, ub+1, 1, 0);
   3549       1.1  mrg        subfunction (NULL);
   3550       1.1  mrg        GOMP_parallel_end ();
   3551       1.1  mrg 
   3552       1.1  mrg        #pragma omp for schedule(runtime)
   3553       1.1  mrg        for (i = 0; i < n; i++)
   3554       1.1  mrg          body;
   3555       1.1  mrg 
   3556       1.1  mrg    becomes
   3557       1.1  mrg 
   3558       1.1  mrg        {
   3559       1.1  mrg          long i, _s0, _e0;
   3560       1.1  mrg          if (GOMP_loop_runtime_start (0, n, 1, &_s0, &_e0))
   3561       1.1  mrg            do {
   3562       1.1  mrg              long _e1 = _e0;
   3563       1.1  mrg              for (i = _s0, i < _e0; i++)
   3564       1.1  mrg                body;
   3565       1.1  mrg            } while (GOMP_loop_runtime_next (&_s0, _&e0));
   3566       1.1  mrg          GOMP_loop_end ();
   3567       1.1  mrg        }
   3568       1.1  mrg 
   3569   1.1.1.2  mrg    Note that while it looks like there is trickiness to propagating a
   3570       1.1  mrg non-constant STEP, there isn't really.  We're explicitly allowed to
   3571       1.1  mrg evaluate it as many times as we want, and any variables involved should
   3572       1.1  mrg automatically be handled as PRIVATE or SHARED like any other variables.
   3573       1.1  mrg So the expression should remain evaluable in the subfunction.  We can
   3574   1.1.1.8  mrg also pull it into a local variable if we like, but since its supposed to
   3575   1.1.1.8  mrg remain unchanged, we can also not if we like.
   3576       1.1  mrg 
   3577   1.1.1.8  mrg    If we have SCHEDULE(STATIC), and no ORDERED, then we ought to be able
   3578   1.1.1.8  mrg to get away with no work-sharing context at all, since we can simply
   3579   1.1.1.8  mrg perform the arithmetic directly in each thread to divide up the
   3580   1.1.1.8  mrg iterations.  Which would mean that we wouldn't need to call any of these
   3581   1.1.1.8  mrg routines.
   3582       1.1  mrg 
   3583       1.1  mrg    There are separate routines for handling loops with an ORDERED
   3584       1.1  mrg clause.  Bookkeeping for that is non-trivial...
   3585       1.1  mrg 
   3586       1.1  mrg 
   3587       1.1  mrg File: libgomp.info,  Node: Implementing ORDERED construct,  Next: Implementing SECTIONS construct,  Prev: Implementing FOR construct,  Up: The libgomp ABI
   3588       1.1  mrg 
   3589  1.1.1.10  mrg 10.12 Implementing ORDERED construct
   3590  1.1.1.10  mrg ====================================
   3591       1.1  mrg 
   3592       1.1  mrg        void GOMP_ordered_start (void)
   3593       1.1  mrg        void GOMP_ordered_end (void)
   3594       1.1  mrg 
   3595       1.1  mrg 
   3596       1.1  mrg File: libgomp.info,  Node: Implementing SECTIONS construct,  Next: Implementing SINGLE construct,  Prev: Implementing ORDERED construct,  Up: The libgomp ABI
   3597       1.1  mrg 
   3598  1.1.1.10  mrg 10.13 Implementing SECTIONS construct
   3599  1.1.1.10  mrg =====================================
   3600       1.1  mrg 
   3601       1.1  mrg A block as
   3602       1.1  mrg 
   3603       1.1  mrg        #pragma omp sections
   3604       1.1  mrg        {
   3605       1.1  mrg          #pragma omp section
   3606       1.1  mrg          stmt1;
   3607       1.1  mrg          #pragma omp section
   3608       1.1  mrg          stmt2;
   3609       1.1  mrg          #pragma omp section
   3610       1.1  mrg          stmt3;
   3611       1.1  mrg        }
   3612       1.1  mrg 
   3613       1.1  mrg    becomes
   3614       1.1  mrg 
   3615       1.1  mrg        for (i = GOMP_sections_start (3); i != 0; i = GOMP_sections_next ())
   3616       1.1  mrg          switch (i)
   3617       1.1  mrg            {
   3618       1.1  mrg            case 1:
   3619       1.1  mrg              stmt1;
   3620       1.1  mrg              break;
   3621       1.1  mrg            case 2:
   3622       1.1  mrg              stmt2;
   3623       1.1  mrg              break;
   3624       1.1  mrg            case 3:
   3625       1.1  mrg              stmt3;
   3626       1.1  mrg              break;
   3627       1.1  mrg            }
   3628       1.1  mrg        GOMP_barrier ();
   3629       1.1  mrg 
   3630       1.1  mrg 
   3631   1.1.1.5  mrg File: libgomp.info,  Node: Implementing SINGLE construct,  Next: Implementing OpenACC's PARALLEL construct,  Prev: Implementing SECTIONS construct,  Up: The libgomp ABI
   3632       1.1  mrg 
   3633  1.1.1.10  mrg 10.14 Implementing SINGLE construct
   3634  1.1.1.10  mrg ===================================
   3635       1.1  mrg 
   3636       1.1  mrg A block like
   3637       1.1  mrg 
   3638       1.1  mrg        #pragma omp single
   3639       1.1  mrg        {
   3640       1.1  mrg          body;
   3641       1.1  mrg        }
   3642       1.1  mrg 
   3643       1.1  mrg    becomes
   3644       1.1  mrg 
   3645       1.1  mrg        if (GOMP_single_start ())
   3646       1.1  mrg          body;
   3647       1.1  mrg        GOMP_barrier ();
   3648       1.1  mrg 
   3649       1.1  mrg    while
   3650       1.1  mrg 
   3651       1.1  mrg        #pragma omp single copyprivate(x)
   3652       1.1  mrg          body;
   3653       1.1  mrg 
   3654       1.1  mrg    becomes
   3655       1.1  mrg 
   3656       1.1  mrg        datap = GOMP_single_copy_start ();
   3657       1.1  mrg        if (datap == NULL)
   3658       1.1  mrg          {
   3659       1.1  mrg            body;
   3660       1.1  mrg            data.x = x;
   3661       1.1  mrg            GOMP_single_copy_end (&data);
   3662       1.1  mrg          }
   3663       1.1  mrg        else
   3664       1.1  mrg          x = datap->x;
   3665       1.1  mrg        GOMP_barrier ();
   3666       1.1  mrg 
   3667       1.1  mrg 
   3668   1.1.1.5  mrg File: libgomp.info,  Node: Implementing OpenACC's PARALLEL construct,  Prev: Implementing SINGLE construct,  Up: The libgomp ABI
   3669   1.1.1.5  mrg 
   3670  1.1.1.10  mrg 10.15 Implementing OpenACC's PARALLEL construct
   3671  1.1.1.10  mrg ===============================================
   3672   1.1.1.5  mrg 
   3673   1.1.1.5  mrg        void GOACC_parallel ()
   3674   1.1.1.5  mrg 
   3675   1.1.1.5  mrg 
   3676       1.1  mrg File: libgomp.info,  Node: Reporting Bugs,  Next: Copying,  Prev: The libgomp ABI,  Up: Top
   3677       1.1  mrg 
   3678  1.1.1.10  mrg 11 Reporting Bugs
   3679   1.1.1.5  mrg *****************
   3680       1.1  mrg 
   3681   1.1.1.3  mrg Bugs in the GNU Offloading and Multi Processing Runtime Library should
   3682  1.1.1.10  mrg be reported via Bugzilla (https://gcc.gnu.org/bugzilla/).  Please add
   3683   1.1.1.8  mrg "openacc", or "openmp", or both to the keywords field in the bug report,
   3684   1.1.1.8  mrg as appropriate.
   3685       1.1  mrg 
   3686       1.1  mrg 
   3687       1.1  mrg File: libgomp.info,  Node: Copying,  Next: GNU Free Documentation License,  Prev: Reporting Bugs,  Up: Top
   3688       1.1  mrg 
   3689   1.1.1.2  mrg GNU General Public License
   3690       1.1  mrg **************************
   3691       1.1  mrg 
   3692   1.1.1.2  mrg                         Version 3, 29 June 2007
   3693       1.1  mrg 
   3694   1.1.1.8  mrg      Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
   3695       1.1  mrg 
   3696   1.1.1.2  mrg      Everyone is permitted to copy and distribute verbatim copies of this
   3697   1.1.1.2  mrg      license document, but changing it is not allowed.
   3698       1.1  mrg 
   3699       1.1  mrg Preamble
   3700       1.1  mrg ========
   3701       1.1  mrg 
   3702   1.1.1.2  mrg The GNU General Public License is a free, copyleft license for software
   3703   1.1.1.2  mrg and other kinds of works.
   3704   1.1.1.2  mrg 
   3705   1.1.1.2  mrg    The licenses for most software and other practical works are designed
   3706   1.1.1.2  mrg to take away your freedom to share and change the works.  By contrast,
   3707   1.1.1.2  mrg the GNU General Public License is intended to guarantee your freedom to
   3708   1.1.1.2  mrg share and change all versions of a program-to make sure it remains free
   3709   1.1.1.2  mrg software for all its users.  We, the Free Software Foundation, use the
   3710   1.1.1.2  mrg GNU General Public License for most of our software; it applies also to
   3711   1.1.1.2  mrg any other work released this way by its authors.  You can apply it to
   3712       1.1  mrg your programs, too.
   3713       1.1  mrg 
   3714       1.1  mrg    When we speak of free software, we are referring to freedom, not
   3715       1.1  mrg price.  Our General Public Licenses are designed to make sure that you
   3716       1.1  mrg have the freedom to distribute copies of free software (and charge for
   3717   1.1.1.2  mrg them if you wish), that you receive source code or can get it if you
   3718   1.1.1.2  mrg want it, that you can change the software or use pieces of it in new
   3719   1.1.1.2  mrg free programs, and that you know you can do these things.
   3720   1.1.1.2  mrg 
   3721   1.1.1.2  mrg    To protect your rights, we need to prevent others from denying you
   3722   1.1.1.8  mrg these rights or asking you to surrender the rights.  Therefore, you have
   3723   1.1.1.8  mrg certain responsibilities if you distribute copies of the software, or if
   3724   1.1.1.8  mrg you modify it: responsibilities to respect the freedom of others.
   3725       1.1  mrg 
   3726       1.1  mrg    For example, if you distribute copies of such a program, whether
   3727   1.1.1.2  mrg gratis or for a fee, you must pass on to the recipients the same
   3728   1.1.1.2  mrg freedoms that you received.  You must make sure that they, too, receive
   3729   1.1.1.2  mrg or can get the source code.  And you must show them these terms so they
   3730   1.1.1.2  mrg know their rights.
   3731   1.1.1.2  mrg 
   3732   1.1.1.2  mrg    Developers that use the GNU GPL protect your rights with two steps:
   3733   1.1.1.2  mrg (1) assert copyright on the software, and (2) offer you this License
   3734   1.1.1.2  mrg giving you legal permission to copy, distribute and/or modify it.
   3735   1.1.1.2  mrg 
   3736   1.1.1.2  mrg    For the developers' and authors' protection, the GPL clearly explains
   3737   1.1.1.2  mrg that there is no warranty for this free software.  For both users' and
   3738   1.1.1.2  mrg authors' sake, the GPL requires that modified versions be marked as
   3739   1.1.1.2  mrg changed, so that their problems will not be attributed erroneously to
   3740   1.1.1.2  mrg authors of previous versions.
   3741   1.1.1.2  mrg 
   3742   1.1.1.2  mrg    Some devices are designed to deny users access to install or run
   3743   1.1.1.8  mrg modified versions of the software inside them, although the manufacturer
   3744   1.1.1.8  mrg can do so.  This is fundamentally incompatible with the aim of
   3745   1.1.1.8  mrg protecting users' freedom to change the software.  The systematic
   3746   1.1.1.8  mrg pattern of such abuse occurs in the area of products for individuals to
   3747   1.1.1.8  mrg use, which is precisely where it is most unacceptable.  Therefore, we
   3748   1.1.1.8  mrg have designed this version of the GPL to prohibit the practice for those
   3749   1.1.1.8  mrg products.  If such problems arise substantially in other domains, we
   3750   1.1.1.8  mrg stand ready to extend this provision to those domains in future versions
   3751   1.1.1.8  mrg of the GPL, as needed to protect the freedom of users.
   3752   1.1.1.2  mrg 
   3753   1.1.1.2  mrg    Finally, every program is threatened constantly by software patents.
   3754   1.1.1.2  mrg States should not allow patents to restrict development and use of
   3755   1.1.1.2  mrg software on general-purpose computers, but in those that do, we wish to
   3756   1.1.1.2  mrg avoid the special danger that patents applied to a free program could
   3757   1.1.1.2  mrg make it effectively proprietary.  To prevent this, the GPL assures that
   3758   1.1.1.2  mrg patents cannot be used to render the program non-free.
   3759       1.1  mrg 
   3760       1.1  mrg    The precise terms and conditions for copying, distribution and
   3761       1.1  mrg modification follow.
   3762       1.1  mrg 
   3763   1.1.1.2  mrg TERMS AND CONDITIONS
   3764   1.1.1.2  mrg ====================
   3765       1.1  mrg 
   3766   1.1.1.2  mrg   0. Definitions.
   3767   1.1.1.2  mrg 
   3768   1.1.1.2  mrg      "This License" refers to version 3 of the GNU General Public
   3769   1.1.1.2  mrg      License.
   3770   1.1.1.2  mrg 
   3771   1.1.1.2  mrg      "Copyright" also means copyright-like laws that apply to other
   3772   1.1.1.2  mrg      kinds of works, such as semiconductor masks.
   3773   1.1.1.2  mrg 
   3774   1.1.1.2  mrg      "The Program" refers to any copyrightable work licensed under this
   3775   1.1.1.2  mrg      License.  Each licensee is addressed as "you".  "Licensees" and
   3776   1.1.1.2  mrg      "recipients" may be individuals or organizations.
   3777   1.1.1.2  mrg 
   3778   1.1.1.2  mrg      To "modify" a work means to copy from or adapt all or part of the
   3779   1.1.1.2  mrg      work in a fashion requiring copyright permission, other than the
   3780   1.1.1.2  mrg      making of an exact copy.  The resulting work is called a "modified
   3781   1.1.1.2  mrg      version" of the earlier work or a work "based on" the earlier work.
   3782   1.1.1.2  mrg 
   3783   1.1.1.2  mrg      A "covered work" means either the unmodified Program or a work
   3784   1.1.1.2  mrg      based on the Program.
   3785   1.1.1.2  mrg 
   3786   1.1.1.2  mrg      To "propagate" a work means to do anything with it that, without
   3787   1.1.1.2  mrg      permission, would make you directly or secondarily liable for
   3788   1.1.1.8  mrg      infringement under applicable copyright law, except executing it on
   3789   1.1.1.8  mrg      a computer or modifying a private copy.  Propagation includes
   3790   1.1.1.2  mrg      copying, distribution (with or without modification), making
   3791   1.1.1.2  mrg      available to the public, and in some countries other activities as
   3792   1.1.1.2  mrg      well.
   3793   1.1.1.2  mrg 
   3794   1.1.1.2  mrg      To "convey" a work means any kind of propagation that enables other
   3795   1.1.1.2  mrg      parties to make or receive copies.  Mere interaction with a user
   3796   1.1.1.2  mrg      through a computer network, with no transfer of a copy, is not
   3797   1.1.1.2  mrg      conveying.
   3798   1.1.1.2  mrg 
   3799   1.1.1.2  mrg      An interactive user interface displays "Appropriate Legal Notices"
   3800   1.1.1.2  mrg      to the extent that it includes a convenient and prominently visible
   3801   1.1.1.2  mrg      feature that (1) displays an appropriate copyright notice, and (2)
   3802   1.1.1.2  mrg      tells the user that there is no warranty for the work (except to
   3803   1.1.1.8  mrg      the extent that warranties are provided), that licensees may convey
   3804   1.1.1.8  mrg      the work under this License, and how to view a copy of this
   3805   1.1.1.2  mrg      License.  If the interface presents a list of user commands or
   3806   1.1.1.2  mrg      options, such as a menu, a prominent item in the list meets this
   3807   1.1.1.2  mrg      criterion.
   3808   1.1.1.2  mrg 
   3809   1.1.1.2  mrg   1. Source Code.
   3810   1.1.1.2  mrg 
   3811   1.1.1.2  mrg      The "source code" for a work means the preferred form of the work
   3812   1.1.1.8  mrg      for making modifications to it.  "Object code" means any non-source
   3813   1.1.1.8  mrg      form of a work.
   3814   1.1.1.2  mrg 
   3815   1.1.1.2  mrg      A "Standard Interface" means an interface that either is an
   3816   1.1.1.2  mrg      official standard defined by a recognized standards body, or, in
   3817   1.1.1.2  mrg      the case of interfaces specified for a particular programming
   3818   1.1.1.2  mrg      language, one that is widely used among developers working in that
   3819   1.1.1.2  mrg      language.
   3820   1.1.1.2  mrg 
   3821   1.1.1.2  mrg      The "System Libraries" of an executable work include anything,
   3822   1.1.1.2  mrg      other than the work as a whole, that (a) is included in the normal
   3823   1.1.1.2  mrg      form of packaging a Major Component, but which is not part of that
   3824   1.1.1.8  mrg      Major Component, and (b) serves only to enable use of the work with
   3825   1.1.1.8  mrg      that Major Component, or to implement a Standard Interface for
   3826   1.1.1.8  mrg      which an implementation is available to the public in source code
   3827   1.1.1.8  mrg      form.  A "Major Component", in this context, means a major
   3828   1.1.1.2  mrg      essential component (kernel, window system, and so on) of the
   3829   1.1.1.2  mrg      specific operating system (if any) on which the executable work
   3830   1.1.1.2  mrg      runs, or a compiler used to produce the work, or an object code
   3831   1.1.1.2  mrg      interpreter used to run it.
   3832   1.1.1.2  mrg 
   3833   1.1.1.2  mrg      The "Corresponding Source" for a work in object code form means all
   3834   1.1.1.2  mrg      the source code needed to generate, install, and (for an executable
   3835   1.1.1.8  mrg      work) run the object code and to modify the work, including scripts
   3836   1.1.1.8  mrg      to control those activities.  However, it does not include the
   3837   1.1.1.8  mrg      work's System Libraries, or general-purpose tools or generally
   3838   1.1.1.2  mrg      available free programs which are used unmodified in performing
   3839   1.1.1.2  mrg      those activities but which are not part of the work.  For example,
   3840   1.1.1.8  mrg      Corresponding Source includes interface definition files associated
   3841   1.1.1.8  mrg      with source files for the work, and the source code for shared
   3842   1.1.1.8  mrg      libraries and dynamically linked subprograms that the work is
   3843   1.1.1.8  mrg      specifically designed to require, such as by intimate data
   3844   1.1.1.2  mrg      communication or control flow between those subprograms and other
   3845   1.1.1.2  mrg      parts of the work.
   3846   1.1.1.2  mrg 
   3847   1.1.1.2  mrg      The Corresponding Source need not include anything that users can
   3848   1.1.1.2  mrg      regenerate automatically from other parts of the Corresponding
   3849   1.1.1.2  mrg      Source.
   3850   1.1.1.2  mrg 
   3851   1.1.1.2  mrg      The Corresponding Source for a work in source code form is that
   3852   1.1.1.2  mrg      same work.
   3853   1.1.1.2  mrg 
   3854   1.1.1.2  mrg   2. Basic Permissions.
   3855   1.1.1.2  mrg 
   3856   1.1.1.2  mrg      All rights granted under this License are granted for the term of
   3857   1.1.1.2  mrg      copyright on the Program, and are irrevocable provided the stated
   3858   1.1.1.2  mrg      conditions are met.  This License explicitly affirms your unlimited
   3859   1.1.1.2  mrg      permission to run the unmodified Program.  The output from running
   3860   1.1.1.8  mrg      a covered work is covered by this License only if the output, given
   3861   1.1.1.8  mrg      its content, constitutes a covered work.  This License acknowledges
   3862   1.1.1.8  mrg      your rights of fair use or other equivalent, as provided by
   3863   1.1.1.8  mrg      copyright law.
   3864   1.1.1.2  mrg 
   3865   1.1.1.2  mrg      You may make, run and propagate covered works that you do not
   3866   1.1.1.2  mrg      convey, without conditions so long as your license otherwise
   3867   1.1.1.2  mrg      remains in force.  You may convey covered works to others for the
   3868   1.1.1.8  mrg      sole purpose of having them make modifications exclusively for you,
   3869   1.1.1.8  mrg      or provide you with facilities for running those works, provided
   3870   1.1.1.8  mrg      that you comply with the terms of this License in conveying all
   3871   1.1.1.8  mrg      material for which you do not control copyright.  Those thus making
   3872   1.1.1.8  mrg      or running the covered works for you must do so exclusively on your
   3873   1.1.1.8  mrg      behalf, under your direction and control, on terms that prohibit
   3874   1.1.1.8  mrg      them from making any copies of your copyrighted material outside
   3875   1.1.1.8  mrg      their relationship with you.
   3876   1.1.1.2  mrg 
   3877   1.1.1.2  mrg      Conveying under any other circumstances is permitted solely under
   3878   1.1.1.2  mrg      the conditions stated below.  Sublicensing is not allowed; section
   3879   1.1.1.2  mrg      10 makes it unnecessary.
   3880   1.1.1.2  mrg 
   3881   1.1.1.2  mrg   3. Protecting Users' Legal Rights From Anti-Circumvention Law.
   3882   1.1.1.2  mrg 
   3883   1.1.1.2  mrg      No covered work shall be deemed part of an effective technological
   3884   1.1.1.2  mrg      measure under any applicable law fulfilling obligations under
   3885   1.1.1.2  mrg      article 11 of the WIPO copyright treaty adopted on 20 December
   3886   1.1.1.2  mrg      1996, or similar laws prohibiting or restricting circumvention of
   3887   1.1.1.2  mrg      such measures.
   3888   1.1.1.2  mrg 
   3889   1.1.1.2  mrg      When you convey a covered work, you waive any legal power to forbid
   3890   1.1.1.2  mrg      circumvention of technological measures to the extent such
   3891   1.1.1.2  mrg      circumvention is effected by exercising rights under this License
   3892   1.1.1.8  mrg      with respect to the covered work, and you disclaim any intention to
   3893   1.1.1.8  mrg      limit operation or modification of the work as a means of
   3894   1.1.1.2  mrg      enforcing, against the work's users, your or third parties' legal
   3895   1.1.1.2  mrg      rights to forbid circumvention of technological measures.
   3896   1.1.1.2  mrg 
   3897   1.1.1.2  mrg   4. Conveying Verbatim Copies.
   3898   1.1.1.2  mrg 
   3899   1.1.1.2  mrg      You may convey verbatim copies of the Program's source code as you
   3900   1.1.1.2  mrg      receive it, in any medium, provided that you conspicuously and
   3901   1.1.1.2  mrg      appropriately publish on each copy an appropriate copyright notice;
   3902   1.1.1.2  mrg      keep intact all notices stating that this License and any
   3903   1.1.1.2  mrg      non-permissive terms added in accord with section 7 apply to the
   3904   1.1.1.2  mrg      code; keep intact all notices of the absence of any warranty; and
   3905   1.1.1.2  mrg      give all recipients a copy of this License along with the Program.
   3906   1.1.1.2  mrg 
   3907   1.1.1.2  mrg      You may charge any price or no price for each copy that you convey,
   3908   1.1.1.2  mrg      and you may offer support or warranty protection for a fee.
   3909   1.1.1.2  mrg 
   3910   1.1.1.2  mrg   5. Conveying Modified Source Versions.
   3911   1.1.1.2  mrg 
   3912   1.1.1.2  mrg      You may convey a work based on the Program, or the modifications to
   3913   1.1.1.2  mrg      produce it from the Program, in the form of source code under the
   3914   1.1.1.2  mrg      terms of section 4, provided that you also meet all of these
   3915   1.1.1.2  mrg      conditions:
   3916   1.1.1.2  mrg 
   3917   1.1.1.2  mrg        a. The work must carry prominent notices stating that you
   3918   1.1.1.2  mrg           modified it, and giving a relevant date.
   3919   1.1.1.2  mrg 
   3920   1.1.1.2  mrg        b. The work must carry prominent notices stating that it is
   3921   1.1.1.2  mrg           released under this License and any conditions added under
   3922   1.1.1.2  mrg           section 7.  This requirement modifies the requirement in
   3923   1.1.1.2  mrg           section 4 to "keep intact all notices".
   3924   1.1.1.2  mrg 
   3925   1.1.1.2  mrg        c. You must license the entire work, as a whole, under this
   3926   1.1.1.2  mrg           License to anyone who comes into possession of a copy.  This
   3927   1.1.1.2  mrg           License will therefore apply, along with any applicable
   3928   1.1.1.2  mrg           section 7 additional terms, to the whole of the work, and all
   3929   1.1.1.2  mrg           its parts, regardless of how they are packaged.  This License
   3930   1.1.1.2  mrg           gives no permission to license the work in any other way, but
   3931   1.1.1.2  mrg           it does not invalidate such permission if you have separately
   3932   1.1.1.2  mrg           received it.
   3933   1.1.1.2  mrg 
   3934   1.1.1.2  mrg        d. If the work has interactive user interfaces, each must display
   3935   1.1.1.2  mrg           Appropriate Legal Notices; however, if the Program has
   3936   1.1.1.2  mrg           interactive interfaces that do not display Appropriate Legal
   3937   1.1.1.2  mrg           Notices, your work need not make them do so.
   3938   1.1.1.2  mrg 
   3939   1.1.1.2  mrg      A compilation of a covered work with other separate and independent
   3940   1.1.1.2  mrg      works, which are not by their nature extensions of the covered
   3941   1.1.1.2  mrg      work, and which are not combined with it such as to form a larger
   3942   1.1.1.2  mrg      program, in or on a volume of a storage or distribution medium, is
   3943   1.1.1.2  mrg      called an "aggregate" if the compilation and its resulting
   3944   1.1.1.2  mrg      copyright are not used to limit the access or legal rights of the
   3945   1.1.1.2  mrg      compilation's users beyond what the individual works permit.
   3946   1.1.1.2  mrg      Inclusion of a covered work in an aggregate does not cause this
   3947   1.1.1.2  mrg      License to apply to the other parts of the aggregate.
   3948   1.1.1.2  mrg 
   3949   1.1.1.2  mrg   6. Conveying Non-Source Forms.
   3950   1.1.1.2  mrg 
   3951   1.1.1.2  mrg      You may convey a covered work in object code form under the terms
   3952   1.1.1.2  mrg      of sections 4 and 5, provided that you also convey the
   3953   1.1.1.2  mrg      machine-readable Corresponding Source under the terms of this
   3954   1.1.1.2  mrg      License, in one of these ways:
   3955   1.1.1.2  mrg 
   3956   1.1.1.2  mrg        a. Convey the object code in, or embodied in, a physical product
   3957   1.1.1.2  mrg           (including a physical distribution medium), accompanied by the
   3958   1.1.1.2  mrg           Corresponding Source fixed on a durable physical medium
   3959   1.1.1.2  mrg           customarily used for software interchange.
   3960   1.1.1.2  mrg 
   3961   1.1.1.2  mrg        b. Convey the object code in, or embodied in, a physical product
   3962   1.1.1.2  mrg           (including a physical distribution medium), accompanied by a
   3963   1.1.1.8  mrg           written offer, valid for at least three years and valid for as
   3964   1.1.1.8  mrg           long as you offer spare parts or customer support for that
   3965   1.1.1.2  mrg           product model, to give anyone who possesses the object code
   3966   1.1.1.2  mrg           either (1) a copy of the Corresponding Source for all the
   3967   1.1.1.2  mrg           software in the product that is covered by this License, on a
   3968   1.1.1.2  mrg           durable physical medium customarily used for software
   3969   1.1.1.2  mrg           interchange, for a price no more than your reasonable cost of
   3970   1.1.1.2  mrg           physically performing this conveying of source, or (2) access
   3971   1.1.1.2  mrg           to copy the Corresponding Source from a network server at no
   3972   1.1.1.2  mrg           charge.
   3973   1.1.1.2  mrg 
   3974   1.1.1.8  mrg        c. Convey individual copies of the object code with a copy of the
   3975   1.1.1.8  mrg           written offer to provide the Corresponding Source.  This
   3976   1.1.1.2  mrg           alternative is allowed only occasionally and noncommercially,
   3977   1.1.1.2  mrg           and only if you received the object code with such an offer,
   3978   1.1.1.2  mrg           in accord with subsection 6b.
   3979   1.1.1.2  mrg 
   3980   1.1.1.2  mrg        d. Convey the object code by offering access from a designated
   3981   1.1.1.8  mrg           place (gratis or for a charge), and offer equivalent access to
   3982   1.1.1.8  mrg           the Corresponding Source in the same way through the same
   3983   1.1.1.2  mrg           place at no further charge.  You need not require recipients
   3984   1.1.1.2  mrg           to copy the Corresponding Source along with the object code.
   3985   1.1.1.2  mrg           If the place to copy the object code is a network server, the
   3986   1.1.1.8  mrg           Corresponding Source may be on a different server (operated by
   3987   1.1.1.8  mrg           you or a third party) that supports equivalent copying
   3988   1.1.1.8  mrg           facilities, provided you maintain clear directions next to the
   3989   1.1.1.8  mrg           object code saying where to find the Corresponding Source.
   3990   1.1.1.2  mrg           Regardless of what server hosts the Corresponding Source, you
   3991   1.1.1.8  mrg           remain obligated to ensure that it is available for as long as
   3992   1.1.1.8  mrg           needed to satisfy these requirements.
   3993   1.1.1.2  mrg 
   3994   1.1.1.2  mrg        e. Convey the object code using peer-to-peer transmission,
   3995   1.1.1.2  mrg           provided you inform other peers where the object code and
   3996   1.1.1.2  mrg           Corresponding Source of the work are being offered to the
   3997   1.1.1.2  mrg           general public at no charge under subsection 6d.
   3998   1.1.1.2  mrg 
   3999   1.1.1.2  mrg      A separable portion of the object code, whose source code is
   4000   1.1.1.2  mrg      excluded from the Corresponding Source as a System Library, need
   4001   1.1.1.2  mrg      not be included in conveying the object code work.
   4002   1.1.1.2  mrg 
   4003   1.1.1.2  mrg      A "User Product" is either (1) a "consumer product", which means
   4004   1.1.1.2  mrg      any tangible personal property which is normally used for personal,
   4005   1.1.1.2  mrg      family, or household purposes, or (2) anything designed or sold for
   4006   1.1.1.8  mrg      incorporation into a dwelling.  In determining whether a product is
   4007   1.1.1.8  mrg      a consumer product, doubtful cases shall be resolved in favor of
   4008   1.1.1.2  mrg      coverage.  For a particular product received by a particular user,
   4009   1.1.1.2  mrg      "normally used" refers to a typical or common use of that class of
   4010   1.1.1.2  mrg      product, regardless of the status of the particular user or of the
   4011   1.1.1.2  mrg      way in which the particular user actually uses, or expects or is
   4012   1.1.1.2  mrg      expected to use, the product.  A product is a consumer product
   4013   1.1.1.2  mrg      regardless of whether the product has substantial commercial,
   4014   1.1.1.2  mrg      industrial or non-consumer uses, unless such uses represent the
   4015   1.1.1.2  mrg      only significant mode of use of the product.
   4016   1.1.1.2  mrg 
   4017   1.1.1.2  mrg      "Installation Information" for a User Product means any methods,
   4018   1.1.1.2  mrg      procedures, authorization keys, or other information required to
   4019   1.1.1.2  mrg      install and execute modified versions of a covered work in that
   4020   1.1.1.2  mrg      User Product from a modified version of its Corresponding Source.
   4021   1.1.1.2  mrg      The information must suffice to ensure that the continued
   4022   1.1.1.2  mrg      functioning of the modified object code is in no case prevented or
   4023   1.1.1.2  mrg      interfered with solely because modification has been made.
   4024   1.1.1.2  mrg 
   4025   1.1.1.2  mrg      If you convey an object code work under this section in, or with,
   4026   1.1.1.2  mrg      or specifically for use in, a User Product, and the conveying
   4027   1.1.1.2  mrg      occurs as part of a transaction in which the right of possession
   4028   1.1.1.2  mrg      and use of the User Product is transferred to the recipient in
   4029   1.1.1.2  mrg      perpetuity or for a fixed term (regardless of how the transaction
   4030   1.1.1.2  mrg      is characterized), the Corresponding Source conveyed under this
   4031   1.1.1.2  mrg      section must be accompanied by the Installation Information.  But
   4032   1.1.1.2  mrg      this requirement does not apply if neither you nor any third party
   4033   1.1.1.2  mrg      retains the ability to install modified object code on the User
   4034   1.1.1.2  mrg      Product (for example, the work has been installed in ROM).
   4035   1.1.1.2  mrg 
   4036   1.1.1.2  mrg      The requirement to provide Installation Information does not
   4037   1.1.1.2  mrg      include a requirement to continue to provide support service,
   4038   1.1.1.8  mrg      warranty, or updates for a work that has been modified or installed
   4039   1.1.1.8  mrg      by the recipient, or for the User Product in which it has been
   4040   1.1.1.8  mrg      modified or installed.  Access to a network may be denied when the
   4041   1.1.1.8  mrg      modification itself materially and adversely affects the operation
   4042   1.1.1.8  mrg      of the network or violates the rules and protocols for
   4043   1.1.1.2  mrg      communication across the network.
   4044   1.1.1.2  mrg 
   4045   1.1.1.2  mrg      Corresponding Source conveyed, and Installation Information
   4046   1.1.1.2  mrg      provided, in accord with this section must be in a format that is
   4047   1.1.1.2  mrg      publicly documented (and with an implementation available to the
   4048   1.1.1.2  mrg      public in source code form), and must require no special password
   4049   1.1.1.2  mrg      or key for unpacking, reading or copying.
   4050   1.1.1.2  mrg 
   4051   1.1.1.2  mrg   7. Additional Terms.
   4052   1.1.1.2  mrg 
   4053   1.1.1.2  mrg      "Additional permissions" are terms that supplement the terms of
   4054   1.1.1.2  mrg      this License by making exceptions from one or more of its
   4055   1.1.1.2  mrg      conditions.  Additional permissions that are applicable to the
   4056   1.1.1.2  mrg      entire Program shall be treated as though they were included in
   4057   1.1.1.2  mrg      this License, to the extent that they are valid under applicable
   4058   1.1.1.2  mrg      law.  If additional permissions apply only to part of the Program,
   4059   1.1.1.2  mrg      that part may be used separately under those permissions, but the
   4060   1.1.1.2  mrg      entire Program remains governed by this License without regard to
   4061   1.1.1.2  mrg      the additional permissions.
   4062   1.1.1.2  mrg 
   4063   1.1.1.2  mrg      When you convey a copy of a covered work, you may at your option
   4064   1.1.1.2  mrg      remove any additional permissions from that copy, or from any part
   4065   1.1.1.2  mrg      of it.  (Additional permissions may be written to require their own
   4066   1.1.1.2  mrg      removal in certain cases when you modify the work.)  You may place
   4067   1.1.1.2  mrg      additional permissions on material, added by you to a covered work,
   4068   1.1.1.2  mrg      for which you have or can give appropriate copyright permission.
   4069   1.1.1.2  mrg 
   4070   1.1.1.2  mrg      Notwithstanding any other provision of this License, for material
   4071   1.1.1.2  mrg      you add to a covered work, you may (if authorized by the copyright
   4072   1.1.1.8  mrg      holders of that material) supplement the terms of this License with
   4073   1.1.1.8  mrg      terms:
   4074   1.1.1.2  mrg 
   4075   1.1.1.2  mrg        a. Disclaiming warranty or limiting liability differently from
   4076   1.1.1.2  mrg           the terms of sections 15 and 16 of this License; or
   4077   1.1.1.2  mrg 
   4078   1.1.1.2  mrg        b. Requiring preservation of specified reasonable legal notices
   4079   1.1.1.2  mrg           or author attributions in that material or in the Appropriate
   4080   1.1.1.2  mrg           Legal Notices displayed by works containing it; or
   4081   1.1.1.2  mrg 
   4082   1.1.1.2  mrg        c. Prohibiting misrepresentation of the origin of that material,
   4083   1.1.1.8  mrg           or requiring that modified versions of such material be marked
   4084   1.1.1.8  mrg           in reasonable ways as different from the original version; or
   4085   1.1.1.2  mrg 
   4086   1.1.1.2  mrg        d. Limiting the use for publicity purposes of names of licensors
   4087   1.1.1.2  mrg           or authors of the material; or
   4088   1.1.1.2  mrg 
   4089   1.1.1.2  mrg        e. Declining to grant rights under trademark law for use of some
   4090   1.1.1.2  mrg           trade names, trademarks, or service marks; or
   4091   1.1.1.2  mrg 
   4092   1.1.1.2  mrg        f. Requiring indemnification of licensors and authors of that
   4093   1.1.1.2  mrg           material by anyone who conveys the material (or modified
   4094   1.1.1.2  mrg           versions of it) with contractual assumptions of liability to
   4095   1.1.1.2  mrg           the recipient, for any liability that these contractual
   4096   1.1.1.2  mrg           assumptions directly impose on those licensors and authors.
   4097   1.1.1.2  mrg 
   4098   1.1.1.2  mrg      All other non-permissive additional terms are considered "further
   4099   1.1.1.2  mrg      restrictions" within the meaning of section 10.  If the Program as
   4100   1.1.1.2  mrg      you received it, or any part of it, contains a notice stating that
   4101   1.1.1.2  mrg      it is governed by this License along with a term that is a further
   4102   1.1.1.2  mrg      restriction, you may remove that term.  If a license document
   4103   1.1.1.8  mrg      contains a further restriction but permits relicensing or conveying
   4104   1.1.1.8  mrg      under this License, you may add to a covered work material governed
   4105   1.1.1.8  mrg      by the terms of that license document, provided that the further
   4106   1.1.1.8  mrg      restriction does not survive such relicensing or conveying.
   4107   1.1.1.2  mrg 
   4108   1.1.1.2  mrg      If you add terms to a covered work in accord with this section, you
   4109   1.1.1.2  mrg      must place, in the relevant source files, a statement of the
   4110   1.1.1.2  mrg      additional terms that apply to those files, or a notice indicating
   4111   1.1.1.2  mrg      where to find the applicable terms.
   4112   1.1.1.2  mrg 
   4113   1.1.1.2  mrg      Additional terms, permissive or non-permissive, may be stated in
   4114   1.1.1.2  mrg      the form of a separately written license, or stated as exceptions;
   4115   1.1.1.2  mrg      the above requirements apply either way.
   4116   1.1.1.2  mrg 
   4117   1.1.1.2  mrg   8. Termination.
   4118   1.1.1.2  mrg 
   4119   1.1.1.2  mrg      You may not propagate or modify a covered work except as expressly
   4120   1.1.1.2  mrg      provided under this License.  Any attempt otherwise to propagate or
   4121   1.1.1.2  mrg      modify it is void, and will automatically terminate your rights
   4122   1.1.1.8  mrg      under this License (including any patent licenses granted under the
   4123   1.1.1.8  mrg      third paragraph of section 11).
   4124   1.1.1.2  mrg 
   4125   1.1.1.2  mrg      However, if you cease all violation of this License, then your
   4126   1.1.1.2  mrg      license from a particular copyright holder is reinstated (a)
   4127   1.1.1.8  mrg      provisionally, unless and until the copyright holder explicitly and
   4128   1.1.1.8  mrg      finally terminates your license, and (b) permanently, if the
   4129   1.1.1.2  mrg      copyright holder fails to notify you of the violation by some
   4130   1.1.1.2  mrg      reasonable means prior to 60 days after the cessation.
   4131   1.1.1.2  mrg 
   4132   1.1.1.2  mrg      Moreover, your license from a particular copyright holder is
   4133   1.1.1.2  mrg      reinstated permanently if the copyright holder notifies you of the
   4134   1.1.1.2  mrg      violation by some reasonable means, this is the first time you have
   4135   1.1.1.2  mrg      received notice of violation of this License (for any work) from
   4136   1.1.1.2  mrg      that copyright holder, and you cure the violation prior to 30 days
   4137   1.1.1.2  mrg      after your receipt of the notice.
   4138   1.1.1.2  mrg 
   4139   1.1.1.2  mrg      Termination of your rights under this section does not terminate
   4140   1.1.1.8  mrg      the licenses of parties who have received copies or rights from you
   4141   1.1.1.8  mrg      under this License.  If your rights have been terminated and not
   4142   1.1.1.8  mrg      permanently reinstated, you do not qualify to receive new licenses
   4143   1.1.1.8  mrg      for the same material under section 10.
   4144   1.1.1.2  mrg 
   4145   1.1.1.2  mrg   9. Acceptance Not Required for Having Copies.
   4146   1.1.1.2  mrg 
   4147   1.1.1.2  mrg      You are not required to accept this License in order to receive or
   4148   1.1.1.2  mrg      run a copy of the Program.  Ancillary propagation of a covered work
   4149   1.1.1.2  mrg      occurring solely as a consequence of using peer-to-peer
   4150   1.1.1.2  mrg      transmission to receive a copy likewise does not require
   4151   1.1.1.2  mrg      acceptance.  However, nothing other than this License grants you
   4152   1.1.1.2  mrg      permission to propagate or modify any covered work.  These actions
   4153   1.1.1.2  mrg      infringe copyright if you do not accept this License.  Therefore,
   4154   1.1.1.2  mrg      by modifying or propagating a covered work, you indicate your
   4155   1.1.1.2  mrg      acceptance of this License to do so.
   4156   1.1.1.2  mrg 
   4157   1.1.1.8  mrg   10. Automatic Licensing of Downstream Recipients.
   4158   1.1.1.2  mrg 
   4159   1.1.1.2  mrg      Each time you convey a covered work, the recipient automatically
   4160   1.1.1.2  mrg      receives a license from the original licensors, to run, modify and
   4161   1.1.1.2  mrg      propagate that work, subject to this License.  You are not
   4162   1.1.1.2  mrg      responsible for enforcing compliance by third parties with this
   4163   1.1.1.2  mrg      License.
   4164   1.1.1.2  mrg 
   4165   1.1.1.2  mrg      An "entity transaction" is a transaction transferring control of an
   4166   1.1.1.2  mrg      organization, or substantially all assets of one, or subdividing an
   4167   1.1.1.2  mrg      organization, or merging organizations.  If propagation of a
   4168   1.1.1.2  mrg      covered work results from an entity transaction, each party to that
   4169   1.1.1.2  mrg      transaction who receives a copy of the work also receives whatever
   4170   1.1.1.2  mrg      licenses to the work the party's predecessor in interest had or
   4171   1.1.1.8  mrg      could give under the previous paragraph, plus a right to possession
   4172   1.1.1.8  mrg      of the Corresponding Source of the work from the predecessor in
   4173   1.1.1.8  mrg      interest, if the predecessor has it or can get it with reasonable
   4174   1.1.1.8  mrg      efforts.
   4175   1.1.1.2  mrg 
   4176   1.1.1.2  mrg      You may not impose any further restrictions on the exercise of the
   4177   1.1.1.2  mrg      rights granted or affirmed under this License.  For example, you
   4178   1.1.1.8  mrg      may not impose a license fee, royalty, or other charge for exercise
   4179   1.1.1.8  mrg      of rights granted under this License, and you may not initiate
   4180   1.1.1.8  mrg      litigation (including a cross-claim or counterclaim in a lawsuit)
   4181   1.1.1.8  mrg      alleging that any patent claim is infringed by making, using,
   4182   1.1.1.8  mrg      selling, offering for sale, or importing the Program or any portion
   4183   1.1.1.8  mrg      of it.
   4184   1.1.1.2  mrg 
   4185   1.1.1.8  mrg   11. Patents.
   4186   1.1.1.2  mrg 
   4187   1.1.1.2  mrg      A "contributor" is a copyright holder who authorizes use under this
   4188   1.1.1.2  mrg      License of the Program or a work on which the Program is based.
   4189   1.1.1.2  mrg      The work thus licensed is called the contributor's "contributor
   4190   1.1.1.2  mrg      version".
   4191   1.1.1.2  mrg 
   4192   1.1.1.2  mrg      A contributor's "essential patent claims" are all patent claims
   4193   1.1.1.2  mrg      owned or controlled by the contributor, whether already acquired or
   4194   1.1.1.2  mrg      hereafter acquired, that would be infringed by some manner,
   4195   1.1.1.2  mrg      permitted by this License, of making, using, or selling its
   4196   1.1.1.2  mrg      contributor version, but do not include claims that would be
   4197   1.1.1.2  mrg      infringed only as a consequence of further modification of the
   4198   1.1.1.2  mrg      contributor version.  For purposes of this definition, "control"
   4199   1.1.1.2  mrg      includes the right to grant patent sublicenses in a manner
   4200   1.1.1.2  mrg      consistent with the requirements of this License.
   4201   1.1.1.2  mrg 
   4202   1.1.1.2  mrg      Each contributor grants you a non-exclusive, worldwide,
   4203   1.1.1.2  mrg      royalty-free patent license under the contributor's essential
   4204   1.1.1.2  mrg      patent claims, to make, use, sell, offer for sale, import and
   4205   1.1.1.8  mrg      otherwise run, modify and propagate the contents of its contributor
   4206   1.1.1.8  mrg      version.
   4207   1.1.1.2  mrg 
   4208   1.1.1.2  mrg      In the following three paragraphs, a "patent license" is any
   4209   1.1.1.2  mrg      express agreement or commitment, however denominated, not to
   4210   1.1.1.2  mrg      enforce a patent (such as an express permission to practice a
   4211   1.1.1.8  mrg      patent or covenant not to sue for patent infringement).  To "grant"
   4212   1.1.1.8  mrg      such a patent license to a party means to make such an agreement or
   4213   1.1.1.8  mrg      commitment not to enforce a patent against the party.
   4214   1.1.1.2  mrg 
   4215   1.1.1.2  mrg      If you convey a covered work, knowingly relying on a patent
   4216   1.1.1.2  mrg      license, and the Corresponding Source of the work is not available
   4217   1.1.1.2  mrg      for anyone to copy, free of charge and under the terms of this
   4218   1.1.1.2  mrg      License, through a publicly available network server or other
   4219   1.1.1.2  mrg      readily accessible means, then you must either (1) cause the
   4220   1.1.1.2  mrg      Corresponding Source to be so available, or (2) arrange to deprive
   4221   1.1.1.2  mrg      yourself of the benefit of the patent license for this particular
   4222   1.1.1.2  mrg      work, or (3) arrange, in a manner consistent with the requirements
   4223   1.1.1.2  mrg      of this License, to extend the patent license to downstream
   4224   1.1.1.2  mrg      recipients.  "Knowingly relying" means you have actual knowledge
   4225   1.1.1.2  mrg      that, but for the patent license, your conveying the covered work
   4226   1.1.1.2  mrg      in a country, or your recipient's use of the covered work in a
   4227   1.1.1.2  mrg      country, would infringe one or more identifiable patents in that
   4228   1.1.1.2  mrg      country that you have reason to believe are valid.
   4229   1.1.1.2  mrg 
   4230   1.1.1.2  mrg      If, pursuant to or in connection with a single transaction or
   4231   1.1.1.2  mrg      arrangement, you convey, or propagate by procuring conveyance of, a
   4232   1.1.1.2  mrg      covered work, and grant a patent license to some of the parties
   4233   1.1.1.2  mrg      receiving the covered work authorizing them to use, propagate,
   4234   1.1.1.2  mrg      modify or convey a specific copy of the covered work, then the
   4235   1.1.1.2  mrg      patent license you grant is automatically extended to all
   4236   1.1.1.2  mrg      recipients of the covered work and works based on it.
   4237   1.1.1.2  mrg 
   4238   1.1.1.2  mrg      A patent license is "discriminatory" if it does not include within
   4239   1.1.1.2  mrg      the scope of its coverage, prohibits the exercise of, or is
   4240   1.1.1.2  mrg      conditioned on the non-exercise of one or more of the rights that
   4241   1.1.1.2  mrg      are specifically granted under this License.  You may not convey a
   4242   1.1.1.2  mrg      covered work if you are a party to an arrangement with a third
   4243   1.1.1.8  mrg      party that is in the business of distributing software, under which
   4244   1.1.1.8  mrg      you make payment to the third party based on the extent of your
   4245   1.1.1.8  mrg      activity of conveying the work, and under which the third party
   4246   1.1.1.8  mrg      grants, to any of the parties who would receive the covered work
   4247   1.1.1.8  mrg      from you, a discriminatory patent license (a) in connection with
   4248   1.1.1.8  mrg      copies of the covered work conveyed by you (or copies made from
   4249   1.1.1.8  mrg      those copies), or (b) primarily for and in connection with specific
   4250   1.1.1.8  mrg      products or compilations that contain the covered work, unless you
   4251   1.1.1.8  mrg      entered into that arrangement, or that patent license was granted,
   4252   1.1.1.8  mrg      prior to 28 March 2007.
   4253   1.1.1.2  mrg 
   4254   1.1.1.2  mrg      Nothing in this License shall be construed as excluding or limiting
   4255   1.1.1.2  mrg      any implied license or other defenses to infringement that may
   4256   1.1.1.2  mrg      otherwise be available to you under applicable patent law.
   4257   1.1.1.2  mrg 
   4258   1.1.1.8  mrg   12. No Surrender of Others' Freedom.
   4259   1.1.1.2  mrg 
   4260   1.1.1.8  mrg      If conditions are imposed on you (whether by court order, agreement
   4261   1.1.1.8  mrg      or otherwise) that contradict the conditions of this License, they
   4262   1.1.1.8  mrg      do not excuse you from the conditions of this License.  If you
   4263   1.1.1.8  mrg      cannot convey a covered work so as to satisfy simultaneously your
   4264   1.1.1.8  mrg      obligations under this License and any other pertinent obligations,
   4265   1.1.1.8  mrg      then as a consequence you may not convey it at all.  For example,
   4266   1.1.1.8  mrg      if you agree to terms that obligate you to collect a royalty for
   4267   1.1.1.8  mrg      further conveying from those to whom you convey the Program, the
   4268   1.1.1.8  mrg      only way you could satisfy both those terms and this License would
   4269   1.1.1.8  mrg      be to refrain entirely from conveying the Program.
   4270   1.1.1.2  mrg 
   4271   1.1.1.8  mrg   13. Use with the GNU Affero General Public License.
   4272   1.1.1.2  mrg 
   4273   1.1.1.2  mrg      Notwithstanding any other provision of this License, you have
   4274   1.1.1.2  mrg      permission to link or combine any covered work with a work licensed
   4275   1.1.1.2  mrg      under version 3 of the GNU Affero General Public License into a
   4276   1.1.1.2  mrg      single combined work, and to convey the resulting work.  The terms
   4277   1.1.1.2  mrg      of this License will continue to apply to the part which is the
   4278   1.1.1.2  mrg      covered work, but the special requirements of the GNU Affero
   4279   1.1.1.2  mrg      General Public License, section 13, concerning interaction through
   4280   1.1.1.2  mrg      a network will apply to the combination as such.
   4281   1.1.1.2  mrg 
   4282   1.1.1.8  mrg   14. Revised Versions of this License.
   4283   1.1.1.2  mrg 
   4284   1.1.1.2  mrg      The Free Software Foundation may publish revised and/or new
   4285   1.1.1.8  mrg      versions of the GNU General Public License from time to time.  Such
   4286   1.1.1.8  mrg      new versions will be similar in spirit to the present version, but
   4287   1.1.1.8  mrg      may differ in detail to address new problems or concerns.
   4288       1.1  mrg 
   4289       1.1  mrg      Each version is given a distinguishing version number.  If the
   4290   1.1.1.2  mrg      Program specifies that a certain numbered version of the GNU
   4291   1.1.1.2  mrg      General Public License "or any later version" applies to it, you
   4292   1.1.1.2  mrg      have the option of following the terms and conditions either of
   4293   1.1.1.8  mrg      that numbered version or of any later version published by the Free
   4294   1.1.1.8  mrg      Software Foundation.  If the Program does not specify a version
   4295   1.1.1.8  mrg      number of the GNU General Public License, you may choose any
   4296   1.1.1.8  mrg      version ever published by the Free Software Foundation.
   4297       1.1  mrg 
   4298   1.1.1.2  mrg      If the Program specifies that a proxy can decide which future
   4299   1.1.1.2  mrg      versions of the GNU General Public License can be used, that
   4300   1.1.1.2  mrg      proxy's public statement of acceptance of a version permanently
   4301   1.1.1.2  mrg      authorizes you to choose that version for the Program.
   4302   1.1.1.2  mrg 
   4303   1.1.1.2  mrg      Later license versions may give you additional or different
   4304   1.1.1.2  mrg      permissions.  However, no additional obligations are imposed on any
   4305   1.1.1.2  mrg      author or copyright holder as a result of your choosing to follow a
   4306   1.1.1.2  mrg      later version.
   4307   1.1.1.2  mrg 
   4308   1.1.1.8  mrg   15. Disclaimer of Warranty.
   4309   1.1.1.2  mrg 
   4310   1.1.1.2  mrg      THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
   4311   1.1.1.8  mrg      APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE
   4312   1.1.1.2  mrg      COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS"
   4313   1.1.1.2  mrg      WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED,
   4314   1.1.1.2  mrg      INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
   4315   1.1.1.8  mrg      MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE
   4316   1.1.1.2  mrg      RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.
   4317   1.1.1.2  mrg      SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL
   4318   1.1.1.2  mrg      NECESSARY SERVICING, REPAIR OR CORRECTION.
   4319   1.1.1.2  mrg 
   4320   1.1.1.8  mrg   16. Limitation of Liability.
   4321   1.1.1.2  mrg 
   4322   1.1.1.2  mrg      IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
   4323   1.1.1.2  mrg      WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES
   4324   1.1.1.8  mrg      AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR
   4325   1.1.1.8  mrg      DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
   4326   1.1.1.2  mrg      CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE
   4327   1.1.1.2  mrg      THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA
   4328   1.1.1.2  mrg      BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
   4329   1.1.1.2  mrg      PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
   4330   1.1.1.2  mrg      PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF
   4331   1.1.1.2  mrg      THE POSSIBILITY OF SUCH DAMAGES.
   4332   1.1.1.2  mrg 
   4333   1.1.1.8  mrg   17. Interpretation of Sections 15 and 16.
   4334   1.1.1.2  mrg 
   4335   1.1.1.2  mrg      If the disclaimer of warranty and limitation of liability provided
   4336   1.1.1.2  mrg      above cannot be given local legal effect according to their terms,
   4337   1.1.1.2  mrg      reviewing courts shall apply local law that most closely
   4338   1.1.1.2  mrg      approximates an absolute waiver of all civil liability in
   4339   1.1.1.2  mrg      connection with the Program, unless a warranty or assumption of
   4340   1.1.1.2  mrg      liability accompanies a copy of the Program in return for a fee.
   4341       1.1  mrg 
   4342   1.1.1.2  mrg END OF TERMS AND CONDITIONS
   4343   1.1.1.2  mrg ===========================
   4344   1.1.1.2  mrg 
   4345   1.1.1.2  mrg How to Apply These Terms to Your New Programs
   4346   1.1.1.2  mrg =============================================
   4347       1.1  mrg 
   4348       1.1  mrg If you develop a new program, and you want it to be of the greatest
   4349       1.1  mrg possible use to the public, the best way to achieve this is to make it
   4350       1.1  mrg free software which everyone can redistribute and change under these
   4351       1.1  mrg terms.
   4352       1.1  mrg 
   4353       1.1  mrg    To do so, attach the following notices to the program.  It is safest
   4354       1.1  mrg to attach them to the start of each source file to most effectively
   4355   1.1.1.2  mrg state the exclusion of warranty; and each file should have at least the
   4356   1.1.1.2  mrg "copyright" line and a pointer to where the full notice is found.
   4357       1.1  mrg 
   4358       1.1  mrg      ONE LINE TO GIVE THE PROGRAM'S NAME AND A BRIEF IDEA OF WHAT IT DOES.
   4359   1.1.1.2  mrg      Copyright (C) YEAR NAME OF AUTHOR
   4360       1.1  mrg 
   4361   1.1.1.2  mrg      This program is free software: you can redistribute it and/or modify
   4362       1.1  mrg      it under the terms of the GNU General Public License as published by
   4363   1.1.1.2  mrg      the Free Software Foundation, either version 3 of the License, or (at
   4364   1.1.1.2  mrg      your option) any later version.
   4365       1.1  mrg 
   4366   1.1.1.2  mrg      This program is distributed in the hope that it will be useful, but
   4367   1.1.1.2  mrg      WITHOUT ANY WARRANTY; without even the implied warranty of
   4368   1.1.1.2  mrg      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
   4369   1.1.1.2  mrg      General Public License for more details.
   4370       1.1  mrg 
   4371       1.1  mrg      You should have received a copy of the GNU General Public License
   4372   1.1.1.8  mrg      along with this program.  If not, see <http://www.gnu.org/licenses/>.
   4373       1.1  mrg 
   4374       1.1  mrg    Also add information on how to contact you by electronic and paper
   4375       1.1  mrg mail.
   4376       1.1  mrg 
   4377   1.1.1.2  mrg    If the program does terminal interaction, make it output a short
   4378   1.1.1.2  mrg notice like this when it starts in an interactive mode:
   4379       1.1  mrg 
   4380   1.1.1.2  mrg      PROGRAM Copyright (C) YEAR NAME OF AUTHOR
   4381   1.1.1.8  mrg      This program comes with ABSOLUTELY NO WARRANTY; for details type 'show w'.
   4382       1.1  mrg      This is free software, and you are welcome to redistribute it
   4383   1.1.1.8  mrg      under certain conditions; type 'show c' for details.
   4384       1.1  mrg 
   4385   1.1.1.8  mrg    The hypothetical commands 'show w' and 'show c' should show the
   4386   1.1.1.2  mrg appropriate parts of the General Public License.  Of course, your
   4387   1.1.1.2  mrg program's commands might be different; for a GUI interface, you would
   4388   1.1.1.2  mrg use an "about box".
   4389       1.1  mrg 
   4390       1.1  mrg    You should also get your employer (if you work as a programmer) or
   4391   1.1.1.2  mrg school, if any, to sign a "copyright disclaimer" for the program, if
   4392   1.1.1.2  mrg necessary.  For more information on this, and how to apply and follow
   4393   1.1.1.8  mrg the GNU GPL, see <http://www.gnu.org/licenses/>.
   4394       1.1  mrg 
   4395   1.1.1.2  mrg    The GNU General Public License does not permit incorporating your
   4396       1.1  mrg program into proprietary programs.  If your program is a subroutine
   4397       1.1  mrg library, you may consider it more useful to permit linking proprietary
   4398       1.1  mrg applications with the library.  If this is what you want to do, use the
   4399   1.1.1.2  mrg GNU Lesser General Public License instead of this License.  But first,
   4400  1.1.1.10  mrg please read <https://www.gnu.org/licenses/why-not-lgpl.html>.
   4401       1.1  mrg 
   4402       1.1  mrg 
   4403       1.1  mrg File: libgomp.info,  Node: GNU Free Documentation License,  Next: Funding,  Prev: Copying,  Up: Top
   4404       1.1  mrg 
   4405       1.1  mrg GNU Free Documentation License
   4406       1.1  mrg ******************************
   4407       1.1  mrg 
   4408   1.1.1.2  mrg                      Version 1.3, 3 November 2008
   4409       1.1  mrg 
   4410   1.1.1.2  mrg      Copyright (C) 2000, 2001, 2002, 2007, 2008 Free Software Foundation, Inc.
   4411   1.1.1.8  mrg      <http://fsf.org/>
   4412       1.1  mrg 
   4413       1.1  mrg      Everyone is permitted to copy and distribute verbatim copies
   4414       1.1  mrg      of this license document, but changing it is not allowed.
   4415       1.1  mrg 
   4416       1.1  mrg   0. PREAMBLE
   4417       1.1  mrg 
   4418       1.1  mrg      The purpose of this License is to make a manual, textbook, or other
   4419       1.1  mrg      functional and useful document "free" in the sense of freedom: to
   4420       1.1  mrg      assure everyone the effective freedom to copy and redistribute it,
   4421       1.1  mrg      with or without modifying it, either commercially or
   4422       1.1  mrg      noncommercially.  Secondarily, this License preserves for the
   4423       1.1  mrg      author and publisher a way to get credit for their work, while not
   4424       1.1  mrg      being considered responsible for modifications made by others.
   4425       1.1  mrg 
   4426       1.1  mrg      This License is a kind of "copyleft", which means that derivative
   4427       1.1  mrg      works of the document must themselves be free in the same sense.
   4428       1.1  mrg      It complements the GNU General Public License, which is a copyleft
   4429       1.1  mrg      license designed for free software.
   4430       1.1  mrg 
   4431       1.1  mrg      We have designed this License in order to use it for manuals for
   4432       1.1  mrg      free software, because free software needs free documentation: a
   4433       1.1  mrg      free program should come with manuals providing the same freedoms
   4434       1.1  mrg      that the software does.  But this License is not limited to
   4435       1.1  mrg      software manuals; it can be used for any textual work, regardless
   4436   1.1.1.8  mrg      of subject matter or whether it is published as a printed book.  We
   4437   1.1.1.8  mrg      recommend this License principally for works whose purpose is
   4438       1.1  mrg      instruction or reference.
   4439       1.1  mrg 
   4440       1.1  mrg   1. APPLICABILITY AND DEFINITIONS
   4441       1.1  mrg 
   4442       1.1  mrg      This License applies to any manual or other work, in any medium,
   4443   1.1.1.8  mrg      that contains a notice placed by the copyright holder saying it can
   4444   1.1.1.8  mrg      be distributed under the terms of this License.  Such a notice
   4445       1.1  mrg      grants a world-wide, royalty-free license, unlimited in duration,
   4446       1.1  mrg      to use that work under the conditions stated herein.  The
   4447       1.1  mrg      "Document", below, refers to any such manual or work.  Any member
   4448   1.1.1.8  mrg      of the public is a licensee, and is addressed as "you".  You accept
   4449   1.1.1.8  mrg      the license if you copy, modify or distribute the work in a way
   4450   1.1.1.8  mrg      requiring permission under copyright law.
   4451       1.1  mrg 
   4452       1.1  mrg      A "Modified Version" of the Document means any work containing the
   4453       1.1  mrg      Document or a portion of it, either copied verbatim, or with
   4454       1.1  mrg      modifications and/or translated into another language.
   4455       1.1  mrg 
   4456       1.1  mrg      A "Secondary Section" is a named appendix or a front-matter section
   4457       1.1  mrg      of the Document that deals exclusively with the relationship of the
   4458       1.1  mrg      publishers or authors of the Document to the Document's overall
   4459       1.1  mrg      subject (or to related matters) and contains nothing that could
   4460       1.1  mrg      fall directly within that overall subject.  (Thus, if the Document
   4461       1.1  mrg      is in part a textbook of mathematics, a Secondary Section may not
   4462       1.1  mrg      explain any mathematics.)  The relationship could be a matter of
   4463       1.1  mrg      historical connection with the subject or with related matters, or
   4464       1.1  mrg      of legal, commercial, philosophical, ethical or political position
   4465       1.1  mrg      regarding them.
   4466       1.1  mrg 
   4467       1.1  mrg      The "Invariant Sections" are certain Secondary Sections whose
   4468   1.1.1.8  mrg      titles are designated, as being those of Invariant Sections, in the
   4469   1.1.1.8  mrg      notice that says that the Document is released under this License.
   4470   1.1.1.8  mrg      If a section does not fit the above definition of Secondary then it
   4471   1.1.1.8  mrg      is not allowed to be designated as Invariant.  The Document may
   4472   1.1.1.8  mrg      contain zero Invariant Sections.  If the Document does not identify
   4473   1.1.1.8  mrg      any Invariant Sections then there are none.
   4474       1.1  mrg 
   4475       1.1  mrg      The "Cover Texts" are certain short passages of text that are
   4476       1.1  mrg      listed, as Front-Cover Texts or Back-Cover Texts, in the notice
   4477       1.1  mrg      that says that the Document is released under this License.  A
   4478       1.1  mrg      Front-Cover Text may be at most 5 words, and a Back-Cover Text may
   4479       1.1  mrg      be at most 25 words.
   4480       1.1  mrg 
   4481       1.1  mrg      A "Transparent" copy of the Document means a machine-readable copy,
   4482       1.1  mrg      represented in a format whose specification is available to the
   4483       1.1  mrg      general public, that is suitable for revising the document
   4484   1.1.1.8  mrg      straightforwardly with generic text editors or (for images composed
   4485   1.1.1.8  mrg      of pixels) generic paint programs or (for drawings) some widely
   4486   1.1.1.8  mrg      available drawing editor, and that is suitable for input to text
   4487   1.1.1.8  mrg      formatters or for automatic translation to a variety of formats
   4488   1.1.1.8  mrg      suitable for input to text formatters.  A copy made in an otherwise
   4489   1.1.1.8  mrg      Transparent file format whose markup, or absence of markup, has
   4490   1.1.1.8  mrg      been arranged to thwart or discourage subsequent modification by
   4491   1.1.1.8  mrg      readers is not Transparent.  An image format is not Transparent if
   4492   1.1.1.8  mrg      used for any substantial amount of text.  A copy that is not
   4493   1.1.1.8  mrg      "Transparent" is called "Opaque".
   4494       1.1  mrg 
   4495       1.1  mrg      Examples of suitable formats for Transparent copies include plain
   4496       1.1  mrg      ASCII without markup, Texinfo input format, LaTeX input format,
   4497   1.1.1.8  mrg      SGML or XML using a publicly available DTD, and standard-conforming
   4498   1.1.1.8  mrg      simple HTML, PostScript or PDF designed for human modification.
   4499   1.1.1.8  mrg      Examples of transparent image formats include PNG, XCF and JPG.
   4500   1.1.1.8  mrg      Opaque formats include proprietary formats that can be read and
   4501   1.1.1.8  mrg      edited only by proprietary word processors, SGML or XML for which
   4502   1.1.1.8  mrg      the DTD and/or processing tools are not generally available, and
   4503   1.1.1.8  mrg      the machine-generated HTML, PostScript or PDF produced by some word
   4504   1.1.1.8  mrg      processors for output purposes only.
   4505       1.1  mrg 
   4506       1.1  mrg      The "Title Page" means, for a printed book, the title page itself,
   4507       1.1  mrg      plus such following pages as are needed to hold, legibly, the
   4508       1.1  mrg      material this License requires to appear in the title page.  For
   4509       1.1  mrg      works in formats which do not have any title page as such, "Title
   4510       1.1  mrg      Page" means the text near the most prominent appearance of the
   4511       1.1  mrg      work's title, preceding the beginning of the body of the text.
   4512       1.1  mrg 
   4513   1.1.1.2  mrg      The "publisher" means any person or entity that distributes copies
   4514   1.1.1.2  mrg      of the Document to the public.
   4515   1.1.1.2  mrg 
   4516       1.1  mrg      A section "Entitled XYZ" means a named subunit of the Document
   4517       1.1  mrg      whose title either is precisely XYZ or contains XYZ in parentheses
   4518       1.1  mrg      following text that translates XYZ in another language.  (Here XYZ
   4519       1.1  mrg      stands for a specific section name mentioned below, such as
   4520       1.1  mrg      "Acknowledgements", "Dedications", "Endorsements", or "History".)
   4521       1.1  mrg      To "Preserve the Title" of such a section when you modify the
   4522       1.1  mrg      Document means that it remains a section "Entitled XYZ" according
   4523       1.1  mrg      to this definition.
   4524       1.1  mrg 
   4525       1.1  mrg      The Document may include Warranty Disclaimers next to the notice
   4526       1.1  mrg      which states that this License applies to the Document.  These
   4527       1.1  mrg      Warranty Disclaimers are considered to be included by reference in
   4528       1.1  mrg      this License, but only as regards disclaiming warranties: any other
   4529       1.1  mrg      implication that these Warranty Disclaimers may have is void and
   4530       1.1  mrg      has no effect on the meaning of this License.
   4531       1.1  mrg 
   4532       1.1  mrg   2. VERBATIM COPYING
   4533       1.1  mrg 
   4534       1.1  mrg      You may copy and distribute the Document in any medium, either
   4535       1.1  mrg      commercially or noncommercially, provided that this License, the
   4536       1.1  mrg      copyright notices, and the license notice saying this License
   4537       1.1  mrg      applies to the Document are reproduced in all copies, and that you
   4538       1.1  mrg      add no other conditions whatsoever to those of this License.  You
   4539       1.1  mrg      may not use technical measures to obstruct or control the reading
   4540       1.1  mrg      or further copying of the copies you make or distribute.  However,
   4541       1.1  mrg      you may accept compensation in exchange for copies.  If you
   4542   1.1.1.8  mrg      distribute a large enough number of copies you must also follow the
   4543   1.1.1.8  mrg      conditions in section 3.
   4544       1.1  mrg 
   4545       1.1  mrg      You may also lend copies, under the same conditions stated above,
   4546       1.1  mrg      and you may publicly display copies.
   4547       1.1  mrg 
   4548       1.1  mrg   3. COPYING IN QUANTITY
   4549       1.1  mrg 
   4550       1.1  mrg      If you publish printed copies (or copies in media that commonly
   4551       1.1  mrg      have printed covers) of the Document, numbering more than 100, and
   4552       1.1  mrg      the Document's license notice requires Cover Texts, you must
   4553       1.1  mrg      enclose the copies in covers that carry, clearly and legibly, all
   4554       1.1  mrg      these Cover Texts: Front-Cover Texts on the front cover, and
   4555       1.1  mrg      Back-Cover Texts on the back cover.  Both covers must also clearly
   4556       1.1  mrg      and legibly identify you as the publisher of these copies.  The
   4557   1.1.1.8  mrg      front cover must present the full title with all words of the title
   4558   1.1.1.8  mrg      equally prominent and visible.  You may add other material on the
   4559   1.1.1.8  mrg      covers in addition.  Copying with changes limited to the covers, as
   4560   1.1.1.8  mrg      long as they preserve the title of the Document and satisfy these
   4561   1.1.1.8  mrg      conditions, can be treated as verbatim copying in other respects.
   4562       1.1  mrg 
   4563       1.1  mrg      If the required texts for either cover are too voluminous to fit
   4564       1.1  mrg      legibly, you should put the first ones listed (as many as fit
   4565       1.1  mrg      reasonably) on the actual cover, and continue the rest onto
   4566       1.1  mrg      adjacent pages.
   4567       1.1  mrg 
   4568       1.1  mrg      If you publish or distribute Opaque copies of the Document
   4569   1.1.1.8  mrg      numbering more than 100, you must either include a machine-readable
   4570   1.1.1.8  mrg      Transparent copy along with each Opaque copy, or state in or with
   4571   1.1.1.8  mrg      each Opaque copy a computer-network location from which the general
   4572   1.1.1.8  mrg      network-using public has access to download using public-standard
   4573   1.1.1.8  mrg      network protocols a complete Transparent copy of the Document, free
   4574   1.1.1.8  mrg      of added material.  If you use the latter option, you must take
   4575   1.1.1.8  mrg      reasonably prudent steps, when you begin distribution of Opaque
   4576   1.1.1.8  mrg      copies in quantity, to ensure that this Transparent copy will
   4577   1.1.1.8  mrg      remain thus accessible at the stated location until at least one
   4578   1.1.1.8  mrg      year after the last time you distribute an Opaque copy (directly or
   4579   1.1.1.8  mrg      through your agents or retailers) of that edition to the public.
   4580       1.1  mrg 
   4581       1.1  mrg      It is requested, but not required, that you contact the authors of
   4582   1.1.1.8  mrg      the Document well before redistributing any large number of copies,
   4583   1.1.1.8  mrg      to give them a chance to provide you with an updated version of the
   4584   1.1.1.8  mrg      Document.
   4585       1.1  mrg 
   4586       1.1  mrg   4. MODIFICATIONS
   4587       1.1  mrg 
   4588       1.1  mrg      You may copy and distribute a Modified Version of the Document
   4589       1.1  mrg      under the conditions of sections 2 and 3 above, provided that you
   4590   1.1.1.8  mrg      release the Modified Version under precisely this License, with the
   4591   1.1.1.8  mrg      Modified Version filling the role of the Document, thus licensing
   4592   1.1.1.8  mrg      distribution and modification of the Modified Version to whoever
   4593   1.1.1.8  mrg      possesses a copy of it.  In addition, you must do these things in
   4594   1.1.1.8  mrg      the Modified Version:
   4595       1.1  mrg 
   4596       1.1  mrg        A. Use in the Title Page (and on the covers, if any) a title
   4597   1.1.1.8  mrg           distinct from that of the Document, and from those of previous
   4598   1.1.1.8  mrg           versions (which should, if there were any, be listed in the
   4599   1.1.1.8  mrg           History section of the Document).  You may use the same title
   4600   1.1.1.8  mrg           as a previous version if the original publisher of that
   4601   1.1.1.8  mrg           version gives permission.
   4602       1.1  mrg 
   4603       1.1  mrg        B. List on the Title Page, as authors, one or more persons or
   4604       1.1  mrg           entities responsible for authorship of the modifications in
   4605       1.1  mrg           the Modified Version, together with at least five of the
   4606       1.1  mrg           principal authors of the Document (all of its principal
   4607       1.1  mrg           authors, if it has fewer than five), unless they release you
   4608       1.1  mrg           from this requirement.
   4609       1.1  mrg 
   4610       1.1  mrg        C. State on the Title page the name of the publisher of the
   4611       1.1  mrg           Modified Version, as the publisher.
   4612       1.1  mrg 
   4613       1.1  mrg        D. Preserve all the copyright notices of the Document.
   4614       1.1  mrg 
   4615       1.1  mrg        E. Add an appropriate copyright notice for your modifications
   4616       1.1  mrg           adjacent to the other copyright notices.
   4617       1.1  mrg 
   4618       1.1  mrg        F. Include, immediately after the copyright notices, a license
   4619       1.1  mrg           notice giving the public permission to use the Modified
   4620       1.1  mrg           Version under the terms of this License, in the form shown in
   4621       1.1  mrg           the Addendum below.
   4622       1.1  mrg 
   4623       1.1  mrg        G. Preserve in that license notice the full lists of Invariant
   4624       1.1  mrg           Sections and required Cover Texts given in the Document's
   4625       1.1  mrg           license notice.
   4626       1.1  mrg 
   4627       1.1  mrg        H. Include an unaltered copy of this License.
   4628       1.1  mrg 
   4629       1.1  mrg        I. Preserve the section Entitled "History", Preserve its Title,
   4630       1.1  mrg           and add to it an item stating at least the title, year, new
   4631   1.1.1.8  mrg           authors, and publisher of the Modified Version as given on the
   4632   1.1.1.8  mrg           Title Page.  If there is no section Entitled "History" in the
   4633   1.1.1.8  mrg           Document, create one stating the title, year, authors, and
   4634   1.1.1.8  mrg           publisher of the Document as given on its Title Page, then add
   4635   1.1.1.8  mrg           an item describing the Modified Version as stated in the
   4636   1.1.1.8  mrg           previous sentence.
   4637       1.1  mrg 
   4638       1.1  mrg        J. Preserve the network location, if any, given in the Document
   4639       1.1  mrg           for public access to a Transparent copy of the Document, and
   4640       1.1  mrg           likewise the network locations given in the Document for
   4641   1.1.1.8  mrg           previous versions it was based on.  These may be placed in the
   4642   1.1.1.8  mrg           "History" section.  You may omit a network location for a work
   4643   1.1.1.8  mrg           that was published at least four years before the Document
   4644   1.1.1.8  mrg           itself, or if the original publisher of the version it refers
   4645   1.1.1.8  mrg           to gives permission.
   4646       1.1  mrg 
   4647       1.1  mrg        K. For any section Entitled "Acknowledgements" or "Dedications",
   4648   1.1.1.8  mrg           Preserve the Title of the section, and preserve in the section
   4649   1.1.1.8  mrg           all the substance and tone of each of the contributor
   4650       1.1  mrg           acknowledgements and/or dedications given therein.
   4651       1.1  mrg 
   4652   1.1.1.8  mrg        L. Preserve all the Invariant Sections of the Document, unaltered
   4653   1.1.1.8  mrg           in their text and in their titles.  Section numbers or the
   4654   1.1.1.8  mrg           equivalent are not considered part of the section titles.
   4655       1.1  mrg 
   4656       1.1  mrg        M. Delete any section Entitled "Endorsements".  Such a section
   4657       1.1  mrg           may not be included in the Modified Version.
   4658       1.1  mrg 
   4659       1.1  mrg        N. Do not retitle any existing section to be Entitled
   4660       1.1  mrg           "Endorsements" or to conflict in title with any Invariant
   4661       1.1  mrg           Section.
   4662       1.1  mrg 
   4663       1.1  mrg        O. Preserve any Warranty Disclaimers.
   4664       1.1  mrg 
   4665       1.1  mrg      If the Modified Version includes new front-matter sections or
   4666       1.1  mrg      appendices that qualify as Secondary Sections and contain no
   4667   1.1.1.8  mrg      material copied from the Document, you may at your option designate
   4668   1.1.1.8  mrg      some or all of these sections as invariant.  To do this, add their
   4669   1.1.1.8  mrg      titles to the list of Invariant Sections in the Modified Version's
   4670   1.1.1.8  mrg      license notice.  These titles must be distinct from any other
   4671   1.1.1.8  mrg      section titles.
   4672       1.1  mrg 
   4673       1.1  mrg      You may add a section Entitled "Endorsements", provided it contains
   4674       1.1  mrg      nothing but endorsements of your Modified Version by various
   4675       1.1  mrg      parties--for example, statements of peer review or that the text
   4676       1.1  mrg      has been approved by an organization as the authoritative
   4677       1.1  mrg      definition of a standard.
   4678       1.1  mrg 
   4679       1.1  mrg      You may add a passage of up to five words as a Front-Cover Text,
   4680   1.1.1.8  mrg      and a passage of up to 25 words as a Back-Cover Text, to the end of
   4681   1.1.1.8  mrg      the list of Cover Texts in the Modified Version.  Only one passage
   4682   1.1.1.8  mrg      of Front-Cover Text and one of Back-Cover Text may be added by (or
   4683   1.1.1.8  mrg      through arrangements made by) any one entity.  If the Document
   4684   1.1.1.8  mrg      already includes a cover text for the same cover, previously added
   4685   1.1.1.8  mrg      by you or by arrangement made by the same entity you are acting on
   4686   1.1.1.8  mrg      behalf of, you may not add another; but you may replace the old
   4687   1.1.1.8  mrg      one, on explicit permission from the previous publisher that added
   4688   1.1.1.8  mrg      the old one.
   4689       1.1  mrg 
   4690       1.1  mrg      The author(s) and publisher(s) of the Document do not by this
   4691       1.1  mrg      License give permission to use their names for publicity for or to
   4692       1.1  mrg      assert or imply endorsement of any Modified Version.
   4693       1.1  mrg 
   4694       1.1  mrg   5. COMBINING DOCUMENTS
   4695       1.1  mrg 
   4696       1.1  mrg      You may combine the Document with other documents released under
   4697       1.1  mrg      this License, under the terms defined in section 4 above for
   4698   1.1.1.8  mrg      modified versions, provided that you include in the combination all
   4699   1.1.1.8  mrg      of the Invariant Sections of all of the original documents,
   4700       1.1  mrg      unmodified, and list them all as Invariant Sections of your
   4701       1.1  mrg      combined work in its license notice, and that you preserve all
   4702       1.1  mrg      their Warranty Disclaimers.
   4703       1.1  mrg 
   4704       1.1  mrg      The combined work need only contain one copy of this License, and
   4705       1.1  mrg      multiple identical Invariant Sections may be replaced with a single
   4706       1.1  mrg      copy.  If there are multiple Invariant Sections with the same name
   4707       1.1  mrg      but different contents, make the title of each such section unique
   4708       1.1  mrg      by adding at the end of it, in parentheses, the name of the
   4709       1.1  mrg      original author or publisher of that section if known, or else a
   4710       1.1  mrg      unique number.  Make the same adjustment to the section titles in
   4711       1.1  mrg      the list of Invariant Sections in the license notice of the
   4712       1.1  mrg      combined work.
   4713       1.1  mrg 
   4714       1.1  mrg      In the combination, you must combine any sections Entitled
   4715       1.1  mrg      "History" in the various original documents, forming one section
   4716       1.1  mrg      Entitled "History"; likewise combine any sections Entitled
   4717       1.1  mrg      "Acknowledgements", and any sections Entitled "Dedications".  You
   4718       1.1  mrg      must delete all sections Entitled "Endorsements."
   4719       1.1  mrg 
   4720       1.1  mrg   6. COLLECTIONS OF DOCUMENTS
   4721       1.1  mrg 
   4722       1.1  mrg      You may make a collection consisting of the Document and other
   4723       1.1  mrg      documents released under this License, and replace the individual
   4724       1.1  mrg      copies of this License in the various documents with a single copy
   4725       1.1  mrg      that is included in the collection, provided that you follow the
   4726   1.1.1.8  mrg      rules of this License for verbatim copying of each of the documents
   4727   1.1.1.8  mrg      in all other respects.
   4728       1.1  mrg 
   4729       1.1  mrg      You may extract a single document from such a collection, and
   4730       1.1  mrg      distribute it individually under this License, provided you insert
   4731   1.1.1.8  mrg      a copy of this License into the extracted document, and follow this
   4732   1.1.1.8  mrg      License in all other respects regarding verbatim copying of that
   4733   1.1.1.8  mrg      document.
   4734       1.1  mrg 
   4735       1.1  mrg   7. AGGREGATION WITH INDEPENDENT WORKS
   4736       1.1  mrg 
   4737       1.1  mrg      A compilation of the Document or its derivatives with other
   4738   1.1.1.8  mrg      separate and independent documents or works, in or on a volume of a
   4739   1.1.1.8  mrg      storage or distribution medium, is called an "aggregate" if the
   4740       1.1  mrg      copyright resulting from the compilation is not used to limit the
   4741       1.1  mrg      legal rights of the compilation's users beyond what the individual
   4742       1.1  mrg      works permit.  When the Document is included in an aggregate, this
   4743       1.1  mrg      License does not apply to the other works in the aggregate which
   4744       1.1  mrg      are not themselves derivative works of the Document.
   4745       1.1  mrg 
   4746       1.1  mrg      If the Cover Text requirement of section 3 is applicable to these
   4747       1.1  mrg      copies of the Document, then if the Document is less than one half
   4748       1.1  mrg      of the entire aggregate, the Document's Cover Texts may be placed
   4749       1.1  mrg      on covers that bracket the Document within the aggregate, or the
   4750       1.1  mrg      electronic equivalent of covers if the Document is in electronic
   4751       1.1  mrg      form.  Otherwise they must appear on printed covers that bracket
   4752       1.1  mrg      the whole aggregate.
   4753       1.1  mrg 
   4754       1.1  mrg   8. TRANSLATION
   4755       1.1  mrg 
   4756       1.1  mrg      Translation is considered a kind of modification, so you may
   4757       1.1  mrg      distribute translations of the Document under the terms of section
   4758       1.1  mrg      4.  Replacing Invariant Sections with translations requires special
   4759       1.1  mrg      permission from their copyright holders, but you may include
   4760       1.1  mrg      translations of some or all Invariant Sections in addition to the
   4761       1.1  mrg      original versions of these Invariant Sections.  You may include a
   4762       1.1  mrg      translation of this License, and all the license notices in the
   4763       1.1  mrg      Document, and any Warranty Disclaimers, provided that you also
   4764       1.1  mrg      include the original English version of this License and the
   4765       1.1  mrg      original versions of those notices and disclaimers.  In case of a
   4766       1.1  mrg      disagreement between the translation and the original version of
   4767       1.1  mrg      this License or a notice or disclaimer, the original version will
   4768       1.1  mrg      prevail.
   4769       1.1  mrg 
   4770       1.1  mrg      If a section in the Document is Entitled "Acknowledgements",
   4771       1.1  mrg      "Dedications", or "History", the requirement (section 4) to
   4772       1.1  mrg      Preserve its Title (section 1) will typically require changing the
   4773       1.1  mrg      actual title.
   4774       1.1  mrg 
   4775       1.1  mrg   9. TERMINATION
   4776       1.1  mrg 
   4777       1.1  mrg      You may not copy, modify, sublicense, or distribute the Document
   4778   1.1.1.2  mrg      except as expressly provided under this License.  Any attempt
   4779   1.1.1.2  mrg      otherwise to copy, modify, sublicense, or distribute it is void,
   4780   1.1.1.2  mrg      and will automatically terminate your rights under this License.
   4781   1.1.1.2  mrg 
   4782   1.1.1.2  mrg      However, if you cease all violation of this License, then your
   4783   1.1.1.2  mrg      license from a particular copyright holder is reinstated (a)
   4784   1.1.1.8  mrg      provisionally, unless and until the copyright holder explicitly and
   4785   1.1.1.8  mrg      finally terminates your license, and (b) permanently, if the
   4786   1.1.1.2  mrg      copyright holder fails to notify you of the violation by some
   4787   1.1.1.2  mrg      reasonable means prior to 60 days after the cessation.
   4788   1.1.1.2  mrg 
   4789   1.1.1.2  mrg      Moreover, your license from a particular copyright holder is
   4790   1.1.1.2  mrg      reinstated permanently if the copyright holder notifies you of the
   4791   1.1.1.2  mrg      violation by some reasonable means, this is the first time you have
   4792   1.1.1.2  mrg      received notice of violation of this License (for any work) from
   4793   1.1.1.2  mrg      that copyright holder, and you cure the violation prior to 30 days
   4794   1.1.1.2  mrg      after your receipt of the notice.
   4795   1.1.1.2  mrg 
   4796   1.1.1.2  mrg      Termination of your rights under this section does not terminate
   4797   1.1.1.8  mrg      the licenses of parties who have received copies or rights from you
   4798   1.1.1.8  mrg      under this License.  If your rights have been terminated and not
   4799   1.1.1.8  mrg      permanently reinstated, receipt of a copy of some or all of the
   4800   1.1.1.8  mrg      same material does not give you any rights to use it.
   4801       1.1  mrg 
   4802   1.1.1.8  mrg   10. FUTURE REVISIONS OF THIS LICENSE
   4803       1.1  mrg 
   4804       1.1  mrg      The Free Software Foundation may publish new, revised versions of
   4805       1.1  mrg      the GNU Free Documentation License from time to time.  Such new
   4806       1.1  mrg      versions will be similar in spirit to the present version, but may
   4807       1.1  mrg      differ in detail to address new problems or concerns.  See
   4808   1.1.1.8  mrg      <http://www.gnu.org/copyleft/>.
   4809       1.1  mrg 
   4810       1.1  mrg      Each version of the License is given a distinguishing version
   4811       1.1  mrg      number.  If the Document specifies that a particular numbered
   4812       1.1  mrg      version of this License "or any later version" applies to it, you
   4813       1.1  mrg      have the option of following the terms and conditions either of
   4814       1.1  mrg      that specified version or of any later version that has been
   4815   1.1.1.8  mrg      published (not as a draft) by the Free Software Foundation.  If the
   4816   1.1.1.8  mrg      Document does not specify a version number of this License, you may
   4817   1.1.1.8  mrg      choose any version ever published (not as a draft) by the Free
   4818   1.1.1.8  mrg      Software Foundation.  If the Document specifies that a proxy can
   4819   1.1.1.8  mrg      decide which future versions of this License can be used, that
   4820   1.1.1.2  mrg      proxy's public statement of acceptance of a version permanently
   4821   1.1.1.2  mrg      authorizes you to choose that version for the Document.
   4822   1.1.1.2  mrg 
   4823   1.1.1.8  mrg   11. RELICENSING
   4824   1.1.1.2  mrg 
   4825   1.1.1.2  mrg      "Massive Multiauthor Collaboration Site" (or "MMC Site") means any
   4826   1.1.1.2  mrg      World Wide Web server that publishes copyrightable works and also
   4827   1.1.1.2  mrg      provides prominent facilities for anybody to edit those works.  A
   4828   1.1.1.2  mrg      public wiki that anybody can edit is an example of such a server.
   4829   1.1.1.2  mrg      A "Massive Multiauthor Collaboration" (or "MMC") contained in the
   4830   1.1.1.2  mrg      site means any set of copyrightable works thus published on the MMC
   4831   1.1.1.2  mrg      site.
   4832   1.1.1.2  mrg 
   4833   1.1.1.2  mrg      "CC-BY-SA" means the Creative Commons Attribution-Share Alike 3.0
   4834   1.1.1.2  mrg      license published by Creative Commons Corporation, a not-for-profit
   4835   1.1.1.2  mrg      corporation with a principal place of business in San Francisco,
   4836   1.1.1.2  mrg      California, as well as future copyleft versions of that license
   4837   1.1.1.2  mrg      published by that same organization.
   4838   1.1.1.2  mrg 
   4839   1.1.1.2  mrg      "Incorporate" means to publish or republish a Document, in whole or
   4840   1.1.1.2  mrg      in part, as part of another Document.
   4841   1.1.1.2  mrg 
   4842   1.1.1.2  mrg      An MMC is "eligible for relicensing" if it is licensed under this
   4843   1.1.1.2  mrg      License, and if all works that were first published under this
   4844   1.1.1.2  mrg      License somewhere other than this MMC, and subsequently
   4845   1.1.1.2  mrg      incorporated in whole or in part into the MMC, (1) had no cover
   4846   1.1.1.2  mrg      texts or invariant sections, and (2) were thus incorporated prior
   4847   1.1.1.2  mrg      to November 1, 2008.
   4848   1.1.1.2  mrg 
   4849   1.1.1.2  mrg      The operator of an MMC Site may republish an MMC contained in the
   4850   1.1.1.2  mrg      site under CC-BY-SA on the same site at any time before August 1,
   4851   1.1.1.2  mrg      2009, provided the MMC is eligible for relicensing.
   4852   1.1.1.2  mrg 
   4853       1.1  mrg ADDENDUM: How to use this License for your documents
   4854       1.1  mrg ====================================================
   4855       1.1  mrg 
   4856       1.1  mrg To use this License in a document you have written, include a copy of
   4857       1.1  mrg the License in the document and put the following copyright and license
   4858       1.1  mrg notices just after the title page:
   4859       1.1  mrg 
   4860       1.1  mrg        Copyright (C)  YEAR  YOUR NAME.
   4861       1.1  mrg        Permission is granted to copy, distribute and/or modify this document
   4862   1.1.1.2  mrg        under the terms of the GNU Free Documentation License, Version 1.3
   4863       1.1  mrg        or any later version published by the Free Software Foundation;
   4864       1.1  mrg        with no Invariant Sections, no Front-Cover Texts, and no Back-Cover
   4865       1.1  mrg        Texts.  A copy of the license is included in the section entitled ``GNU
   4866       1.1  mrg        Free Documentation License''.
   4867       1.1  mrg 
   4868       1.1  mrg    If you have Invariant Sections, Front-Cover Texts and Back-Cover
   4869   1.1.1.8  mrg Texts, replace the "with...Texts."  line with this:
   4870       1.1  mrg 
   4871       1.1  mrg          with the Invariant Sections being LIST THEIR TITLES, with
   4872       1.1  mrg          the Front-Cover Texts being LIST, and with the Back-Cover Texts
   4873       1.1  mrg          being LIST.
   4874       1.1  mrg 
   4875       1.1  mrg    If you have Invariant Sections without Cover Texts, or some other
   4876       1.1  mrg combination of the three, merge those two alternatives to suit the
   4877       1.1  mrg situation.
   4878       1.1  mrg 
   4879       1.1  mrg    If your document contains nontrivial examples of program code, we
   4880   1.1.1.8  mrg recommend releasing these examples in parallel under your choice of free
   4881   1.1.1.8  mrg software license, such as the GNU General Public License, to permit
   4882   1.1.1.8  mrg their use in free software.
   4883       1.1  mrg 
   4884       1.1  mrg 
   4885   1.1.1.2  mrg File: libgomp.info,  Node: Funding,  Next: Library Index,  Prev: GNU Free Documentation License,  Up: Top
   4886       1.1  mrg 
   4887       1.1  mrg Funding Free Software
   4888       1.1  mrg *********************
   4889       1.1  mrg 
   4890       1.1  mrg If you want to have more free software a few years from now, it makes
   4891       1.1  mrg sense for you to help encourage people to contribute funds for its
   4892       1.1  mrg development.  The most effective approach known is to encourage
   4893       1.1  mrg commercial redistributors to donate.
   4894       1.1  mrg 
   4895       1.1  mrg    Users of free software systems can boost the pace of development by
   4896       1.1  mrg encouraging for-a-fee distributors to donate part of their selling price
   4897       1.1  mrg to free software developers--the Free Software Foundation, and others.
   4898       1.1  mrg 
   4899       1.1  mrg    The way to convince distributors to do this is to demand it and
   4900       1.1  mrg expect it from them.  So when you compare distributors, judge them
   4901       1.1  mrg partly by how much they give to free software development.  Show
   4902       1.1  mrg distributors they must compete to be the one who gives the most.
   4903       1.1  mrg 
   4904       1.1  mrg    To make this approach work, you must insist on numbers that you can
   4905       1.1  mrg compare, such as, "We will donate ten dollars to the Frobnitz project
   4906       1.1  mrg for each disk sold."  Don't be satisfied with a vague promise, such as
   4907       1.1  mrg "A portion of the profits are donated," since it doesn't give a basis
   4908       1.1  mrg for comparison.
   4909       1.1  mrg 
   4910       1.1  mrg    Even a precise fraction "of the profits from this disk" is not very
   4911       1.1  mrg meaningful, since creative accounting and unrelated business decisions
   4912   1.1.1.8  mrg can greatly alter what fraction of the sales price counts as profit.  If
   4913   1.1.1.8  mrg the price you pay is $50, ten percent of the profit is probably less
   4914       1.1  mrg than a dollar; it might be a few cents, or nothing at all.
   4915       1.1  mrg 
   4916       1.1  mrg    Some redistributors do development work themselves.  This is useful
   4917       1.1  mrg too; but to keep everyone honest, you need to inquire how much they do,
   4918       1.1  mrg and what kind.  Some kinds of development make much more long-term
   4919       1.1  mrg difference than others.  For example, maintaining a separate version of
   4920       1.1  mrg a program contributes very little; maintaining the standard version of a
   4921       1.1  mrg program for the whole community contributes much.  Easy new ports
   4922       1.1  mrg contribute little, since someone else would surely do them; difficult
   4923   1.1.1.8  mrg ports such as adding a new CPU to the GNU Compiler Collection contribute
   4924   1.1.1.8  mrg more; major new features or packages contribute the most.
   4925       1.1  mrg 
   4926       1.1  mrg    By establishing the idea that supporting further development is "the
   4927       1.1  mrg proper thing to do" when distributing free software for a fee, we can
   4928       1.1  mrg assure a steady flow of resources into making more free software.
   4929       1.1  mrg 
   4930       1.1  mrg      Copyright (C) 1994 Free Software Foundation, Inc.
   4931       1.1  mrg      Verbatim copying and redistribution of this section is permitted
   4932       1.1  mrg      without royalty; alteration is not permitted.
   4933       1.1  mrg 
   4934       1.1  mrg 
   4935   1.1.1.2  mrg File: libgomp.info,  Node: Library Index,  Prev: Funding,  Up: Top
   4936       1.1  mrg 
   4937   1.1.1.2  mrg Library Index
   4938   1.1.1.2  mrg *************
   4939       1.1  mrg 
   4940       1.1  mrg [index]
   4941       1.1  mrg * Menu:
   4942       1.1  mrg 
   4943  1.1.1.10  mrg * acc_get_property:                      acc_get_property.      (line 6)
   4944  1.1.1.10  mrg * acc_get_property_string:               acc_get_property.      (line 6)
   4945   1.1.1.7  mrg * Environment Variable:                  OMP_CANCELLATION.      (line 6)
   4946   1.1.1.8  mrg * Environment Variable <1>:              OMP_DISPLAY_ENV.       (line 6)
   4947   1.1.1.8  mrg * Environment Variable <2>:              OMP_DEFAULT_DEVICE.    (line 6)
   4948   1.1.1.8  mrg * Environment Variable <3>:              OMP_DYNAMIC.           (line 6)
   4949   1.1.1.8  mrg * Environment Variable <4>:              OMP_MAX_ACTIVE_LEVELS. (line 6)
   4950   1.1.1.8  mrg * Environment Variable <5>:              OMP_MAX_TASK_PRIORITY. (line 6)
   4951   1.1.1.8  mrg * Environment Variable <6>:              OMP_NESTED.            (line 6)
   4952   1.1.1.8  mrg * Environment Variable <7>:              OMP_NUM_THREADS.       (line 6)
   4953   1.1.1.8  mrg * Environment Variable <8>:              OMP_PROC_BIND.         (line 6)
   4954   1.1.1.8  mrg * Environment Variable <9>:              OMP_PLACES.            (line 6)
   4955   1.1.1.8  mrg * Environment Variable <10>:             OMP_STACKSIZE.         (line 6)
   4956   1.1.1.8  mrg * Environment Variable <11>:             OMP_SCHEDULE.          (line 6)
   4957   1.1.1.8  mrg * Environment Variable <12>:             OMP_THREAD_LIMIT.      (line 6)
   4958   1.1.1.8  mrg * Environment Variable <13>:             OMP_WAIT_POLICY.       (line 6)
   4959   1.1.1.8  mrg * Environment Variable <14>:             GOMP_CPU_AFFINITY.     (line 6)
   4960   1.1.1.8  mrg * Environment Variable <15>:             GOMP_DEBUG.            (line 6)
   4961   1.1.1.8  mrg * Environment Variable <16>:             GOMP_STACKSIZE.        (line 6)
   4962   1.1.1.8  mrg * Environment Variable <17>:             GOMP_SPINCOUNT.        (line 6)
   4963   1.1.1.8  mrg * Environment Variable <18>:             GOMP_RTEMS_THREAD_POOLS.
   4964   1.1.1.5  mrg                                                                 (line 6)
   4965   1.1.1.8  mrg * FDL, GNU Free Documentation License:   GNU Free Documentation License.
   4966   1.1.1.6  mrg                                                                 (line 6)
   4967   1.1.1.7  mrg * Implementation specific setting:       OMP_NESTED.            (line 6)
   4968   1.1.1.8  mrg * Implementation specific setting <1>:   OMP_NUM_THREADS.       (line 6)
   4969   1.1.1.8  mrg * Implementation specific setting <2>:   OMP_SCHEDULE.          (line 6)
   4970   1.1.1.8  mrg * Implementation specific setting <3>:   GOMP_STACKSIZE.        (line 6)
   4971   1.1.1.8  mrg * Implementation specific setting <4>:   GOMP_SPINCOUNT.        (line 6)
   4972   1.1.1.8  mrg * Implementation specific setting <5>:   GOMP_RTEMS_THREAD_POOLS.
   4973   1.1.1.8  mrg                                                                 (line 6)
   4974       1.1  mrg * Introduction:                          Top.                   (line 6)
   4975       1.1  mrg 
   4976       1.1  mrg 
   4977       1.1  mrg 
   4978       1.1  mrg Tag Table:
   4979   1.1.1.8  mrg Node: Top2083
   4980  1.1.1.10  mrg Node: Enabling OpenMP4645
   4981  1.1.1.10  mrg Node: Runtime Library Routines5433
   4982  1.1.1.11  mrg Node: omp_get_active_level8511
   4983  1.1.1.11  mrg Node: omp_get_ancestor_thread_num9211
   4984  1.1.1.11  mrg Node: omp_get_cancellation10141
   4985  1.1.1.11  mrg Node: omp_get_default_device10955
   4986  1.1.1.11  mrg Node: omp_get_dynamic11631
   4987  1.1.1.11  mrg Node: omp_get_level12506
   4988  1.1.1.11  mrg Node: omp_get_max_active_levels13126
   4989  1.1.1.11  mrg Node: omp_get_max_task_priority13831
   4990  1.1.1.11  mrg Node: omp_get_max_threads14451
   4991  1.1.1.11  mrg Node: omp_get_nested15208
   4992  1.1.1.11  mrg Node: omp_get_num_devices16122
   4993  1.1.1.11  mrg Node: omp_get_num_procs16643
   4994  1.1.1.11  mrg Node: omp_get_num_teams17182
   4995  1.1.1.11  mrg Node: omp_get_num_threads17698
   4996  1.1.1.11  mrg Node: omp_get_proc_bind18787
   4997  1.1.1.11  mrg Node: omp_get_schedule19710
   4998  1.1.1.11  mrg Node: omp_get_team_num20664
   4999  1.1.1.11  mrg Node: omp_get_team_size21163
   5000  1.1.1.11  mrg Node: omp_get_thread_limit22123
   5001  1.1.1.11  mrg Node: omp_get_thread_num22742
   5002  1.1.1.11  mrg Node: omp_in_parallel23613
   5003  1.1.1.11  mrg Node: omp_in_final24262
   5004  1.1.1.11  mrg Node: omp_is_initial_device24936
   5005  1.1.1.11  mrg Node: omp_set_default_device25629
   5006  1.1.1.11  mrg Node: omp_set_dynamic26420
   5007  1.1.1.11  mrg Node: omp_set_max_active_levels27306
   5008  1.1.1.11  mrg Node: omp_set_nested28083
   5009  1.1.1.11  mrg Node: omp_set_num_threads28975
   5010  1.1.1.11  mrg Node: omp_set_schedule29843
   5011  1.1.1.11  mrg Node: omp_init_lock30924
   5012  1.1.1.11  mrg Node: omp_set_lock31577
   5013  1.1.1.11  mrg Node: omp_test_lock32432
   5014  1.1.1.11  mrg Node: omp_unset_lock33408
   5015  1.1.1.11  mrg Node: omp_destroy_lock34339
   5016  1.1.1.11  mrg Node: omp_init_nest_lock35016
   5017  1.1.1.11  mrg Node: omp_set_nest_lock35751
   5018  1.1.1.11  mrg Node: omp_test_nest_lock36666
   5019  1.1.1.11  mrg Node: omp_unset_nest_lock37693
   5020  1.1.1.11  mrg Node: omp_destroy_nest_lock38708
   5021  1.1.1.11  mrg Node: omp_get_wtick39459
   5022  1.1.1.11  mrg Node: omp_get_wtime40051
   5023  1.1.1.11  mrg Node: Environment Variables40827
   5024  1.1.1.11  mrg Node: OMP_CANCELLATION42398
   5025  1.1.1.11  mrg Node: OMP_DISPLAY_ENV42931
   5026  1.1.1.11  mrg Node: OMP_DEFAULT_DEVICE43634
   5027  1.1.1.11  mrg Node: OMP_DYNAMIC44414
   5028  1.1.1.11  mrg Node: OMP_MAX_ACTIVE_LEVELS45010
   5029  1.1.1.11  mrg Node: OMP_MAX_TASK_PRIORITY45660
   5030  1.1.1.11  mrg Node: OMP_NESTED46318
   5031  1.1.1.11  mrg Node: OMP_NUM_THREADS46923
   5032  1.1.1.11  mrg Node: OMP_PROC_BIND47611
   5033  1.1.1.11  mrg Node: OMP_PLACES48806
   5034  1.1.1.11  mrg Node: OMP_STACKSIZE50985
   5035  1.1.1.11  mrg Node: OMP_SCHEDULE51809
   5036  1.1.1.11  mrg Node: OMP_THREAD_LIMIT52507
   5037  1.1.1.11  mrg Node: OMP_WAIT_POLICY53107
   5038  1.1.1.11  mrg Node: GOMP_CPU_AFFINITY53799
   5039  1.1.1.11  mrg Node: GOMP_DEBUG55529
   5040  1.1.1.11  mrg Node: GOMP_STACKSIZE56036
   5041  1.1.1.11  mrg Node: GOMP_SPINCOUNT56867
   5042  1.1.1.11  mrg Node: GOMP_RTEMS_THREAD_POOLS58071
   5043  1.1.1.11  mrg Node: Enabling OpenACC60249
   5044  1.1.1.11  mrg Node: OpenACC Runtime Library Routines61150
   5045  1.1.1.11  mrg Node: acc_get_num_devices65431
   5046  1.1.1.11  mrg Node: acc_set_device_type66157
   5047  1.1.1.11  mrg Node: acc_get_device_type66921
   5048  1.1.1.11  mrg Node: acc_set_device_num67934
   5049  1.1.1.11  mrg Node: acc_get_device_num68751
   5050  1.1.1.11  mrg Node: acc_get_property69550
   5051  1.1.1.11  mrg Node: acc_async_test71773
   5052  1.1.1.11  mrg Node: acc_async_test_all72761
   5053  1.1.1.11  mrg Node: acc_wait73661
   5054  1.1.1.11  mrg Node: acc_wait_all74524
   5055  1.1.1.11  mrg Node: acc_wait_all_async75285
   5056  1.1.1.11  mrg Node: acc_wait_async76037
   5057  1.1.1.11  mrg Node: acc_init76745
   5058  1.1.1.11  mrg Node: acc_shutdown77390
   5059  1.1.1.11  mrg Node: acc_on_device78057
   5060  1.1.1.11  mrg Node: acc_malloc79061
   5061  1.1.1.11  mrg Node: acc_free79560
   5062  1.1.1.11  mrg Node: acc_copyin79987
   5063  1.1.1.11  mrg Node: acc_present_or_copyin81574
   5064  1.1.1.11  mrg Node: acc_create83352
   5065  1.1.1.11  mrg Node: acc_present_or_create84984
   5066  1.1.1.11  mrg Node: acc_copyout86770
   5067  1.1.1.11  mrg Node: acc_delete89074
   5068  1.1.1.11  mrg Node: acc_update_device91321
   5069  1.1.1.11  mrg Node: acc_update_self92895
   5070  1.1.1.11  mrg Node: acc_map_data94485
   5071  1.1.1.11  mrg Node: acc_unmap_data95170
   5072  1.1.1.11  mrg Node: acc_deviceptr95691
   5073  1.1.1.11  mrg Node: acc_hostptr96261
   5074  1.1.1.11  mrg Node: acc_is_present96825
   5075  1.1.1.11  mrg Node: acc_memcpy_to_device98352
   5076  1.1.1.11  mrg Node: acc_memcpy_from_device99015
   5077  1.1.1.11  mrg Node: acc_attach99682
   5078  1.1.1.11  mrg Node: acc_detach100329
   5079  1.1.1.11  mrg Node: acc_get_current_cuda_device101108
   5080  1.1.1.11  mrg Node: acc_get_current_cuda_context101693
   5081  1.1.1.11  mrg Node: acc_get_cuda_stream102293
   5082  1.1.1.11  mrg Node: acc_set_cuda_stream102884
   5083  1.1.1.11  mrg Node: acc_prof_register103555
   5084  1.1.1.11  mrg Node: acc_prof_unregister104114
   5085  1.1.1.11  mrg Node: acc_prof_lookup104681
   5086  1.1.1.11  mrg Node: acc_register_library105202
   5087  1.1.1.11  mrg Node: OpenACC Environment Variables105768
   5088  1.1.1.11  mrg Node: ACC_DEVICE_TYPE106340
   5089  1.1.1.11  mrg Node: ACC_DEVICE_NUM106576
   5090  1.1.1.11  mrg Node: ACC_PROFLIB106830
   5091  1.1.1.11  mrg Node: GCC_ACC_NOTIFY107161
   5092  1.1.1.11  mrg Node: CUDA Streams Usage107381
   5093  1.1.1.11  mrg Ref: CUDA Streams Usage-Footnote-1109282
   5094  1.1.1.11  mrg Node: OpenACC Library Interoperability109391
   5095  1.1.1.11  mrg Ref: OpenACC Library Interoperability-Footnote-1115759
   5096  1.1.1.11  mrg Ref: OpenACC Library Interoperability-Footnote-2116011
   5097  1.1.1.11  mrg Node: OpenACC Profiling Interface116219
   5098  1.1.1.11  mrg Node: The libgomp ABI126243
   5099  1.1.1.11  mrg Node: Implementing MASTER construct127096
   5100  1.1.1.11  mrg Node: Implementing CRITICAL construct127512
   5101  1.1.1.11  mrg Node: Implementing ATOMIC construct128253
   5102  1.1.1.11  mrg Node: Implementing FLUSH construct128736
   5103  1.1.1.11  mrg Node: Implementing BARRIER construct129009
   5104  1.1.1.11  mrg Node: Implementing THREADPRIVATE construct129280
   5105  1.1.1.11  mrg Node: Implementing PRIVATE clause129935
   5106  1.1.1.11  mrg Node: Implementing FIRSTPRIVATE LASTPRIVATE COPYIN and COPYPRIVATE clauses130518
   5107  1.1.1.11  mrg Node: Implementing REDUCTION clause131844
   5108  1.1.1.11  mrg Node: Implementing PARALLEL construct132403
   5109  1.1.1.11  mrg Node: Implementing FOR construct133662
   5110  1.1.1.11  mrg Node: Implementing ORDERED construct135662
   5111  1.1.1.11  mrg Node: Implementing SECTIONS construct135970
   5112  1.1.1.11  mrg Node: Implementing SINGLE construct136738
   5113  1.1.1.11  mrg Node: Implementing OpenACC's PARALLEL construct137452
   5114  1.1.1.11  mrg Node: Reporting Bugs137712
   5115  1.1.1.11  mrg Node: Copying138075
   5116  1.1.1.11  mrg Node: GNU Free Documentation License175621
   5117  1.1.1.11  mrg Node: Funding200744
   5118  1.1.1.11  mrg Node: Library Index203270
   5119       1.1  mrg 
   5120       1.1  mrg End Tag Table
   5121