summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2016-12-14 18:35:12 +0100
committerMarek Olšák <[email protected]>2017-03-30 14:44:33 +0200
commit9338ab0afd0ab82a9077e11651c61424039bd12c (patch)
treedab47d311c4bee05551832403904bf7f2552c723 /src/gallium
parent68d6d097f15dbe17c1d0c8cb57157d9fd0005bdc (diff)
radeonsi/gfx9: set the LLVM processor, require LLVM 5.0
Reviewed-by: Nicolai Hähnle <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/drivers/radeon/r600_pipe_common.c2
-rw-r--r--src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c7
2 files changed, 9 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeon/r600_pipe_common.c b/src/gallium/drivers/radeon/r600_pipe_common.c
index 7ec57031412..052054b421d 100644
--- a/src/gallium/drivers/radeon/r600_pipe_common.c
+++ b/src/gallium/drivers/radeon/r600_pipe_common.c
@@ -952,6 +952,8 @@ const char *r600_get_llvm_processor_name(enum radeon_family family)
case CHIP_POLARIS11:
case CHIP_POLARIS12: /* same as polaris11 */
return HAVE_LLVM >= 0x0309 ? "polaris11" : "carrizo";
+ case CHIP_VEGA10:
+ return "gfx900";
default:
return "";
}
diff --git a/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c b/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
index 25f08ef0acd..4becd2a6818 100644
--- a/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
+++ b/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
@@ -232,6 +232,13 @@ static bool do_winsys_init(struct amdgpu_winsys *ws, int fd)
goto fail;
}
+ /* LLVM 5.0 is required for GFX9. */
+ if (ws->info.chip_class >= GFX9 && HAVE_LLVM < 0x0500) {
+ fprintf(stderr, "amdgpu: LLVM 5.0 is required, got LLVM %i.%i\n",
+ HAVE_LLVM >> 8, HAVE_LLVM & 255);
+ goto fail;
+ }
+
/* family and rev_id are for addrlib */
switch (ws->info.family) {
case CHIP_TAHITI: