summaryrefslogtreecommitdiffstats
path: root/openmp/runtime/src/include/30
Commit message (Collapse)AuthorAgeFilesLines
* [OpenMP] Remove OMP spec versioningJonathan Peyton2019-07-124-1819/+0
| | | | | | | | | | Remove all older OMP spec versioning from the runtime and build system. Patch by Terry Wilmarth Differential Revision: https://reviews.llvm.org/D64534 llvm-svn: 365963
* Update more file headers across all of the LLVM projects in the monorepoChandler Carruth2019-01-194-16/+12
| | | | | | | | | | | | | | | | | | to reflect the new license. These used slightly different spellings that defeated my regular expressions. We understand that people may be surprised that we're moving the header entirely to discuss the new license. We checked this carefully with the Foundation's lawyer and we believe this is the correct approach. Essentially, all code in the project is now made available by the LLVM project under our new license, so you will see that the license headers include that license only. Some of our contributors have contributed code under our old license, and accordingly, we have retained a copy of our old license notice in the top-level files in each project and repository. llvm-svn: 351648
* Restrict OMPT to OpenMP version 5.0 and remove old header filesJonathan Peyton2017-10-201-488/+0
| | | | | | | | Patch by Simon Convent Differential Revision: https://reviews.llvm.org/D38876 llvm-svn: 316234
* Remove trailing whitespace in src/ directoryJonathan Peyton2016-05-201-1/+1
| | | | | | This patch doesn't affect D19878's context. So D19878 still cleanly applies. llvm-svn: 270252
* Adding new kmp_aligned_malloc() entry pointJonathan Peyton2016-05-124-0/+30
| | | | | | | | | | | | | This change adds a new entry point, kmp_aligned_malloc(size_t size, size_t alignment), an entry point corresponding to kmp_malloc() but with the capability to return aligned memory as well. Other allocator routines have been adjusted so that kmp_free() can be used for freeing memory blocks allocated by any kmp_*alloc() routine, including the new kmp_aligned_malloc() routine. Differential Revision: http://reviews.llvm.org/D19814 llvm-svn: 269365
* [OMPT] Workaround clang failing with 'declare target'Jonas Hahnfeld2016-01-281-2/+3
| | | | | | | | | | Current clang trunk reports _OPENMP to be 201307 = OpenMP 4.0. It doesn't recognize '#pragma omp declare target' though (patch still pending) and therefore fails compilation. Differential Revision: http://reviews.llvm.org/D16631 llvm-svn: 259026
* [OMPT] Add ompt_event_task_switch event into OMPT/OpenMPJonathan Peyton2015-11-111-4/+4
| | | | | | | | | | | | The patch adds support for ompt_event_task_switch into LLVM/OpenMP. Note that the patch has also updated the signature of ompt_event_task_switch to ompt_task_pair_callback_t (rather than the previous ompt_task_switch_callback_t). Patch by Harald Servat Differential Revision: http://reviews.llvm.org/D14566 llvm-svn: 252761
* [OMPT] Overhaul OMPT initialization interfaceJonathan Peyton2015-09-211-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | The OMPT specification has changed. This revision brings the LLVM OpenMP implementation up to date. Technical overview of changes: Previously, a public weak symbol ompt_initialize was called after the OpenMP runtime is initialized. The new interface calls a global weak symbol ompt_tool prior to initialization. If a tool is present, ompt_tool returns a pointer to a function that matches the signature for ompt_initialize. After OpenMP is initialized the function pointer is called to initialize a tool. Knowing that OMPT will be enabled before initialization allows OMPT support to be initialized as part of initialization instead of back patching initialization of OMPT support after the fact. Post OpenMP initialization support has been generalized moves from ompt-specific.c into ompt-general.c, since the OMPT initialization logic is no longer implementation specific. Patch by John Mellor-Crummey Differential Revision: http://reviews.llvm.org/D12998 llvm-svn: 248187
* Removing the Makefile/Perl build system.Jonathan Peyton2015-09-142-177/+0
| | | | | | | | | | | | This change deletes the Makefile+Perl build system and all files used by it which aren't used by the CMake build system. This included many Perl files, *.mk files, iomp* files. This change also updates the README's and index.html to instruct the user to use the CMake build system. All mentioning of the Perl+Makefile based system are removed. Differential Revision: http://reviews.llvm.org/D12331 llvm-svn: 247583
* [OpenMP] [CMake] Removing expand-vars.pl in favor of CMake's configure_file()Jonathan Peyton2015-08-284-19/+19
| | | | | | | | | | | | | | | | | | | Currently, the libomp CMake build system uses a Perl script to configure files (tools/expand-vars.pl). This patch replaces the use of the Perl script by using CMake's configure_file() function. The major changes include: 1. *.var has every $KMP_* variable changed to @LIBOMP_*@ 2. kmp_config.h.cmake is a new file which contains all the feature macros and #cmakedefine lines 3. Most of the -D lines have been moved from LibompDefinitions.cmake but some OS specific MACROs (e.g., _GNU_SOURCE) remain. 4. All expand-vars.pl related logic is removed from the CMake files. One important note about this change is that it breaks the old Perl+Makefile build system because it can't create kmp_config.h properly. Differential Review: http://reviews.llvm.org/D12211 llvm-svn: 246314
* Fix OMPT support for task frames, parallel regions, and parallel regions + loopsJonathan Peyton2015-07-211-2/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch makes it possible for a performance tool that uses call stack unwinding to map implementation-level call stacks from master and worker threads into a unified global view. There are several components to this patch. include/*/ompt.h.var Add a new enumeration type that indicates whether the code for a master task for a parallel region is invoked by the user program or the runtime system Change the signature for OMPT parallel begin/end callbacks to indicate whether the master task will be invoked by the program or the runtime system. This enables a performance tool using call stack unwinding to handle these two cases differently. For this case, a profiler that uses call stack unwinding needs to know that the call path prefix for the master task may differ from those available within the begin/end callbacks if the program invokes the master. kmp.h Change the signature for __kmp_join_call to take an additional parameter indicating the fork_context type. This is needed to supply the OMPT parallel end callback with information about whether the compiler or the runtime invoked the master task for a parallel region. kmp_csupport.c Ensure that the OMPT task frame field reenter_runtime_frame is properly set and cleared before and after calls to fork and join threads for a parallel region. Adjust the code for the new signature for __kmp_join_call. Adjust the OMPT parallel begin callback invocations to carry the extra parameter indicating whether the program or the runtime invokes the master task for a parallel region. kmp_gsupport.c Apply all of the analogous changes described for kmp_csupport.c for the GOMP interface Add OMPT support for the GOMP combined parallel region + loop API to maintain the OMPT task frame field reenter_runtime_frame. kmp_runtime.c: Use the new information passed by __kmp_join_call to adjust the OMPT parallel end callback invocations to carry the extra parameter indicating whether the program or the runtime invokes the master task for a parallel region. ompt_internal.h: Use the flavor of the parallel region API (GNU or Intel) to determine who invokes the master task. Differential Revision: http://reviews.llvm.org/D11259 llvm-svn: 242817
* Rename OMPT placeholder type names to be in the OMPT name spaceJonathan Peyton2015-07-141-5/+5
| | | | | | | | | | | | r242052 changed the name of OMPT placeholder functions to move them from the omp_ name space to the ompt_ name space. This patch moves the names of the types of these functions into the OMPT name space as well. Patch by John Mellor-Crummey Differential Revision: http://reviews.llvm.org/D11171 llvm-svn: 242155
* Fix some bugs in OMPT supportJonathan Peyton2015-07-131-5/+5
| | | | | | | | | | | | | | | | | | | | | | | 1.) in kmp_csupport.c, move computation of parameters only needed for OMPT tracing inside a conditional to reduce overhead if not receiving ompt_event_master_begin callbacks. 2.) in kmp_gsupport.c, remove spurious reset of OMPT reenter_runtime_frame (which is set in its caller, GOMP_parallel_start correct placement of #if OMP_TRACE so that state is maintained even if tracing support not included. 3.) in z_Linux_util.c, add architecture independent support for OMPT by setting and resetting OMPT's exit_frame_ptr before and after invoking a microtask. 4.) On the Intel MIC, the loader refuses to retain static symbols in the libomp.so shared library, even though tools need them. The loader could not be bullied into doing so. To accommodate this, I changed the visibility of OMPT placeholder functions to public. This required additions in exports.so.txt, adding extern "C" scoping in ompt-general.c so that the public placeholder symbols won't be mangled. Patch by John Mellor-Crummey Differential Revision: http://reviews.llvm.org/D11062 llvm-svn: 242052
* Added missed symbol omp_in_final into include/module files.Andrey Churbanov2015-05-063-0/+15
| | | | llvm-svn: 236619
* This patch contains the new files for OMPT and the needed changes to the ↵Andrey Churbanov2015-04-291-0/+472
| | | | | | build infrastructure llvm-svn: 236117
* Comments only: removing the Revision and Date svn variables from the top of ↵Andrey Churbanov2015-01-276-12/+0
| | | | | | all the source files. llvm-svn: 227207
* I apologise in advance for the size of this check-in. At Intel we doJim Cownie2014-10-076-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | understand that this is not friendly, and are working to change our internal code-development to make it easier to make development features available more frequently and in finer (more functional) chunks. Unfortunately we haven't got that in place yet, and unpicking this into multiple separate check-ins would be non-trivial, so please bear with me on this one. We should be better in the future. Apologies over, what do we have here? GGC 4.9 compatibility -------------------- * We have implemented the new entrypoints used by code compiled by GCC 4.9 to implement the same functionality in gcc 4.8. Therefore code compiled with gcc 4.9 that used to work will continue to do so. However, there are some other new entrypoints (associated with task cancellation) which are not implemented. Therefore user code compiled by gcc 4.9 that uses these new features will not link against the LLVM runtime. (It remains unclear how to handle those entrypoints, since the GCC interface has potentially unpleasant performance implications for join barriers even when cancellation is not used) --- new parallel entry points --- new entry points that aren't OpenMP 4.0 related These are implemented fully :- GOMP_parallel_loop_dynamic() GOMP_parallel_loop_guided() GOMP_parallel_loop_runtime() GOMP_parallel_loop_static() GOMP_parallel_sections() GOMP_parallel() --- cancellation entry points --- Currently, these only give a runtime error if OMP_CANCELLATION is true because our plain barriers don't check for cancellation while waiting GOMP_barrier_cancel() GOMP_cancel() GOMP_cancellation_point() GOMP_loop_end_cancel() GOMP_sections_end_cancel() --- taskgroup entry points --- These are implemented fully. GOMP_taskgroup_start() GOMP_taskgroup_end() --- target entry points --- These are empty (as they are in libgomp) GOMP_target() GOMP_target_data() GOMP_target_end_data() GOMP_target_update() GOMP_teams() Improvements in Barriers and Fork/Join -------------------------------------- * Barrier and fork/join code is now in its own file (which makes it easier to understand and modify). * Wait/release code is now templated and in its own file; suspend/resume code is also templated * There's a new, hierarchical, barrier, which exploits the cache-hierarchy of the Intel(r) Xeon Phi(tm) coprocessor to improve fork/join and barrier performance. ***BEWARE*** the new source files have *not* been added to the legacy Cmake build system. If you want to use that fixes wil be required. Statistics Collection Code -------------------------- * New code has been added to collect application statistics (if this is enabled at library compile time; by default it is not). The statistics code itself is generally useful, the lightweight timing code uses the X86 rdtsc instruction, so will require changes for other architectures. The intent of this code is not for users to tune their codes but rather 1) For timing code-paths inside the runtime 2) For gathering general properties of OpenMP codes to focus attention on which OpenMP features are most used. Nested Hot Teams ---------------- * The runtime now maintains more state to reduce the overhead of creating and destroying inner parallel teams. This improves the performance of code that repeatedly uses nested parallelism with the same resource allocation. Set the new KMP_HOT_TEAMS_MAX_LEVEL envirable to a depth to enable this (and, of course, OMP_NESTED=true to enable nested parallelism at all). Improved Intel(r) VTune(Tm) Amplifier support --------------------------------------------- * The runtime provides additional information to Vtune via the itt_notify interface to allow it to display better OpenMP specific analyses of load-imbalance. Support for OpenMP Composite Statements --------------------------------------- * Implement new entrypoints required by some of the OpenMP 4.1 composite statements. Improved ifdefs --------------- * More separation of concepts ("Does this platform do X?") from platforms ("Are we compiling for platform Y?"), which should simplify future porting. ScaleMP* contribution --------------------- Stack padding to improve the performance in their environment where cross-node coherency is managed at the page level. Redesign of wait and release code --------------------------------- The code is simplified and performance improved. Bug Fixes --------- *Fixes for Windows multiple processor groups. *Fix Fortran module build on Linux: offload attribute added. *Fix entry names for distribute-parallel-loop construct to be consistent with the compiler codegen. *Fix an inconsistent error message for KMP_PLACE_THREADS environment variable. llvm-svn: 219214
* First attempt to import OpenMP runtimeJim Cownie2013-09-276-0/+1967
llvm-svn: 191506
OpenPOWER on IntegriCloud