SWDEV-529449 - Bug fix when retrieving a memobj from the IPC mem handle

[ROCm/clr commit: f7482ef0a6]
This commit is contained in:
Assiouras, Ioannis
2025-05-13 19:18:22 +01:00
committed by GitHub
parent f6e2ce709e
commit 71f19d7017
7 changed files with 55 additions and 53 deletions
+8
View File
@@ -416,6 +416,14 @@ device::Memory* Memory::getDeviceMemory(const Device& dev, bool alloc) {
// ================================================================================================
Memory::~Memory() {
if (ipcShared()) {
amd::MemObjMap::RemoveIpcHandleMemObj(this);
auto device = context_().devices()[0];
if (device != nullptr) {
device->IpcDetach(this);
}
}
// For_each destructor callback:
DestructorCallBackEntry* entry;
for (entry = destructorCallbacks_; entry != nullptr; entry = entry->next_) {