On 13/01/2021 15:07, Chung-Lin Tang wrote:
We currently emit errors, but do not fatally cause exit of the program if those are not met. We're still unsure if complete block-out of program execution is the right
thing for the user. This can be discussed later.

After the Unified Shared Memory patches are committed, this patch will need to be altered as attached.

I'll commit my patch to OG11 shortly.

Andrew
libgomp, nvptx: report USM supported

libgomp/ChangeLog:

        * plugin/plugin-nvptx.c (GOMP_OFFLOAD_supported_features): Allow
        GOMP_REQUIRES_UNIFIED_ADDRESS and GOMP_REQUIRES_UNIFIED_SHARED_MEMORY.

diff --git a/libgomp/plugin/plugin-nvptx.c b/libgomp/plugin/plugin-nvptx.c
index dd490b2ae2a..e77c6a87930 100644
--- a/libgomp/plugin/plugin-nvptx.c
+++ b/libgomp/plugin/plugin-nvptx.c
@@ -1260,11 +1260,14 @@ GOMP_OFFLOAD_fini_device (int n)
   return true;
 }
 
-/* Indicate which GOMP_REQUIRES_* features are supported, currently none.  */
+/* Indicate which GOMP_REQUIRES_* features are supported.  */
 
 bool
 GOMP_OFFLOAD_supported_features (unsigned int *mask)
 {
+  *mask &= ~(GOMP_REQUIRES_UNIFIED_ADDRESS
+             | GOMP_REQUIRES_UNIFIED_SHARED_MEMORY);
+
   return (*mask == 0);
 }
 

Reply via email to