diff --git a/rocclr/runtime/device/pal/paldefs.hpp b/rocclr/runtime/device/pal/paldefs.hpp index 72054005f8..fbdec58fb3 100644 --- a/rocclr/runtime/device/pal/paldefs.hpp +++ b/rocclr/runtime/device/pal/paldefs.hpp @@ -141,8 +141,17 @@ static const AMDDeviceInfo DeviceInfo[] = { /* Iceland */ { "Iceland", "iceland", 4, 16, 1, 256, 64 * Ki, 32, 800 }, /* Tonga */ { "Tonga", "tonga", 4, 16, 1, 256, 64 * Ki, 32, 800 }, /* Fiji */ { "Fiji", "fiji", 4, 16, 1, 256, 64 * Ki, 32, 800 }, -/* Ellesmere */ { "Horse", "horse", 4, 16, 1, 256, 64 * Ki, 32, 800 }, -/* Buffin */ { "Goose", "goose", 4, 16, 1, 256, 64 * Ki, 32, 800 }, +/* Ellesmere */ { "Ellesmere", "ellesmere",4, 16, 1, 256, 64 * Ki, 32, 800 }, +/* Buffin */ { "Baffin", "baffin", 4, 16, 1, 256, 64 * Ki, 32, 800 }, +}; + +static const AMDDeviceInfo GfxIpDeviceInfo[] = { +/* Unknown */ { "", "unknown", 4, 16, 1, 256, 64 * Ki, 32, 000 }, +/* GFX6_0_0 */ { "GFX6_0_0", "gfx6_0_0", 4, 16, 1, 256, 64 * Ki, 32, 600 }, +/* GFX7_0_0 */ { "GFX7_0_0", "gfx7_0_0", 4, 16, 1, 256, 64 * Ki, 32, 700 }, +/* GFX8_0_0 */ { "GFX8_0_0", "gfx8_0_0", 4, 16, 1, 256, 64 * Ki, 32, 800 }, +/* GFX8_0_1 */ { "GFX8_0_1", "gfx8_0_1", 4, 16, 1, 256, 64 * Ki, 32, 801 }, +/* GFX9_0_0 */ { "", "", 4, 16, 1, 256, 64 * Ki, 32, 900 }, }; static const char* Gfx700 = "AMD:AMDGPU:7:0:0"; diff --git a/rocclr/runtime/device/pal/paldevice.cpp b/rocclr/runtime/device/pal/paldevice.cpp index 47a20ebbd9..30691785cf 100644 --- a/rocclr/runtime/device/pal/paldevice.cpp +++ b/rocclr/runtime/device/pal/paldevice.cpp @@ -637,7 +637,13 @@ Device::create(Pal::IDevice* device) ipLevel_ = properties().gfxLevel; // Update HW info for the device - hwInfo_ = &DeviceInfo[static_cast(properties().revision)]; + if (properties().revision == Pal::AsicRevision::Unknown) { + hwInfo_ = &GfxIpDeviceInfo[static_cast(properties().gfxLevel)]; + } + else { + hwInfo_ = &DeviceInfo[static_cast(properties().revision)]; + } + // Find the number of available engines numComputeEngines_ = diff --git a/rocclr/runtime/device/pal/palprogram.cpp b/rocclr/runtime/device/pal/palprogram.cpp index cc0fabd828..c985ae4e94 100644 --- a/rocclr/runtime/device/pal/palprogram.cpp +++ b/rocclr/runtime/device/pal/palprogram.cpp @@ -739,10 +739,9 @@ bool ORCAHSALoaderContext::IsaSupportedByAgent(hsa_agent_t agent, hsa_isa_t isa) return false; } case gfx900: - switch (program_->dev().properties().revision) { - case 0: -/* case Pal::AsicRevision::Greenland: - return isa.handle == gfx900 || isa.handle == gfx901;*/ + switch (program_->dev().properties().gfxLevel) { + case Pal::GfxIpLevel::GfxIp9: + return isa.handle == gfx900 || isa.handle == gfx901; default: assert(0); return false; diff --git a/rocclr/runtime/device/pal/palsettings.cpp b/rocclr/runtime/device/pal/palsettings.cpp index 86c5542fd4..e29b86741d 100644 --- a/rocclr/runtime/device/pal/palsettings.cpp +++ b/rocclr/runtime/device/pal/palsettings.cpp @@ -155,10 +155,15 @@ Settings::create( ModifyMaxWorkload modifyMaxWorkload = {0}; switch (palProp.revision) { -/* case Pal::AsicRevision::: - case CAL_TARGET_GREENLAND: - //TODO: specific codes for AI - aiPlus_ = true;*/ + case Pal::AsicRevision::Unknown: + switch (palProp.gfxLevel) { + case Pal::GfxIpLevel::GfxIp9: + aiPlus_ = true; + break; + default: + assert(0 && "Unknown GfxIP type!"); + return false; + } // Fall through to VI ... case Pal::AsicRevision::Carrizo: case Pal::AsicRevision::Stoney: