diff options
author | Alexey Bataev <a.bataev@hotmail.com> | 2019-12-19 10:01:10 -0500 |
---|---|---|
committer | Alexey Bataev <a.bataev@hotmail.com> | 2019-12-23 10:04:46 -0500 |
commit | 0860db966a7d2ab61b26e41426a55189986924b4 (patch) | |
tree | d90f8ba8208077ca27a6ebc27db727c97bda583c /clang/test/OpenMP/for_simd_codegen.cpp | |
parent | e40ac74dacda99ff6330945f0f105252b7c28c9c (diff) | |
download | bcm5719-llvm-0860db966a7d2ab61b26e41426a55189986924b4.tar.gz bcm5719-llvm-0860db966a7d2ab61b26e41426a55189986924b4.zip |
[OPENMP50]Codegen for nontemporal clause.
Summary:
Basic codegen for the declarations marked as nontemporal. Also, if the
base declaration in the member expression is marked as nontemporal,
lvalue for member decl access inherits nonteporal flag from the base
lvalue.
Reviewers: rjmccall, hfinkel, jdoerfert
Subscribers: guansong, arphaman, caomhin, kkwli0, cfe-commits
Tags: #clang
Differential Revision: https://reviews.llvm.org/D71708
Diffstat (limited to 'clang/test/OpenMP/for_simd_codegen.cpp')
-rw-r--r-- | clang/test/OpenMP/for_simd_codegen.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/clang/test/OpenMP/for_simd_codegen.cpp b/clang/test/OpenMP/for_simd_codegen.cpp index 4bc6b362f02..a668cb77a06 100644 --- a/clang/test/OpenMP/for_simd_codegen.cpp +++ b/clang/test/OpenMP/for_simd_codegen.cpp @@ -333,7 +333,7 @@ void simple(float *a, float *b, float *c, float *d) { // OMP50: br i1 [[COND]], label {{%?}}[[THEN:[^,]+]], label {{%?}}[[ELSE:[^,]+]] // OMP50: [[THEN]]: #ifdef OMP5 - #pragma omp for simd reduction(*:R) if (simd:A) + #pragma omp for simd reduction(*:R) if (simd:A) nontemporal(R) #else #pragma omp for simd reduction(*:R) #endif @@ -366,7 +366,8 @@ void simple(float *a, float *b, float *c, float *d) { // CHECK-NEXT: [[LC_IT_2:%.+]] = add nsw i64 -10, [[LC_IT_1]] // CHECK-NEXT: store i64 [[LC_IT_2]], i64* [[LC:%[^,]+]], // CHECK-NEXT: [[LC_VAL:%.+]] = load i64, i64* [[LC]] -// CHECK: store i32 %{{.+}}, i32* [[R_PRIV]], +// OMP45: store i32 %{{.+}}, i32* [[R_PRIV]], +// OMP50: store i32 %{{.+}}, i32* [[R_PRIV]],{{.*}}!nontemporal R *= i; // CHECK: [[IV8_2:%.+]] = load i64, i64* [[OMP_IV8]] // CHECK-NEXT: [[ADD8_2:%.+]] = add nsw i64 [[IV8_2]], 1 |