diff options
author | Carlo Bertolli <cbertol@us.ibm.com> | 2017-02-17 21:29:13 +0000 |
---|---|---|
committer | Carlo Bertolli <cbertol@us.ibm.com> | 2017-02-17 21:29:13 +0000 |
commit | 8429d81202b1ccac43a9a4e88430afea8be1a101 (patch) | |
tree | 4ca7ee38234716d0948e848eea42a25a48b70038 /clang/lib/Basic/OpenMPKinds.cpp | |
parent | 996f9b4cade428d4a8819d04c51652a7ccfa5310 (diff) | |
download | bcm5719-llvm-8429d81202b1ccac43a9a4e88430afea8be1a101.tar.gz bcm5719-llvm-8429d81202b1ccac43a9a4e88430afea8be1a101.zip |
[OpenMP] Prepare Sema for initial implementation for pragma 'distribute parallel for'
https://reviews.llvm.org/D29922
This patch adds two fields for use in the implementation of 'distribute parallel for':
The increment expression for the distribute loop. As the chunk assigned to a team is executed by multiple threads within the 'parallel for' region, the increment expression has to correspond to the value returned by the related runtime call (for_static_init).
The upper bound of the innermost loop ('for' in 'distribute parallel for') is not the globalUB expression normally used for pragma 'for' when found in isolation. It is instead the upper bound of the chunk assigned to the team ('distribute' loop). In this way, we prevent teams from executing chunks assigned to other teams.
The use of these two fields can be see in a related explanatory patch:
https://reviews.llvm.org/D29508
llvm-svn: 295497
Diffstat (limited to 'clang/lib/Basic/OpenMPKinds.cpp')
-rw-r--r-- | clang/lib/Basic/OpenMPKinds.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Basic/OpenMPKinds.cpp b/clang/lib/Basic/OpenMPKinds.cpp index 12a4aea31fe..5a8bb61eaad 100644 --- a/clang/lib/Basic/OpenMPKinds.cpp +++ b/clang/lib/Basic/OpenMPKinds.cpp @@ -873,6 +873,7 @@ void clang::getOpenMPCaptureRegions( case OMPD_parallel_for: case OMPD_parallel_for_simd: case OMPD_parallel_sections: + case OMPD_distribute_parallel_for: CaptureRegions.push_back(OMPD_parallel); break; case OMPD_target_teams: @@ -902,7 +903,6 @@ void clang::getOpenMPCaptureRegions( case OMPD_taskloop_simd: case OMPD_distribute_parallel_for_simd: case OMPD_distribute_simd: - case OMPD_distribute_parallel_for: case OMPD_teams_distribute: case OMPD_teams_distribute_simd: case OMPD_teams_distribute_parallel_for_simd: |