mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-25 21:42:53 +08:00
Fill devices from api thread
Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
5c1c96fa94
commit
b0ec436b3e
@@ -157,6 +157,23 @@ bool DebugSession::areRequestedThreadsStopped(ze_device_thread_t thread) {
|
||||
return requestedThreadsStopped;
|
||||
}
|
||||
|
||||
void DebugSession::fillDevicesFromThread(ze_device_thread_t thread, std::vector<uint8_t> &devices) {
|
||||
auto deviceCount = std::max(1u, connectedDevice->getNEODevice()->getNumSubDevices());
|
||||
UNRECOVERABLE_IF(devices.size() < deviceCount);
|
||||
|
||||
uint32_t deviceIndex = 0;
|
||||
convertToPhysical(thread, deviceIndex);
|
||||
bool singleDevice = (thread.slice != UINT32_MAX && deviceCount > 1) || deviceCount == 1;
|
||||
|
||||
if (singleDevice) {
|
||||
devices[deviceIndex] = 1;
|
||||
} else {
|
||||
for (uint32_t i = 0; i < deviceCount; i++) {
|
||||
devices[i] = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
bool DebugSession::isBindlessSystemRoutine() {
|
||||
if (debugArea.reserved1 &= 1) {
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user