summaryrefslogtreecommitdiffstats
path: root/openmp/runtime/test/tasking
Commit message (Collapse)AuthorAgeFilesLines
* [OpenMP] NFC: Fix trivial typos in commentsKelvin Li2020-01-032-2/+2
| | | | | | Submitted by: kiszk Differential Revision: https://reviews.llvm.org/D72171
* [openmp] [test] Skip one more test that kills NetBSD buildbotMichał Górny2019-11-071-0/+3
|
* fixed test: eliminated race condition which might cause deadlockAndrey Churbanov2019-09-251-1/+1
| | | | llvm-svn: 372887
* Enable tasks dependencies hashmaps resizing.Andrey Churbanov2019-09-251-0/+38
| | | | | | | | Patch by viroulep (Philippe Virouleau) Differential Revision: https://reviews.llvm.org/D67447 llvm-svn: 372879
* Remove REQUIRES OMP spec version within lit testsJonathan Peyton2019-07-176-6/+0
| | | | | | | | This is a follow up patch to D64534 (r365963) which removed all OMP spec versioning within the OpenMP runtime codebase. This patch removes REQUIRES: openmp-x.y lines from lit tests. llvm-svn: 366341
* [OpenMP] Remove OMP spec versioningJonathan Peyton2019-07-121-1/+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
* Create a runtime option to disable task throttling.Andrey Churbanov2019-07-021-0/+60
| | | | | | | | Patch by viroulep (Philippe Virouleau) Differential Revision: https://reviews.llvm.org/D63196 llvm-svn: 364934
* New implementation of OpenMP 5.0 detached tasks.Andrey Churbanov2019-06-193-0/+367
| | | | | | | | Patch by Alex Duran Differential Revision: https://reviews.llvm.org/D62485 llvm-svn: 363799
* [openmp] [test] Skip kernel-breaking tests on NetBSDMichal Gorny2019-05-282-0/+10
| | | | | | | | | The omp_taskloop_num_tasks and omp_taskwait have deadlooped on the NetBSD buildbot previously, practically hanging the host running it. Disable them until we can find a good solution, or make the kernel less fragile. llvm-svn: 361825
* [OpenMP] Implement task modifier for reduction clauseJonathan Peyton2019-05-014-0/+414
| | | | | | | | | | | | | | | | | Implemented task modifier in two versions - one without taking into account omp_orig variable (the omp_orig still can be processed by compiler without help of the library, but each reduction object will need separate initializer with global access to omp_orig), another with omp_orig variable included into interface (single initializer can be used for multiple reduction objects of the same type). Second version can be used when the omp_orig is not globally accessible, or to optimize code in case of multiple reduction objects of the same type. Patch by Andrey Churbanov Differential Revision: https://reviews.llvm.org/D60976 llvm-svn: 359710
* Ensure correct pthread flags and libraries are usedDimitry Andric2019-04-032-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | On most platforms, certain compiler and linker flags have to be passed when using pthreads, otherwise linking against libomp.so might fail with undefined references to several pthread functions. Use CMake's `find_package(Threads)` to determine these for standalone builds, or take them (and optionally modify them) from the top-level LLVM cmake files. Also, On FreeBSD, ensure that libomp.so is linked against libm.so, similar to NetBSD. Adjust test cases with hardcoded `-lpthread` flag to use the common build flags, which should now have the required pthread flags. Reviewers: emaste, jlpeyton, krytarowski, mgorny, protze.joachim, Hahnfeld Reviewed By: Hahnfeld Subscribers: AndreyChurbanov, tra, EricWF, Hahnfeld, jfb, jdoerfert, openmp-commits Tags: #openmp Differential Revision: https://reviews.llvm.org/D59451 llvm-svn: 357618
* [OpenMP] Fixes for LIBOMP_OMP_VERSION=45/40Roman Lebedev2018-12-157-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: I have discovered this because i wanted to experiment with building static libomp (with openmp-4.0 support only) for debugging purposes. There are three kinds of problems here: 1. `__kmp_compare_and_store_acq()` simply does not exist. It was added in D47903 by @jlpeyton. I'm guessing `__kmp_atomic_compare_store_acq()` was meant. 2. In `__kmp_is_ticket_lock_initialized()`, `lck->lk.initialized` is `std::atomic<bool>`, while `lck` is `kmp_ticket_lock_t *`. Naturally, they can't be equality-compared. Either, it should return the value read from `lck->lk.initialized`, or do what `__kmp_is_queuing_lock_initialized()` does, compare the passed pointer with the field in the struct pointed by the pointer. I think the latter is correct-er choice here. 3. Tests were not versioned. They assume that `LIBOMP_OMP_VERSION` is at the latest version. This does not touch LIBOMP_OMP_VERSION=30. That is still broken. Reviewers: jlpeyton, Hahnfeld, AndreyChurbanov Reviewed By: AndreyChurbanov Subscribers: guansong, jfb, openmp-commits, jlpeyton Tags: #openmp Differential Revision: https://reviews.llvm.org/D55496 llvm-svn: 349260
* Fix for bugzilla https://bugs.llvm.org/show_bug.cgi?id=39970Andrey Churbanov2018-12-132-0/+6
| | | | | | | | Broken tests fixed Differential Revision: https://reviews.llvm.org/D55598 llvm-svn: 349017
* Implementation of OpenMP 5.0 mutexinoutset task dependency type.Andrey Churbanov2018-11-072-0/+307
| | | | | | Differential Revision: https://reviews.llvm.org/D53380 llvm-svn: 346307
* [tests] Add annotations for taskloop featuresJonas Hahnfeld2018-08-022-0/+10
| | | | | | | | | Only supported since GCC 6 and Intel 17.0. However GCC 6.3.0 is crashing on two of the tests, so disable them as well... Differential Revision: https://reviews.llvm.org/D50085 llvm-svn: 338720
* [test] Convert test for PR36720 to c89Jonas Hahnfeld2018-08-011-2/+4
| | | | | | | | | GCC 4.8.5 defaults to this old C standard. I think we should make the tests pass a newer -std=c99|c11 but that's too intrusive for now... Differential Revision: https://reviews.llvm.org/D50084 llvm-svn: 338490
* [OpenMP] Fix tasking + parallel bugJonathan Peyton2018-07-301-0/+34
| | | | | | | | | | | | From the bug report, the runtime needs to initialize the nproc variables (inside middle init) for each root when the task is encountered, otherwise, a segfault can occur. Bugzilla: https://bugs.llvm.org/show_bug.cgi?id=36720 Differential Revision: https://reviews.llvm.org/D49996 llvm-svn: 338313
* Introduce GOMP_taskloop APIJonathan Peyton2018-04-182-4/+0
| | | | | | | | | | | | | | | This patch introduces GOMP_taskloop to our API. It adds GOMP_4.5 to our version symbols. Being a wrapper around __kmpc_taskloop, the function creates a task with the loop bounds properly nested in the shareds so that the GOMP task thunk will work properly. Also, the firstprivate copy constructors are properly handled using the __kmp_gomp_task_dup() auxiliary function. Currently, only linear spawning of tasks is supported for the GOMP_taskloop interface. Differential Revision: https://reviews.llvm.org/D45327 llvm-svn: 330282
* [CMake] Detect information about test compilerJonas Hahnfeld2017-11-301-0/+2
| | | | | | | | | | | | Perform a nested CMake invocation to avoid writing our own parser for compiler versions when we are not testing the in-tree compiler. Use the extracted information to mark a test as unsupported that hangs with Clang prior to version 4.0.1 and restrict tests for libomptarget to Clang version 6.0.0 and later. Differential Revision: https://reviews.llvm.org/D40083 llvm-svn: 319448
* Add C++ support for testcasesJonathan Peyton2017-10-201-2/+2
| | | | | | | | Patch by Simon Convent Differential Revision: https://reviews.llvm.org/D38878 llvm-svn: 316230
* [test] Fix uninitialized memory in omp_taskloop_grainsize.cJonas Hahnfeld2017-09-291-1/+2
| | | | | | result was never initialized to zero which sometimes failed the test. llvm-svn: 314513
* Fix failing taskloop tests by omitting gccJonathan Peyton2017-07-182-0/+4
| | | | | | We do not have GOMP interface support for taskloop yet. llvm-svn: 308351
* Add recursive task scheduling strategy to taskloop implementationJonathan Peyton2017-07-183-0/+174
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Taskloop implementation is extended by using recursive task scheduling. Envirable KMP_TASKLOOP_MIN_TASKS added as a manual threshold for the user to switch from recursive to linear tasks scheduling. Details: * The calculations for the loop parameters are moved from __kmp_taskloop_linear upper level * Initial calculation is done in the __kmpc_taskloop, further range splitting is done in the __kmp_taskloop_recur. * Added threshold to switch from recursive to linear tasks scheduling; * One half of split range is scheduled as an internal task which just moves sub-range parameters to the stealing thread that continues recursive scheduling (if number of tasks still enough), the other half is processed recursively; * Internal task duplication routine fixed to assign parent task, that was not needed when all tasks were scheduled by same thread, but is needed now. Patch by Andrey Churbanov Differential Revision: https://reviews.llvm.org/D35273 llvm-svn: 308338
* Run-time library part of OpenMP 5.0 task reduction implementation.Andrey Churbanov2017-02-161-0/+374
| | | | | | | | | Added test kmp_task_reduction_nest.cpp which has an example of possible compiler codegen. Differential Revision: https://reviews.llvm.org/D29600 llvm-svn: 295343
* Correct wrong comment in bug_nested_proxy_task.cJonas Hahnfeld2017-01-301-1/+1
| | | | | | The nested proxy task does not have dependencies. llvm-svn: 293472
* kmp_gsupport: Fix library initialization with taskgroupJonas Hahnfeld2016-08-081-0/+16
| | | | | | Differential Revision: https://reviews.llvm.org/D23259 llvm-svn: 278003
* Mark tests with task dependencies as unsupported with GCCJonas Hahnfeld2016-08-082-0/+6
| | | | llvm-svn: 277996
* Do not block on explicit task depending on proxy taskJonas Hahnfeld2016-08-081-0/+131
| | | | | | | | | | | | | | | | | | | | | | Consider the following code: int dep; #pragma omp target nowait depend(out: dep) { sleep(1); } #pragma omp task depend(in: dep) { printf("Task with dependency\n"); } printf("Doing some work...\n"); In its current state the runtime will block on the second task and not continue execution. Differential Revision: https://reviews.llvm.org/D23116 llvm-svn: 277992
* __kmp_free_task: Fix for serial explicit tasks producing proxy tasksJonas Hahnfeld2016-08-081-0/+128
| | | | | | | | | | | | | | | | | | | | | | | | | | | Consider the following code which may be executed by a serial team: int dep; #pragma omp target nowait depend(out: dep) { sleep(1); } #pragma omp task depend(in: dep) { #pragma omp target nowait { sleep(1); } } Here the explicit task may not be freed until the nested proxy task has finished. The current code hasn't considered this and called __kmp_free_task anyway which triggered an assert because of remaining incomplete children: KMP_DEBUG_ASSERT( TCR_4(taskdata->td_incomplete_child_tasks) == 0 ); Differential Revision: https://reviews.llvm.org/D23115 llvm-svn: 277991
* Add test case for nested creation of tasksJonas Hahnfeld2016-08-041-0/+35
| | | | | | For discussion in D23115 llvm-svn: 277730
* Bug fix for hang when tasks used in nested parallelJonathan Peyton2016-06-211-0/+32
| | | | | | | | | | | | Bug fix for hang when omp task and nested parallelism used together. Still some problem remains with task state saving/restoring, but user's case works fine now. All tasking unit tests passed as well. Patch by Andrey Churbanov Differential Revision: http://reviews.llvm.org/D21558 llvm-svn: 273297
* Remove trailing whitespace from testsJonathan Peyton2016-05-177-13/+13
| | | | llvm-svn: 269841
* Add new OpenMP 4.5 taskloop construct featureJonathan Peyton2016-03-021-0/+158
| | | | | | | | | | | | | | | | | | From the standard: The taskloop construct specifies that the iterations of one or more associated loops will be executed in parallel using OpenMP tasks. The iterations are distributed across tasks created by the construct and scheduled to be executed. This initial implementation uses a simple linear tasks distribution algorithm. Later we can add other algorithms to speedup generation of huge number of tasks (i.e., tree-like tasks generation should be faster). This needs to be put into the OpenMP runtime library in order for the compiler team to develop the compiler side of the implementation. Differential Revision: http://reviews.llvm.org/D17404 llvm-svn: 262535
* Forgot to add test files for doacross and task priority.Jonathan Peyton2016-03-021-0/+22
| | | | llvm-svn: 262533
* [OPENMP][TESTSUITE] Undefined variable in test omp_task_final.cJonathan Peyton2015-10-121-1/+1
| | | | | | | | Patch by Alexey Bataev Differential Revision: http://reviews.llvm.org/D13661 llvm-svn: 250066
* OpenMP Initial testsuite change to purely llvm-lit based testingJonathan Peyton2015-09-219-0/+484
This change introduces a check-libomp target which is based upon llvm's lit test infrastructure. Each test (generated from the University of Houston's OpenMP testsuite) is compiled and then run. For each test, an exit status of 0 indicates success and non-zero indicates failure. This way, FileCheck is not needed. I've added a bit of logic to generate symlinks (libiomp5 and libgomp) in the build tree so that gcc can be tested as well. When building out-of- tree builds, the user will have to provide llvm-lit either by specifying -DLIBOMP_LLVM_LIT_EXECUTABLE or having llvm-lit in their PATH. Differential Revision: http://reviews.llvm.org/D11821 llvm-svn: 248211
OpenPOWER on IntegriCloud