Create printf handler if kernel has implicit args in OCL

Related-To: NEO-5081
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
Mateusz Jablonski
2021-09-17 10:33:25 +00:00
committed by Compute-Runtime-Automation
parent 5be770ab49
commit 64b2fd5b19
7 changed files with 93 additions and 38 deletions

View File

@@ -37,9 +37,10 @@ PrintfHandler *PrintfHandler::create(const MultiDispatchInfo &multiDispatchInfo,
return new PrintfHandler(device);
}
auto mainKernel = multiDispatchInfo.peekMainKernel();
if ((mainKernel != nullptr) &&
mainKernel->checkIfIsParentKernelAndBlocksUsesPrintf()) {
return new PrintfHandler(device);
if (mainKernel != nullptr) {
if (mainKernel->checkIfIsParentKernelAndBlocksUsesPrintf() || mainKernel->getImplicitArgs()) {
return new PrintfHandler(device);
}
}
return nullptr;
}