SWDEV-311271 - Initial mempool implementation
HIP_MEM_POOL_SUPPORT controls memory pool support in runtime. Currently it's disabled by default. The initial change doesn't include: IPC, MGPU, virtual memory alloc, suballoc, defragmentation, internal dependencies. Change-Id: Ibed8528ebec698b045ebb247e49c0ecd6e587ed7
Этот коммит содержится в:
1 родитель
1a4fd9b7ea
Коммит
539d264eb0
14 files changed
+1438
-7
No files matched your search
@@ -407,6 +407,12 @@ hipError_t hipStreamSynchronize(hipStream_t stream) {
|
||||
// Wait for the current host queue
|
||||
hip::getQueue(stream)->finish();
|
||||
|
||||
// Make sure runtime releases memory for all memory pools on the device,
|
||||
// associated with the queue
|
||||
auto hip_stream = reinterpret_cast<hip::Stream*>(stream);
|
||||
auto device = (hip_stream == nullptr) ? hip::getCurrentDevice() : hip_stream->GetDevice();
|
||||
device->ReleaseFreedMemory(hip_stream);
|
||||
|
||||
HIP_RETURN(hipSuccess);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user