Import HSA header files from AMD

These are the same header files that exist in the Radeon Open Compute Runtime
project (as of October 2020), but they have been specially relicensed by AMD
for use in GCC.

The header files retain AMD copyright.

include/ChangeLog:

	* hsa.h: Replace whole file.
	* hsa_ext_amd.h: New file.
	* hsa_ext_image.h: New file.

libgomp/ChangeLog:

	* plugin/plugin-gcn.c: Include hsa_ext_amd.h.
	(HSA_AMD_AGENT_INFO_COMPUTE_UNIT_COUNT): Delete redundant definition.
This commit is contained in:
Andrew Stubbs 2020-11-23 16:27:59 +00:00
parent 42bdf81449
commit 85f0a4d982
4 changed files with 8969 additions and 553 deletions

File diff suppressed because it is too large Load Diff

1969
include/hsa_ext_amd.h Normal file

File diff suppressed because it is too large Load Diff

1440
include/hsa_ext_image.h Normal file

File diff suppressed because it is too large Load Diff

View File

@ -37,6 +37,7 @@
#include <stdbool.h>
#include <limits.h>
#include <hsa.h>
#include <hsa_ext_amd.h>
#include <dlfcn.h>
#include <signal.h>
#include "libgomp-plugin.h"
@ -46,11 +47,6 @@
#include "oacc-int.h"
#include <assert.h>
/* Additional definitions not in HSA 1.1.
FIXME: this needs to be updated in hsa.h for upstream, but the only source
right now is the ROCr source which may cause license issues. */
#define HSA_AMD_AGENT_INFO_COMPUTE_UNIT_COUNT 0xA002
/* These probably won't be in elf.h for a while. */
#ifndef R_AMDGPU_NONE
#define R_AMDGPU_NONE 0