GCC with patches for OS216
修訂 | ca79a89b9b90bd76cd026898bfa2b8aaf8395e6e (tree) |
---|---|
時間 | 2020-06-27 06:23:05 |
作者 | Kwok Cheung Yeung <kcy@code...> |
Commiter | Kwok Cheung Yeung |
Fix failure in gfortran.dg/gomp/combined-if.f90 test
Enabling nvptx offloading results in extra '#pragma omp simd' statements
in the tree dump with an extra '_simt_'.
This is a backport from master
(commit 0fce12c0920c12492c878c0ca5f639f93b93f183).
2020-06-26 Kwok Cheung Yeung <kcy@codesourcery.com>
gcc/testsuite/
* gfortran.dg/gomp/combined-if.f90: Adjust expected number
of matches depending on whether nvptx offloading is supported.
* lib/target-supports.exp
(check_effective_target_offload_nvptx): New.
@@ -1,3 +1,10 @@ | ||
1 | +2020-06-26 Kwok Cheung Yeung <kcy@codesourcery.com> | |
2 | + | |
3 | + * gfortran.dg/gomp/combined-if.f90: Adjust expected number | |
4 | + of matches depending on whether nvptx offloading is supported. | |
5 | + * lib/target-supports.exp | |
6 | + (check_effective_target_offload_nvptx): New. | |
7 | + | |
1 | 8 | 2020-06-25 Tobias Burnus <tobias@codesourcery.com> |
2 | 9 | Kwok Cheung Yeung <kcy@codesourery.com> |
3 | 10 |
@@ -104,5 +104,6 @@ contains | ||
104 | 104 | end module |
105 | 105 | |
106 | 106 | ! { dg-final { scan-tree-dump-times "(?n)#pragma omp target.* if\\(" 9 "omplower" } } |
107 | -! { dg-final { scan-tree-dump-times "(?n)#pragma omp simd.* if\\(" 7 "omplower" } } | |
107 | +! { dg-final { scan-tree-dump-times "(?n)#pragma omp simd.* if\\(" 4 "omplower" { target { ! offload_nvptx } } } } | |
108 | +! { dg-final { scan-tree-dump-times "(?n)#pragma omp simd.* if\\(" 7 "omplower" { target { offload_nvptx } } } } | |
108 | 109 | ! { dg-final { scan-tree-dump-times "(?n)#pragma omp parallel.* if\\(" 6 "omplower" } } |
@@ -9754,6 +9754,14 @@ proc check_effective_target_vect_max_reduc { } { | ||
9754 | 9754 | return 0 |
9755 | 9755 | } |
9756 | 9756 | |
9757 | +# Return 1 if the compiler has been configured with nvptx offloading. | |
9758 | + | |
9759 | +proc check_effective_target_offload_nvptx { } { | |
9760 | + return [check_no_compiler_messages offload_nvptx assembly { | |
9761 | + int main () {return 0;} | |
9762 | + } "-foffload=nvptx-none" ] | |
9763 | +} | |
9764 | + | |
9757 | 9765 | # Return 1 if the compiler has been configured with hsa offloading. |
9758 | 9766 | |
9759 | 9767 | proc check_effective_target_offload_hsa { } { |
@@ -9762,7 +9770,7 @@ proc check_effective_target_offload_hsa { } { | ||
9762 | 9770 | } "-foffload=hsa" ] |
9763 | 9771 | } |
9764 | 9772 | |
9765 | -# Return 1 if the compiler has been configured with hsa offloading. | |
9773 | +# Return 1 if the compiler has been configured with gcn offloading. | |
9766 | 9774 | |
9767 | 9775 | proc check_effective_target_offload_gcn { } { |
9768 | 9776 | return [check_no_compiler_messages offload_gcn assembly { |