diff options
author | Tom de Vries <tdevries@suse.de> | 2022-04-01 12:14:47 +0200 |
---|---|---|
committer | Tom de Vries <tdevries@suse.de> | 2022-04-01 13:22:07 +0200 |
commit | 065e25f6331c130bc3cd2ce78036f2328adb3d71 (patch) | |
tree | b71accdd1bf796df5c1632d0097e15d08e16c385 /libgomp/testsuite/libgomp.oacc-c-c++-common | |
parent | 1e9c026848dd871266305d7e52292e0e10897f31 (diff) | |
download | gcc-065e25f6331c130bc3cd2ce78036f2328adb3d71.zip gcc-065e25f6331c130bc3cd2ce78036f2328adb3d71.tar.gz gcc-065e25f6331c130bc3cd2ce78036f2328adb3d71.tar.bz2 |
[libgomp, testsuite, nvptx] Fix dg-output test in vector-length-128-7.c
When running test-case libgomp.oacc-c-c++-common/vector-length-128-7.c on an
RTX A2000 (sm_86) with driver 510.60.02 I run into:
...
FAIL: libgomp.oacc-c/../libgomp.oacc-c-c++-common/vector-length-128-7.c \
-DACC_DEVICE_TYPE_nvidia=1 -DACC_MEM_SHARED=0 -foffload=nvptx-none -O0 \
output pattern test
...
The failing check verifies the launch dimensions:
...
/* { dg-output "nvptx_exec: kernel main\\\$_omp_fn\\\$0: \
launch gangs=1, workers=8, vectors=128" } */
...
which fails because (as we can see with GOMP_DEBUG=1) the actual num_workers
is 6:
...
nvptx_exec: kernel main$_omp_fn$0: launch gangs=1, workers=6, vectors=128
...
This is due to the result of cuOccupancyMaxPotentialBlockSize (which suggests
'a launch configuration with reasonable occupancy') printed just before:
...
cuOccupancyMaxPotentialBlockSize: grid = 52, block = 768
...
[ Note: 6 * 128 == 768. ]
Fix this by updating the check to allow num_workers in the range 1 to 8.
Tested on x86_64 with nvptx accelerator.
libgomp/ChangeLog:
2022-04-01 Tom de Vries <tdevries@suse.de>
* testsuite/libgomp.oacc-c-c++-common/vector-length-128-7.c: Fix
num_workers check.
Diffstat (limited to 'libgomp/testsuite/libgomp.oacc-c-c++-common')
-rw-r--r-- | libgomp/testsuite/libgomp.oacc-c-c++-common/vector-length-128-7.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/vector-length-128-7.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/vector-length-128-7.c index 4a8c1bf..92b3de0 100644 --- a/libgomp/testsuite/libgomp.oacc-c-c++-common/vector-length-128-7.c +++ b/libgomp/testsuite/libgomp.oacc-c-c++-common/vector-length-128-7.c @@ -37,4 +37,4 @@ main (void) } /* { dg-final { scan-offload-tree-dump "__attribute__\\(\\(oacc function \\(1, 0, 128\\)" "oaccloops" } } */ -/* { dg-output "nvptx_exec: kernel main\\\$_omp_fn\\\$0: launch gangs=1, workers=8, vectors=128" } */ +/* { dg-output "nvptx_exec: kernel main\\\$_omp_fn\\\$0: launch gangs=1, workers=\[1-8\], vectors=128" } */ |