mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-29 09:03:14 +08:00
Add Device::getParentDevice function
Change-Id: I7b75bca67dceb74624c8dd8fd8c1542437fd9393 Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
This commit is contained in:
@@ -43,6 +43,10 @@ Device *SubDevice::getDeviceById(uint32_t deviceId) const {
|
||||
return const_cast<SubDevice *>(this);
|
||||
}
|
||||
|
||||
Device *SubDevice::getParentDevice() const {
|
||||
return &rootDevice;
|
||||
}
|
||||
|
||||
uint64_t SubDevice::getGlobalMemorySize() const {
|
||||
auto globalMemorySize = Device::getGlobalMemorySize();
|
||||
return globalMemorySize / rootDevice.getNumAvailableDevices();
|
||||
|
||||
Reference in New Issue
Block a user