From 09a507e8d0b982f671cd99a075ab15469a656d7c Mon Sep 17 00:00:00 2001 From: foreman Date: Fri, 19 Jan 2018 11:15:37 -0500 Subject: [PATCH] P4 to Git Change 1505681 by wchau@wchau_OCL_boltzmann on 2018/01/19 11:10:00 SWDEV-143191 - OpenCL Runtime Support for Vega20 BU in ROCm - add device info entry for Vega20 - modified Makefile.library to use Vega20's bitcode library Affected files ... ... //depot/stg/opencl/drivers/opencl/library/build/Makefile.library#63 edit ... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocdefs.hpp#15 edit ... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocdevice.cpp#81 edit [ROCm/clr commit: edb9746999a5a47f95ae003fd091eb9b425ec854] --- projects/clr/rocclr/runtime/device/rocm/rocdefs.hpp | 4 +++- projects/clr/rocclr/runtime/device/rocm/rocdevice.cpp | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/projects/clr/rocclr/runtime/device/rocm/rocdefs.hpp b/projects/clr/rocclr/runtime/device/rocm/rocdefs.hpp index 6c06a35b82..64a64cc15b 100644 --- a/projects/clr/rocclr/runtime/device/rocm/rocdefs.hpp +++ b/projects/clr/rocclr/runtime/device/rocm/rocdefs.hpp @@ -38,6 +38,7 @@ const HsaDeviceId HSA_VEGA10_ID = 9; const HsaDeviceId HSA_VEGA10_HBCC_ID = 10; const HsaDeviceId HSA_RAVEN_ID = 11; const HsaDeviceId HSA_VEGA12_ID = 12; +const HsaDeviceId HSA_VEGA20_ID = 13; const HsaDeviceId HSA_INVALID_DEVICE_ID = -1; static const AMDDeviceInfo DeviceInfo[] = { @@ -60,7 +61,8 @@ static const AMDDeviceInfo DeviceInfo[] = { /* TARGET VEGA10 */ {HSA_VEGA10_ID, "", "gfx900", "gfx900", 4, 16, 1, 256, 64 * Ki, 32, 0, 0}, /* TARGET VEGA10_HBCC */ {HSA_VEGA10_HBCC_ID, "", "gfx901", "gfx901", 4, 16, 1, 256, 64 * Ki, 32, 0, 0}, /* TARGET RAVEN */ {HSA_RAVEN_ID, "", "gfx902", "gfx902", 4, 16, 1, 256, 64 * Ki, 32, 0, 0}, - /* TARGET VEGA12 */ {HSA_VEGA12_ID, "", "gfx904", "gfx904", 4, 16, 1, 256, 64 * Ki, 32, 0, 0}}; + /* TARGET VEGA12 */ {HSA_VEGA12_ID, "", "gfx904", "gfx904", 4, 16, 1, 256, 64 * Ki, 32, 0, 0}, + /* TARGET VEGA20 */ {HSA_VEGA20_ID, "", "gfx906", "gfx906", 4, 16, 1, 256, 64 * Ki, 32, 0, 0}}; } const uint kMaxAsyncQueues = 8; // set to match the number of pipes, which is 8 diff --git a/projects/clr/rocclr/runtime/device/rocm/rocdevice.cpp b/projects/clr/rocclr/runtime/device/rocm/rocdevice.cpp index c274f6156e..24bcb1cbc9 100644 --- a/projects/clr/rocclr/runtime/device/rocm/rocdevice.cpp +++ b/projects/clr/rocclr/runtime/device/rocm/rocdevice.cpp @@ -92,6 +92,8 @@ static HsaDeviceId getHsaDeviceId(hsa_agent_t device, uint32_t& pci_id) { return HSA_RAVEN_ID; case 904: return HSA_VEGA12_ID; + case 906: + return HSA_VEGA20_ID; default: return HSA_INVALID_DEVICE_ID; }