diff options
author | Arpith Chacko Jacob <acjacob@us.ibm.com> | 2016-02-01 16:32:47 +0000 |
---|---|---|
committer | Arpith Chacko Jacob <acjacob@us.ibm.com> | 2016-02-01 16:32:47 +0000 |
commit | f1958627d9cc6fde9fba025af2ed4c1566d1da04 (patch) | |
tree | ac60309f7f96099c7df60a89283219a53bd8c7d8 /clang/test/OpenMP/target_messages.cpp | |
parent | 04bf91a8c1c6faaedf3f20dff6b795cc13e1071e (diff) | |
download | bcm5719-llvm-f1958627d9cc6fde9fba025af2ed4c1566d1da04.tar.gz bcm5719-llvm-f1958627d9cc6fde9fba025af2ed4c1566d1da04.zip |
[OpenMP] Prevent nesting of target constructs within target code execution regions.
Summary:
This patch enhances Sema to check for the following restriction:
OpenMP 4.5 [2.17 Nesting of Regions]
If a target, target update, target data, target enter data, or
target exit data construct is encountered during execution of a
target region, the behavior is unspecified.
Reviewers: ABataev
Differential Revision: http://reviews.llvm.org/D16758
llvm-svn: 259366
Diffstat (limited to 'clang/test/OpenMP/target_messages.cpp')
-rw-r--r-- | clang/test/OpenMP/target_messages.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/test/OpenMP/target_messages.cpp b/clang/test/OpenMP/target_messages.cpp index 86a91838ce0..361da5f3819 100644 --- a/clang/test/OpenMP/target_messages.cpp +++ b/clang/test/OpenMP/target_messages.cpp @@ -21,6 +21,7 @@ int main(int argc, char **argv) { #pragma omp target } // expected-warning {{extra tokens at the end of '#pragma omp target' are ignored}} foo(); #pragma omp target + foo(); // expected-warning@+1 {{extra tokens at the end of '#pragma omp target' are ignored}} #pragma omp target unknown() foo(); |