Fix DirectSubmission residency handling

- allocations should be resident within OsContext

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
This commit is contained in:
Mateusz Hoppe
2021-09-03 11:40:34 +00:00
committed by Compute-Runtime-Automation
parent e9f56e7d96
commit f2eb7f3aea
11 changed files with 101 additions and 10 deletions

View File

@@ -56,6 +56,14 @@ MemoryOperationsStatus AubMemoryOperationsHandler::evict(Device *device, Graphic
}
}
MemoryOperationsStatus AubMemoryOperationsHandler::makeResidentWithinOsContext(OsContext *osContext, ArrayRef<GraphicsAllocation *> gfxAllocations, bool evictable) {
return makeResident(nullptr, gfxAllocations);
}
MemoryOperationsStatus AubMemoryOperationsHandler::evictWithinOsContext(OsContext *osContext, GraphicsAllocation &gfxAllocation) {
return evict(nullptr, gfxAllocation);
}
MemoryOperationsStatus AubMemoryOperationsHandler::isResident(Device *device, GraphicsAllocation &gfxAllocation) {
auto lock = acquireLock(resourcesLock);
auto itor = std::find(residentAllocations.begin(), residentAllocations.end(), &gfxAllocation);