mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-05 09:09:04 +08:00
Move hw_info files to shared
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
1301f77e17
commit
fae50eb64a
261
shared/source/gen8/hw_info_bdw.cpp
Normal file
261
shared/source/gen8/hw_info_bdw.cpp
Normal file
@@ -0,0 +1,261 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2021 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
|
||||
#include "shared/source/aub_mem_dump/definitions/aub_services.h"
|
||||
#include "shared/source/gen8/hw_cmds.h"
|
||||
#include "shared/source/helpers/constants.h"
|
||||
|
||||
#include "engine_node.h"
|
||||
|
||||
namespace NEO {
|
||||
|
||||
const char *HwMapper<IGFX_BROADWELL>::abbreviation = "bdw";
|
||||
|
||||
bool isSimulationBDW(unsigned short deviceId) {
|
||||
switch (deviceId) {
|
||||
case IBDW_GT0_DESK_DEVICE_F0_ID:
|
||||
case IBDW_GT1_DESK_DEVICE_F0_ID:
|
||||
case IBDW_GT2_DESK_DEVICE_F0_ID:
|
||||
case IBDW_GT3_DESK_DEVICE_F0_ID:
|
||||
case IBDW_GT4_DESK_DEVICE_F0_ID:
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
};
|
||||
|
||||
const PLATFORM BDW::platform = {
|
||||
IGFX_BROADWELL,
|
||||
PCH_UNKNOWN,
|
||||
IGFX_GEN8_CORE,
|
||||
IGFX_GEN8_CORE,
|
||||
PLATFORM_NONE, // default init
|
||||
0, // usDeviceID
|
||||
0, // usRevId. 0 sets the stepping to A0
|
||||
0, // usDeviceID_PCH
|
||||
0, // usRevId_PCH
|
||||
GTTYPE_UNDEFINED};
|
||||
|
||||
const RuntimeCapabilityTable BDW::capabilityTable{
|
||||
EngineDirectSubmissionInitVec{
|
||||
{aub_stream::ENGINE_RCS, {true, true}}}, // directSubmissionEngines
|
||||
{50000, 5000, 200000, true, true, true}, // kmdNotifyProperties
|
||||
MemoryConstants::max48BitAddress, // gpuAddressSpace
|
||||
80, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
&isSimulationBDW, // isSimulation
|
||||
PreemptionMode::Disabled, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
0, // maxRenderFrequency
|
||||
30, // clVersionSupport
|
||||
CmdServicesMemTraceVersion::DeviceValues::Bdw, // aubDeviceId
|
||||
0, // extraQuantityThreadsPerEU
|
||||
64, // slmSize
|
||||
sizeof(BDW::GRF), // grfSize
|
||||
36u, // timestampValidBits
|
||||
32u, // kernelTimestampValidBits
|
||||
false, // blitterOperationsSupported
|
||||
true, // ftrSupportsInteger64BitAtomics
|
||||
true, // ftrSupportsFP64
|
||||
true, // ftrSupports64BitMath
|
||||
true, // ftrSvm
|
||||
true, // ftrSupportsCoherency
|
||||
false, // ftrSupportsVmeAvcTextureSampler
|
||||
false, // ftrSupportsVmeAvcPreemption
|
||||
false, // ftrRenderCompressedBuffers
|
||||
false, // ftrRenderCompressedImages
|
||||
false, // ftr64KBpages
|
||||
true, // instrumentationEnabled
|
||||
true, // forceStatelessCompilationFor32Bit
|
||||
"core", // platformType
|
||||
"", // deviceName
|
||||
false, // sourceLevelDebuggerSupported
|
||||
false, // supportsVme
|
||||
false, // supportCacheFlushAfterWalker
|
||||
true, // supportsImages
|
||||
true, // supportsDeviceEnqueue
|
||||
true, // supportsPipes
|
||||
true, // supportsOcl21Features
|
||||
false, // supportsOnDemandPageFaults
|
||||
true, // supportsIndependentForwardProgress
|
||||
true, // hostPtrTrackingEnabled
|
||||
false, // levelZeroSupported
|
||||
true, // isIntegratedDevice
|
||||
true, // supportsMediaBlock
|
||||
false // fusedEuEnabled
|
||||
};
|
||||
|
||||
WorkaroundTable BDW::workaroundTable = {};
|
||||
FeatureTable BDW::featureTable = {};
|
||||
|
||||
void BDW::setupFeatureAndWorkaroundTable(HardwareInfo *hwInfo) {
|
||||
FeatureTable *featureTable = &hwInfo->featureTable;
|
||||
WorkaroundTable *workaroundTable = &hwInfo->workaroundTable;
|
||||
|
||||
featureTable->ftrL3IACoherency = true;
|
||||
featureTable->ftrPPGTT = true;
|
||||
featureTable->ftrSVM = true;
|
||||
featureTable->ftrIA32eGfxPTEs = true;
|
||||
featureTable->ftrFbc = true;
|
||||
featureTable->ftrFbc2AddressTranslation = true;
|
||||
featureTable->ftrFbcBlitterTracking = true;
|
||||
featureTable->ftrFbcCpuTracking = true;
|
||||
featureTable->ftrTileY = true;
|
||||
|
||||
workaroundTable->waDisableLSQCROPERFforOCL = true;
|
||||
workaroundTable->waReportPerfCountUseGlobalContextID = true;
|
||||
workaroundTable->waUseVAlign16OnTileXYBpp816 = true;
|
||||
workaroundTable->waModifyVFEStateAfterGPGPUPreemption = true;
|
||||
workaroundTable->waSamplerCacheFlushBetweenRedescribedSurfaceReads = true;
|
||||
}
|
||||
|
||||
const HardwareInfo BDW_1x2x6::hwInfo = {
|
||||
&BDW::platform,
|
||||
&BDW::featureTable,
|
||||
&BDW::workaroundTable,
|
||||
&BDW_1x2x6::gtSystemInfo,
|
||||
BDW::capabilityTable,
|
||||
};
|
||||
|
||||
GT_SYSTEM_INFO BDW_1x2x6::gtSystemInfo = {0};
|
||||
void BDW_1x2x6::setupHardwareInfo(HardwareInfo *hwInfo, bool setupFeatureTableAndWorkaroundTable) {
|
||||
GT_SYSTEM_INFO *gtSysInfo = &hwInfo->gtSystemInfo;
|
||||
gtSysInfo->ThreadCount = gtSysInfo->EUCount * BDW::threadsPerEu;
|
||||
gtSysInfo->SliceCount = 1;
|
||||
gtSysInfo->L3CacheSizeInKb = 384;
|
||||
gtSysInfo->L3BankCount = 2;
|
||||
gtSysInfo->MaxFillRate = 8;
|
||||
gtSysInfo->TotalVsThreads = 336;
|
||||
gtSysInfo->TotalHsThreads = 336;
|
||||
gtSysInfo->TotalDsThreads = 336;
|
||||
gtSysInfo->TotalGsThreads = 336;
|
||||
gtSysInfo->TotalPsThreadsWindowerRange = 64;
|
||||
gtSysInfo->CsrSizeInMb = 8;
|
||||
gtSysInfo->MaxEuPerSubSlice = BDW::maxEuPerSubslice;
|
||||
gtSysInfo->MaxSlicesSupported = BDW::maxSlicesSupported;
|
||||
gtSysInfo->MaxSubSlicesSupported = BDW::maxSubslicesSupported;
|
||||
gtSysInfo->IsL3HashModeEnabled = false;
|
||||
gtSysInfo->IsDynamicallyPopulated = false;
|
||||
if (setupFeatureTableAndWorkaroundTable) {
|
||||
setupFeatureAndWorkaroundTable(hwInfo);
|
||||
}
|
||||
};
|
||||
|
||||
const HardwareInfo BDW_1x3x6::hwInfo = {
|
||||
&BDW::platform,
|
||||
&BDW::featureTable,
|
||||
&BDW::workaroundTable,
|
||||
&BDW_1x3x6::gtSystemInfo,
|
||||
BDW::capabilityTable,
|
||||
};
|
||||
GT_SYSTEM_INFO BDW_1x3x6::gtSystemInfo = {0};
|
||||
void BDW_1x3x6::setupHardwareInfo(HardwareInfo *hwInfo, bool setupFeatureTableAndWorkaroundTable) {
|
||||
GT_SYSTEM_INFO *gtSysInfo = &hwInfo->gtSystemInfo;
|
||||
gtSysInfo->ThreadCount = gtSysInfo->EUCount * BDW::threadsPerEu;
|
||||
gtSysInfo->SliceCount = 1;
|
||||
gtSysInfo->L3CacheSizeInKb = 768;
|
||||
gtSysInfo->L3BankCount = 4;
|
||||
gtSysInfo->MaxFillRate = 8;
|
||||
gtSysInfo->TotalVsThreads = 336;
|
||||
gtSysInfo->TotalHsThreads = 336;
|
||||
gtSysInfo->TotalDsThreads = 336;
|
||||
gtSysInfo->TotalGsThreads = 336;
|
||||
gtSysInfo->TotalPsThreadsWindowerRange = 64;
|
||||
gtSysInfo->CsrSizeInMb = 8;
|
||||
gtSysInfo->MaxEuPerSubSlice = BDW::maxEuPerSubslice;
|
||||
gtSysInfo->MaxSlicesSupported = BDW::maxSlicesSupported;
|
||||
gtSysInfo->MaxSubSlicesSupported = BDW::maxSubslicesSupported;
|
||||
gtSysInfo->IsL3HashModeEnabled = false;
|
||||
gtSysInfo->IsDynamicallyPopulated = false;
|
||||
if (setupFeatureTableAndWorkaroundTable) {
|
||||
setupFeatureAndWorkaroundTable(hwInfo);
|
||||
}
|
||||
};
|
||||
|
||||
const HardwareInfo BDW_1x3x8::hwInfo = {
|
||||
&BDW::platform,
|
||||
&BDW::featureTable,
|
||||
&BDW::workaroundTable,
|
||||
&BDW_1x3x8::gtSystemInfo,
|
||||
BDW::capabilityTable,
|
||||
};
|
||||
GT_SYSTEM_INFO BDW_1x3x8::gtSystemInfo = {0};
|
||||
void BDW_1x3x8::setupHardwareInfo(HardwareInfo *hwInfo, bool setupFeatureTableAndWorkaroundTable) {
|
||||
GT_SYSTEM_INFO *gtSysInfo = &hwInfo->gtSystemInfo;
|
||||
gtSysInfo->ThreadCount = gtSysInfo->EUCount * BDW::threadsPerEu;
|
||||
gtSysInfo->SliceCount = 1;
|
||||
gtSysInfo->L3CacheSizeInKb = 384;
|
||||
gtSysInfo->L3BankCount = 2;
|
||||
gtSysInfo->MaxFillRate = 8;
|
||||
gtSysInfo->TotalVsThreads = 336;
|
||||
gtSysInfo->TotalHsThreads = 336;
|
||||
gtSysInfo->TotalDsThreads = 336;
|
||||
gtSysInfo->TotalGsThreads = 336;
|
||||
gtSysInfo->TotalPsThreadsWindowerRange = 64;
|
||||
gtSysInfo->CsrSizeInMb = 8;
|
||||
gtSysInfo->MaxEuPerSubSlice = BDW::maxEuPerSubslice;
|
||||
gtSysInfo->MaxSlicesSupported = BDW::maxSlicesSupported;
|
||||
gtSysInfo->MaxSubSlicesSupported = BDW::maxSubslicesSupported;
|
||||
gtSysInfo->IsL3HashModeEnabled = false;
|
||||
gtSysInfo->IsDynamicallyPopulated = false;
|
||||
if (setupFeatureTableAndWorkaroundTable) {
|
||||
setupFeatureAndWorkaroundTable(hwInfo);
|
||||
}
|
||||
};
|
||||
|
||||
const HardwareInfo BDW_2x3x8::hwInfo = {
|
||||
&BDW::platform,
|
||||
&BDW::featureTable,
|
||||
&BDW::workaroundTable,
|
||||
&BDW_2x3x8::gtSystemInfo,
|
||||
BDW::capabilityTable,
|
||||
};
|
||||
GT_SYSTEM_INFO BDW_2x3x8::gtSystemInfo = {0};
|
||||
void BDW_2x3x8::setupHardwareInfo(HardwareInfo *hwInfo, bool setupFeatureTableAndWorkaroundTable) {
|
||||
GT_SYSTEM_INFO *gtSysInfo = &hwInfo->gtSystemInfo;
|
||||
gtSysInfo->ThreadCount = gtSysInfo->EUCount * BDW::threadsPerEu;
|
||||
gtSysInfo->SliceCount = 2;
|
||||
gtSysInfo->L3CacheSizeInKb = 1536;
|
||||
gtSysInfo->L3BankCount = 8;
|
||||
gtSysInfo->MaxFillRate = 16;
|
||||
gtSysInfo->TotalVsThreads = 336;
|
||||
gtSysInfo->TotalHsThreads = 336;
|
||||
gtSysInfo->TotalDsThreads = 336;
|
||||
gtSysInfo->TotalGsThreads = 336;
|
||||
gtSysInfo->TotalPsThreadsWindowerRange = 64;
|
||||
gtSysInfo->CsrSizeInMb = 8;
|
||||
gtSysInfo->MaxEuPerSubSlice = BDW::maxEuPerSubslice;
|
||||
gtSysInfo->MaxSlicesSupported = BDW::maxSlicesSupported;
|
||||
gtSysInfo->MaxSubSlicesSupported = BDW::maxSubslicesSupported;
|
||||
gtSysInfo->IsL3HashModeEnabled = false;
|
||||
gtSysInfo->IsDynamicallyPopulated = false;
|
||||
if (setupFeatureTableAndWorkaroundTable) {
|
||||
setupFeatureAndWorkaroundTable(hwInfo);
|
||||
}
|
||||
};
|
||||
|
||||
const HardwareInfo BDW::hwInfo = BDW_1x3x8::hwInfo;
|
||||
const uint64_t BDW::defaultHardwareInfoConfig = 0x100030008;
|
||||
|
||||
void setupBDWHardwareInfoImpl(HardwareInfo *hwInfo, bool setupFeatureTableAndWorkaroundTable, uint64_t hwInfoConfig) {
|
||||
if (hwInfoConfig == 0x200030008) {
|
||||
BDW_2x3x8::setupHardwareInfo(hwInfo, setupFeatureTableAndWorkaroundTable);
|
||||
} else if (hwInfoConfig == 0x100030008) {
|
||||
BDW_1x3x8::setupHardwareInfo(hwInfo, setupFeatureTableAndWorkaroundTable);
|
||||
} else if (hwInfoConfig == 0x100030006) {
|
||||
BDW_1x3x6::setupHardwareInfo(hwInfo, setupFeatureTableAndWorkaroundTable);
|
||||
} else if (hwInfoConfig == 0x100020006) {
|
||||
BDW_1x2x6::setupHardwareInfo(hwInfo, setupFeatureTableAndWorkaroundTable);
|
||||
} else if (hwInfoConfig == 0x0) {
|
||||
// Default config
|
||||
BDW_1x3x8::setupHardwareInfo(hwInfo, setupFeatureTableAndWorkaroundTable);
|
||||
} else {
|
||||
UNRECOVERABLE_IF(true);
|
||||
}
|
||||
}
|
||||
|
||||
void (*BDW::setupHardwareInfo)(HardwareInfo *, bool, uint64_t) = setupBDWHardwareInfoImpl;
|
||||
} // namespace NEO
|
||||
12
shared/source/gen8/hw_info_gen8.cpp
Normal file
12
shared/source/gen8/hw_info_gen8.cpp
Normal file
@@ -0,0 +1,12 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2021 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
|
||||
#include "shared/source/gen8/hw_info_gen8.h"
|
||||
|
||||
namespace NEO {
|
||||
const char *GfxFamilyMapper<IGFX_GEN8_CORE>::name = "Gen8";
|
||||
} // namespace NEO
|
||||
Reference in New Issue
Block a user