]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
OpenMP 5.0: requires directive: adjust libgomp HSA plugin
authorThomas Schwinge <thomas@codesourcery.com>
Wed, 3 Mar 2021 21:51:01 +0000 (22:51 +0100)
committerThomas Schwinge <thomas@codesourcery.com>
Thu, 25 Mar 2021 11:16:45 +0000 (12:16 +0100)
Fix-up for og10 commit c2e4a17adc0989f216c7fc3f93f150c66adba23a "OpenMP 5.0:
requires directive".

    libgomp: while loading libgomp-plugin-hsa.so.1: [...]/libgomp-plugin-hsa.so.1: undefined symbol: GOMP_OFFLOAD_supported_features

libgomp/
* plugin/plugin-hsa.c (GOMP_OFFLOAD_supported_features): New
function.

libgomp/ChangeLog.omp
libgomp/plugin/plugin-hsa.c

index 03ca74c8f3d5746919b1bc4a95534c2b8be25e4b..19f48dc61202c87ec040c846f44409de875cf8a8 100644 (file)
@@ -1,5 +1,8 @@
 2021-03-25  Thomas Schwinge  <thomas@codesourcery.com>
 
+       * plugin/plugin-hsa.c (GOMP_OFFLOAD_supported_features): New
+       function.
+
        * target.c (__requires_mask_table, __requires_mask_table_end): Add
        '__attribute__((weak))'.
 
index abd3bc64163bb864cb05f0809c93875e3e1b24c5..bddb690ca14fbde9c6608927e90e3d17fca926e6 100644 (file)
@@ -1869,3 +1869,11 @@ GOMP_OFFLOAD_dev2dev (int ord, void *dst, const void *src, size_t n)
                     "it should never be called");
   return false;
 }
+
+/* Indicate which GOMP_REQUIRES_* features are supported, currently none.  */
+
+bool
+GOMP_OFFLOAD_supported_features (unsigned int *mask)
+{
+  return (*mask == 0);
+}