mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-20 00:24:58 +08:00
Remove adjustHwInfoForIgc helper
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com> Related-To: NEO-6738
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
6f2efa4d54
commit
7f08a9d993
@@ -242,10 +242,8 @@ bool ModuleTranslationUnit::createFromNativeBinary(const char *input, size_t inp
|
||||
UNRECOVERABLE_IF((nullptr == device) || (nullptr == device->getNEODevice()));
|
||||
auto productAbbreviation = NEO::hardwarePrefix[device->getNEODevice()->getHardwareInfo().platform.eProductFamily];
|
||||
|
||||
auto copyHwInfo = device->getNEODevice()->getHardwareInfo();
|
||||
const auto &compilerHwInfoConfig = *NEO::CompilerHwInfoConfig::get(copyHwInfo.platform.eProductFamily);
|
||||
compilerHwInfoConfig.adjustHwInfoForIgc(copyHwInfo);
|
||||
NEO::TargetDevice targetDevice = NEO::targetDeviceFromHwInfo(copyHwInfo);
|
||||
const auto &hwInfo = device->getNEODevice()->getHardwareInfo();
|
||||
NEO::TargetDevice targetDevice = NEO::targetDeviceFromHwInfo(hwInfo);
|
||||
std::string decodeErrors;
|
||||
std::string decodeWarnings;
|
||||
ArrayRef<const uint8_t> archive(reinterpret_cast<const uint8_t *>(input), inputSize);
|
||||
|
||||
@@ -162,11 +162,6 @@ cl_int Program::createProgramFromBinary(
|
||||
|
||||
auto hwInfo = executionEnvironment.rootDeviceEnvironments[rootDeviceIndex]->getHardwareInfo();
|
||||
auto productAbbreviation = hardwarePrefix[hwInfo->platform.eProductFamily];
|
||||
|
||||
auto copyHwInfo = *hwInfo;
|
||||
const auto &compilerHwInfoConfig = *CompilerHwInfoConfig::get(copyHwInfo.platform.eProductFamily);
|
||||
compilerHwInfoConfig.adjustHwInfoForIgc(copyHwInfo);
|
||||
|
||||
TargetDevice targetDevice = targetDeviceFromHwInfo(*hwInfo);
|
||||
std::string decodeErrors;
|
||||
std::string decodeWarnings;
|
||||
@@ -304,7 +299,7 @@ void Program::cleanCurrentKernelInfo(uint32_t rootDeviceIndex) {
|
||||
auto &buildInfo = buildInfos[rootDeviceIndex];
|
||||
for (auto &kernelInfo : buildInfo.kernelInfoArray) {
|
||||
if (kernelInfo->kernelAllocation) {
|
||||
//register cache flush in all csrs where kernel allocation was used
|
||||
// register cache flush in all csrs where kernel allocation was used
|
||||
for (auto &engine : this->executionEnvironment.memoryManager->getRegisteredEngines()) {
|
||||
auto contextId = engine.osContext->getContextId();
|
||||
if (kernelInfo->kernelAllocation->isUsedByOsContext(contextId)) {
|
||||
@@ -334,10 +329,10 @@ void Program::cleanCurrentKernelInfo(uint32_t rootDeviceIndex) {
|
||||
}
|
||||
|
||||
void Program::updateNonUniformFlag() {
|
||||
//Look for -cl-std=CL substring and extract value behind which can be 1.2 2.0 2.1 and convert to value
|
||||
// Look for -cl-std=CL substring and extract value behind which can be 1.2 2.0 2.1 and convert to value
|
||||
auto pos = options.find(clStdOptionName);
|
||||
if (pos == std::string::npos) {
|
||||
programOptionVersion = 12u; //Default is 1.2
|
||||
programOptionVersion = 12u; // Default is 1.2
|
||||
} else {
|
||||
std::stringstream ss{options.c_str() + pos + clStdOptionName.size()};
|
||||
uint32_t majorV = 0u, minorV = 0u;
|
||||
|
||||
@@ -79,13 +79,9 @@ int OclocIgcFacade::initialize(const HardwareInfo &hwInfo) {
|
||||
}
|
||||
|
||||
const auto compilerHwInfoConfig = CompilerHwInfoConfig::get(hwInfo.platform.eProductFamily);
|
||||
auto copyHwInfo = hwInfo;
|
||||
if (compilerHwInfoConfig) {
|
||||
compilerHwInfoConfig->adjustHwInfoForIgc(copyHwInfo);
|
||||
}
|
||||
|
||||
IGC::PlatformHelper::PopulateInterfaceWith(*igcPlatform.get(), copyHwInfo.platform);
|
||||
IGC::GtSysInfoHelper::PopulateInterfaceWith(*igcGtSystemInfo.get(), copyHwInfo.gtSystemInfo);
|
||||
IGC::PlatformHelper::PopulateInterfaceWith(*igcPlatform.get(), hwInfo.platform);
|
||||
IGC::GtSysInfoHelper::PopulateInterfaceWith(*igcGtSystemInfo.get(), hwInfo.gtSystemInfo);
|
||||
|
||||
populateWithFeatures(igcFtrWa.get(), hwInfo, compilerHwInfoConfig);
|
||||
|
||||
|
||||
@@ -436,12 +436,8 @@ IGC::IgcOclDeviceCtxTagOCL *CompilerInterface::getIgcDeviceCtx(const Device &dev
|
||||
getHwInfoForPlatformString(productFamily, hwInfo);
|
||||
}
|
||||
|
||||
auto copyHwInfo = *hwInfo;
|
||||
const auto &compilerHwInfoConfig = *CompilerHwInfoConfig::get(copyHwInfo.platform.eProductFamily);
|
||||
compilerHwInfoConfig.adjustHwInfoForIgc(copyHwInfo);
|
||||
|
||||
IGC::PlatformHelper::PopulateInterfaceWith(*igcPlatform, copyHwInfo.platform);
|
||||
IGC::GtSysInfoHelper::PopulateInterfaceWith(*igcGtSystemInfo, copyHwInfo.gtSystemInfo);
|
||||
IGC::PlatformHelper::PopulateInterfaceWith(*igcPlatform, hwInfo->platform);
|
||||
IGC::GtSysInfoHelper::PopulateInterfaceWith(*igcGtSystemInfo, hwInfo->gtSystemInfo);
|
||||
|
||||
igcFtrWa.get()->SetFtrDesktop(device.getHardwareInfo().featureTable.flags.ftrDesktop);
|
||||
igcFtrWa.get()->SetFtrChannelSwizzlingXOREnabled(device.getHardwareInfo().featureTable.flags.ftrChannelSwizzlingXOREnabled);
|
||||
|
||||
@@ -27,7 +27,6 @@ class CompilerHwInfoConfig {
|
||||
virtual bool isForceEmuInt32DivRemSPRequired() const = 0;
|
||||
virtual bool isStatelessToStatefulBufferOffsetSupported() const = 0;
|
||||
virtual bool isForceToStatelessRequired() const = 0;
|
||||
virtual void adjustHwInfoForIgc(HardwareInfo &hwInfo) const = 0;
|
||||
};
|
||||
|
||||
template <PRODUCT_FAMILY gfxProduct>
|
||||
@@ -42,7 +41,6 @@ class CompilerHwInfoConfigHw : public CompilerHwInfoConfig {
|
||||
bool isForceEmuInt32DivRemSPRequired() const override;
|
||||
bool isStatelessToStatefulBufferOffsetSupported() const override;
|
||||
bool isForceToStatelessRequired() const override;
|
||||
void adjustHwInfoForIgc(HardwareInfo &hwInfo) const override;
|
||||
|
||||
protected:
|
||||
CompilerHwInfoConfigHw() = default;
|
||||
|
||||
@@ -20,8 +20,4 @@ bool CompilerHwInfoConfigHw<gfxProduct>::isStatelessToStatefulBufferOffsetSuppor
|
||||
return true;
|
||||
}
|
||||
|
||||
template <PRODUCT_FAMILY gfxProduct>
|
||||
void CompilerHwInfoConfigHw<gfxProduct>::adjustHwInfoForIgc(HardwareInfo &hwInfo) const {
|
||||
}
|
||||
|
||||
} // namespace NEO
|
||||
|
||||
Reference in New Issue
Block a user