mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-29 00:58:39 +08:00
feature: L0 Device Hierarchy support for Composite & Flat modes
Related-To: LOCI-4615 - Added Support for users to set ZE_FLAT_DEVICE_HIERARCHY to either FLAT or COMPOSITE to change how devices are returned in zeDeviceGet and clGetDeviceIDs. - COMPOSITE is default behavior that exists today. - FLAT returns all sub devices which have no sub devices and all root devices that have no sub devices in zeDeviceGet ie with all devices flattened out in order. - Added zeDeviceGetRootDevice for one to retrieve the Root Device for any SubDevice. Signed-off-by: Neil R Spruit <neil.r.spruit@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
5b80bd4d7c
commit
8efd8853fb
@@ -262,6 +262,10 @@ cl_int CL_API_CALL clGetDeviceIDs(cl_platform_id platform,
|
||||
exposeSubDevices = DebugManager.flags.ReturnSubDevicesAsApiDevices.get();
|
||||
}
|
||||
|
||||
if (pPlatform->peekExecutionEnvironment()->isExposingSubDevicesAsDevices()) {
|
||||
exposeSubDevices = true;
|
||||
}
|
||||
|
||||
ClDevice *device = pPlatform->getClDevice(platformDeviceIndex);
|
||||
UNRECOVERABLE_IF(device == nullptr);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user