Changeset 3677 in CLRX


Ignore:
Timestamp:
Jan 29, 2018, 3:49:06 PM (2 years ago)
Author:
matszpk
Message:

CLRadeonExtender: ROCmBinGen: Use specific ROCm device version table.

Location:
CLRadeonExtender/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • CLRadeonExtender/trunk/CLRX/utils/GPUId.h

    r3575 r3677  
    189189{
    190190    AMDCL2 = 0, ///< AMD OpenCL 2.0 driver
    191     OPENSOURCE ///< ROCm and Gallium
     191    OPENSOURCE, ///< Gallium
     192    ROCM  ///< ROCm
    192193};
    193194
  • CLRadeonExtender/trunk/amdbin/ROCmBinaries.cpp

    r3673 r3677  
    313313{
    314314    AMDGPUArchVersion amdGpuArchValues = getGPUArchVersion(input->deviceType,
    315                 GPUArchVersionTable::OPENSOURCE);
     315                GPUArchVersionTable::ROCM);
    316316    if (input->archMinor!=UINT32_MAX)
    317317        amdGpuArchValues.minor = input->archMinor;
  • CLRadeonExtender/trunk/utils/GPUId.cpp

    r3657 r3677  
    319319}
    320320
    321 // AMD GPU architecture for Gallium and ROCm
     321// AMD GPU architecture for Gallium
    322322static const AMDGPUArchVersion galliumGpuArchVersionTbl[] =
    323323{
     
    352352};
    353353
     354// AMD GPU architecture for ROCm
     355static const AMDGPUArchVersion rocmGpuArchVersionTbl[] =
     356{
     357    { 0, 0, 0 }, // GPUDeviceType::CAPE_VERDE
     358    { 0, 0, 0 }, // GPUDeviceType::PITCAIRN
     359    { 0, 0, 0 }, // GPUDeviceType::TAHITI
     360    { 0, 0, 0 }, // GPUDeviceType::OLAND
     361    { 7, 0, 0 }, // GPUDeviceType::BONAIRE
     362    { 7, 0, 0 }, // GPUDeviceType::SPECTRE
     363    { 7, 0, 0 }, // GPUDeviceType::SPOOKY
     364    { 7, 0, 0 }, // GPUDeviceType::KALINDI
     365    { 0, 0, 0 }, // GPUDeviceType::HAINAN
     366    { 7, 0, 1 }, // GPUDeviceType::HAWAII
     367    { 8, 0, 0 }, // GPUDeviceType::ICELAND
     368    { 8, 0, 2 }, // GPUDeviceType::TONGA
     369    { 7, 0, 0 }, // GPUDeviceType::MULLINS
     370    { 8, 0, 3 }, // GPUDeviceType::FIJI
     371    { 8, 0, 1 }, // GPUDeviceType::CARRIZO
     372    { 8, 0, 1 }, // GPUDeviceType::DUMMY
     373    { 8, 0, 3 }, // GPUDeviceType::GOOSE
     374    { 8, 0, 3 }, // GPUDeviceType::HORSE
     375    { 8, 1, 0 }, // GPUDeviceType::STONEY
     376    { 8, 0, 3 }, // GPUDeviceType::ELLESMERE
     377    { 8, 0, 3 }, // GPUDeviceType::BAFFIN
     378    { 8, 0, 4 }, // GPUDeviceType::GFX804
     379    { 9, 0, 0 }, // GPUDeviceType::GFX900
     380    { 9, 0, 1 }, // GPUDeviceType::GFX901
     381    { 9, 0, 2 }, // GPUDeviceType::GFX902
     382    { 9, 0, 3 }, // GPUDeviceType::GFX903
     383    { 9, 0, 4 }, // GPUDeviceType::GFX904
     384    { 9, 0, 5 }  // GPUDeviceType::GFX905
     385};
     386
    354387// AMDGPU architecture values for specific GPU device type for AMDOCL 2.0
    355388static const AMDGPUArchVersion amdCL2GpuArchVersionTbl[] =
     
    391424    // choose correct GPU arch values table
    392425    const AMDGPUArchVersion* archValuesTable = (table == GPUArchVersionTable::AMDCL2) ?
    393             amdCL2GpuArchVersionTbl : galliumGpuArchVersionTbl;
     426            amdCL2GpuArchVersionTbl :
     427            ((table == GPUArchVersionTable::OPENSOURCE) ? galliumGpuArchVersionTbl :
     428            rocmGpuArchVersionTbl);
    394429    return archValuesTable[cxuint(deviceType)];
    395430}
Note: See TracChangeset for help on using the changeset viewer.