For apu: call commitSvmMemory() from Device::svmAlloc()
Change-Id: Ic6e9b2ad4624e7e1c50835d3825254c76e764bf0
[ROCm/clr commit: 532083f87c]
Ta zmiana jest zawarta w:
1 rodzic
e8de9c3322
złożenie
b2e264b2c1
Plik 1 zmieniony
+4
@@ -2237,6 +2237,10 @@ void* Device::svmAlloc(amd::Context& context, size_t size, size_t alignment, cl_
|
|||||||
// add the information to context so that we can use it later.
|
// add the information to context so that we can use it later.
|
||||||
amd::MemObjMap::AddMemObj(mem->getSvmPtr(), mem);
|
amd::MemObjMap::AddMemObj(mem->getSvmPtr(), mem);
|
||||||
svmPtr = mem->getSvmPtr();
|
svmPtr = mem->getSvmPtr();
|
||||||
|
|
||||||
|
if (settings().apuSystem_ && gpuMem->isHostMemDirectAccess()) {
|
||||||
|
mem->commitSvmMemory();
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
// find the existing amd::mem object
|
// find the existing amd::mem object
|
||||||
mem = amd::MemObjMap::FindMemObj(svmPtr);
|
mem = amd::MemObjMap::FindMemObj(svmPtr);
|
||||||
|
|||||||
Reference in new issue
Zablokuj użytkownika