mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-28 00:03:14 +08:00
Allow for zebin rebuild when IR is present
This commits adds rebuilding zebin binary. If zebin is built for different device and has SPIRV, then new ze binary will be built using SPIRV. Signed-off-by: Krystian Chmielewski <krystian.chmielewski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
e9ebd10ab8
commit
01a719cf33
@@ -64,10 +64,12 @@ cl_int Program::build(
|
||||
deviceBuildInfos[device].buildStatus = CL_BUILD_IN_PROGRESS;
|
||||
}
|
||||
|
||||
if (nullptr != buildOptions) {
|
||||
options = buildOptions;
|
||||
} else if (this->createdFrom != CreatedFrom::BINARY) {
|
||||
options = "";
|
||||
if (false == requiresRebuild) {
|
||||
if (nullptr != buildOptions) {
|
||||
options = buildOptions;
|
||||
} else if (this->createdFrom != CreatedFrom::BINARY) {
|
||||
options = "";
|
||||
}
|
||||
}
|
||||
|
||||
const bool shouldSuppressRebuildWarning{CompilerOptions::extract(CompilerOptions::noRecompiledFromIr, options)};
|
||||
@@ -130,7 +132,7 @@ cl_int Program::build(
|
||||
NEO::TranslationOutput compilerOuput = {};
|
||||
|
||||
for (const auto &clDevice : deviceVector) {
|
||||
if (shouldWarnAboutRebuild && !shouldSuppressRebuildWarning) {
|
||||
if (requiresRebuild && !shouldSuppressRebuildWarning) {
|
||||
this->updateBuildLog(clDevice->getRootDeviceIndex(), CompilerWarnings::recompiledFromIr.data(), CompilerWarnings::recompiledFromIr.length());
|
||||
}
|
||||
auto compilerErr = pCompilerInterface->build(clDevice->getDevice(), inputArgs, compilerOuput);
|
||||
|
||||
Reference in New Issue
Block a user