mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 06:49:52 +08:00
Skip disabled engines when round robin over copy engines
Signed-off-by: Lukasz Jobczyk <lukasz.jobczyk@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
538e0aea87
commit
ae357c79ed
@@ -162,8 +162,8 @@ aub_stream::EngineType selectLinkCopyEngine(const HardwareInfo &hwInfo, const De
|
||||
if (enableCmdQRoundRobindBcsEngineAssign) {
|
||||
aub_stream::EngineType engineType;
|
||||
do {
|
||||
engineType = static_cast<aub_stream::EngineType>(aub_stream::EngineType::ENGINE_BCS1 + (selectorCopyEngine.fetch_add(1u) % 8));
|
||||
} while (!HwHelper::get(hwInfo.platform.eRenderCoreFamily).isSubDeviceEngineSupported(hwInfo, deviceBitfield, engineType));
|
||||
engineType = static_cast<aub_stream::EngineType>(aub_stream::EngineType::ENGINE_BCS1 + (selectorCopyEngine.fetch_add(1u) % EngineHelpers::numLinkedCopyEngines));
|
||||
} while (!HwHelper::get(hwInfo.platform.eRenderCoreFamily).isSubDeviceEngineSupported(hwInfo, deviceBitfield, engineType) || !hwInfo.featureTable.ftrBcsInfo.test(engineType - aub_stream::EngineType::ENGINE_BCS1 + 1));
|
||||
|
||||
return engineType;
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2021 Intel Corporation
|
||||
* Copyright (C) 2019-2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -64,6 +64,8 @@ constexpr bool isLinkBcs(aub_stream::EngineType engineType) {
|
||||
return engineType >= aub_stream::ENGINE_BCS1 && engineType <= aub_stream::ENGINE_BCS8;
|
||||
}
|
||||
|
||||
constexpr uint32_t numLinkedCopyEngines = 8u;
|
||||
|
||||
bool linkCopyEnginesSupported(const HardwareInfo &hwInfo, const DeviceBitfield &deviceBitfield);
|
||||
|
||||
aub_stream::EngineType selectLinkCopyEngine(const HardwareInfo &hwInfo, const DeviceBitfield &deviceBitfield, std::atomic<uint32_t> &selectorCopyEngine);
|
||||
|
||||
Reference in New Issue
Block a user