P4 to Git Change 1279182 by asalmanp@asalmanp-ocl-stg-pal on 2016/06/13 15:10:34
SWDEV-79278 - [OpenCL][PAL][GFXIP9 Bring up] OCL GFXIP9 general development.Adding support for ASIC detection based on gfxLevel on PAL. For GFXIP9+, the Asic revision on PAL is Unknown and gfxLevel should be used for ASIC detection. ReviewBoardURL = http://ocltc.amd.com/reviews/r/10616/ Affected files ... ... //depot/stg/opencl/drivers/opencl/runtime/device/pal/paldefs.hpp#4 edit ... //depot/stg/opencl/drivers/opencl/runtime/device/pal/paldevice.cpp#9 edit ... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palprogram.cpp#6 edit ... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palsettings.cpp#4 edit
Этот коммит содержится в:
@@ -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";
|
||||
|
||||
@@ -637,7 +637,13 @@ Device::create(Pal::IDevice* device)
|
||||
ipLevel_ = properties().gfxLevel;
|
||||
|
||||
// Update HW info for the device
|
||||
hwInfo_ = &DeviceInfo[static_cast<uint>(properties().revision)];
|
||||
if (properties().revision == Pal::AsicRevision::Unknown) {
|
||||
hwInfo_ = &GfxIpDeviceInfo[static_cast<uint>(properties().gfxLevel)];
|
||||
}
|
||||
else {
|
||||
hwInfo_ = &DeviceInfo[static_cast<uint>(properties().revision)];
|
||||
}
|
||||
|
||||
|
||||
// Find the number of available engines
|
||||
numComputeEngines_ =
|
||||
|
||||
@@ -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;
|
||||
|
||||
@@ -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:
|
||||
|
||||
Ссылка в новой задаче
Block a user