diff options
author | Tobias Burnus <tobias@codesourcery.com> | 2023-02-03 08:33:17 +0100 |
---|---|---|
committer | Tobias Burnus <tobias@codesourcery.com> | 2023-02-03 08:33:17 +0100 |
commit | f84fdb134dec02f68fd9a39a58e726023470e537 (patch) | |
tree | cc6126fdbca2cf1101e3b99647e0e39639d71b18 /libgomp/plugin | |
parent | 167b04b9b8a2becfd23b8ccf7f09016bbd013e12 (diff) | |
download | gcc-f84fdb134dec02f68fd9a39a58e726023470e537.zip gcc-f84fdb134dec02f68fd9a39a58e726023470e537.tar.gz gcc-f84fdb134dec02f68fd9a39a58e726023470e537.tar.bz2 |
libgomp: enable reverse offload for AMDGCN
libgomp/ChangeLog:
* libgomp.texi (5.0 Impl. Status, gcn specifics): Update for
reverse offload.
* plugin/plugin-gcn.c (GOMP_OFFLOAD_get_num_devices): Accept
reverse-offload requirement.
Diffstat (limited to 'libgomp/plugin')
-rw-r--r-- | libgomp/plugin/plugin-gcn.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libgomp/plugin/plugin-gcn.c b/libgomp/plugin/plugin-gcn.c index a7b3505..11ce6b0 100644 --- a/libgomp/plugin/plugin-gcn.c +++ b/libgomp/plugin/plugin-gcn.c @@ -3262,7 +3262,8 @@ GOMP_OFFLOAD_get_num_devices (unsigned int omp_requires_mask) return 0; /* Return -1 if no omp_requires_mask cannot be fulfilled but devices were present. */ - if (hsa_context.agent_count > 0 && omp_requires_mask != 0) + if (hsa_context.agent_count > 0 + && (omp_requires_mask & ~GOMP_REQUIRES_REVERSE_OFFLOAD) != 0) return -1; return hsa_context.agent_count; } |