diff options
author | Thomas Schwinge <thomas@codesourcery.com> | 2019-02-22 11:50:49 +0100 |
---|---|---|
committer | Thomas Schwinge <tschwinge@gcc.gnu.org> | 2019-02-22 11:50:49 +0100 |
commit | 1241136c71bc1bf67b1df59f965ad5d50a613b4e (patch) | |
tree | f3e5c383f4e173702f09e518e4acdb4918a15d9a /libgomp | |
parent | 68034b1bc2058fd3c78b0f583e718e8443346580 (diff) | |
download | gcc-1241136c71bc1bf67b1df59f965ad5d50a613b4e.zip gcc-1241136c71bc1bf67b1df59f965ad5d50a613b4e.tar.gz gcc-1241136c71bc1bf67b1df59f965ad5d50a613b4e.tar.bz2 |
[libgomp] In OpenACC offloading testing, be more explicit in what is supported, and what is not, or why not
libgomp/
* testsuite/lib/libgomp.exp: Error out for unknown offload target.
* testsuite/libgomp.oacc-c++/c++.exp: Likewise. Report if
"offloading: supported, but hardware not accessible".
* testsuite/libgomp.oacc-c/c.exp: Likewise.
* testsuite/libgomp.oacc-fortran/fortran.exp: Likewise.
From-SVN: r269106
Diffstat (limited to 'libgomp')
-rw-r--r-- | libgomp/ChangeLog | 8 | ||||
-rw-r--r-- | libgomp/testsuite/lib/libgomp.exp | 7 | ||||
-rw-r--r-- | libgomp/testsuite/libgomp.oacc-c++/c++.exp | 4 | ||||
-rw-r--r-- | libgomp/testsuite/libgomp.oacc-c/c.exp | 4 | ||||
-rw-r--r-- | libgomp/testsuite/libgomp.oacc-fortran/fortran.exp | 4 |
5 files changed, 19 insertions, 8 deletions
diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog index f310c2f..32bc21f 100644 --- a/libgomp/ChangeLog +++ b/libgomp/ChangeLog @@ -1,3 +1,11 @@ +2019-02-22 Thomas Schwinge <thomas@codesourcery.com> + + * testsuite/lib/libgomp.exp: Error out for unknown offload target. + * testsuite/libgomp.oacc-c++/c++.exp: Likewise. Report if + "offloading: supported, but hardware not accessible". + * testsuite/libgomp.oacc-c/c.exp: Likewise. + * testsuite/libgomp.oacc-fortran/fortran.exp: Likewise. + 2019-02-19 Chung-Lin Tang <cltang@codesourcery.com> PR c/87924 diff --git a/libgomp/testsuite/lib/libgomp.exp b/libgomp/testsuite/lib/libgomp.exp index 04738a9..2392642 100644 --- a/libgomp/testsuite/lib/libgomp.exp +++ b/libgomp/testsuite/lib/libgomp.exp @@ -58,6 +58,9 @@ foreach offload_target_openacc $offload_targets_s { hsa { continue } + default { + error "Unknown offload target: $offload_target_openacc" + } } lappend offload_targets_s_openacc "$offload_target_openacc" } @@ -375,7 +378,7 @@ proc check_effective_target_openacc_nvidia_accel_configured { } { return [is-effective-target lp64] } -# Return 1 if at least one nvidia board is present. +# Return 1 if at least one Nvidia GPU is accessible. proc check_effective_target_openacc_nvidia_accel_present { } { return [check_runtime openacc_nvidia_accel_present { @@ -386,7 +389,7 @@ proc check_effective_target_openacc_nvidia_accel_present { } { } "" ] } -# Return 1 if at least one nvidia board is present, and the nvidia device type +# Return 1 if at least one Nvidia GPU is accessible, and the nvidia device type # is selected by default by means of setting the environment variable # ACC_DEVICE_TYPE. diff --git a/libgomp/testsuite/libgomp.oacc-c++/c++.exp b/libgomp/testsuite/libgomp.oacc-c++/c++.exp index 9beadd6..d0e5f42 100644 --- a/libgomp/testsuite/libgomp.oacc-c++/c++.exp +++ b/libgomp/testsuite/libgomp.oacc-c++/c++.exp @@ -88,7 +88,7 @@ if { $lang_test_file_found } { nvidia { if { ![check_effective_target_openacc_nvidia_accel_present] } { # Don't bother; execution testing is going to FAIL. - untested "$subdir $offload_target_openacc offloading" + untested "$subdir $offload_target_openacc offloading: supported, but hardware not accessible" continue } @@ -101,7 +101,7 @@ if { $lang_test_file_found } { set acc_mem_shared 0 } default { - set acc_mem_shared 0 + error "Unknown OpenACC device type: $offload_target_openacc" } } set tagopt "$tagopt -DACC_MEM_SHARED=$acc_mem_shared" diff --git a/libgomp/testsuite/libgomp.oacc-c/c.exp b/libgomp/testsuite/libgomp.oacc-c/c.exp index 4475bf5..77e852e 100644 --- a/libgomp/testsuite/libgomp.oacc-c/c.exp +++ b/libgomp/testsuite/libgomp.oacc-c/c.exp @@ -51,7 +51,7 @@ foreach offload_target_openacc $offload_targets_s_openacc { nvidia { if { ![check_effective_target_openacc_nvidia_accel_present] } { # Don't bother; execution testing is going to FAIL. - untested "$subdir $offload_target_openacc offloading" + untested "$subdir $offload_target_openacc offloading: supported, but hardware not accessible" continue } @@ -64,7 +64,7 @@ foreach offload_target_openacc $offload_targets_s_openacc { set acc_mem_shared 0 } default { - set acc_mem_shared 0 + error "Unknown OpenACC device type: $offload_target_openacc" } } set tagopt "$tagopt -DACC_MEM_SHARED=$acc_mem_shared" diff --git a/libgomp/testsuite/libgomp.oacc-fortran/fortran.exp b/libgomp/testsuite/libgomp.oacc-fortran/fortran.exp index 663c932..a262a8a 100644 --- a/libgomp/testsuite/libgomp.oacc-fortran/fortran.exp +++ b/libgomp/testsuite/libgomp.oacc-fortran/fortran.exp @@ -76,14 +76,14 @@ if { $lang_test_file_found } { nvidia { if { ![check_effective_target_openacc_nvidia_accel_present] } { # Don't bother; execution testing is going to FAIL. - untested "$subdir $offload_target_openacc offloading" + untested "$subdir $offload_target_openacc offloading: supported, but hardware not accessible" continue } set acc_mem_shared 0 } default { - set acc_mem_shared 0 + error "Unknown OpenACC device type: $offload_target_openacc" } } set tagopt "$tagopt -DACC_MEM_SHARED=$acc_mem_shared" |