Limit cooperative dispatch support to platforms supporting cooperative engine

By default, cooperative dispatch is not supported
for platforms not supporting cooperative engine.

Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
This commit is contained in:
Filip Hazubski
2022-11-20 22:36:09 +00:00
committed by Compute-Runtime-Automation
parent 6c7ca96f28
commit c124bfbc6c
11 changed files with 193 additions and 23 deletions

View File

@@ -6047,7 +6047,9 @@ cl_int CL_API_CALL clEnqueueNDCountKernelINTEL(cl_command_queue commandQueue,
auto &gfxCoreHelper = device.getGfxCoreHelper();
auto engineGroupType = gfxCoreHelper.getEngineGroupType(pCommandQueue->getGpgpuEngine().getEngineType(),
pCommandQueue->getGpgpuEngine().getEngineUsage(), hardwareInfo);
if (!gfxCoreHelper.isCooperativeDispatchSupported(engineGroupType, hardwareInfo)) {
if (!gfxCoreHelper.isCooperativeDispatchSupported(engineGroupType, hardwareInfo) &&
(DebugManager.flags.ForceTheoreticalMaxWorkGroupCount.get() == false) &&
(DebugManager.flags.OverrideMaxWorkGroupCount.get() == -1)) {
retVal = CL_INVALID_COMMAND_QUEUE;
return retVal;
}