SWDEV-336024 - Clear device heap to 0

The heap must be cleared once per device, but ROCclr doesn't
create a queue per device in HIP. Hence, the clear operation will
be performed during the first queue creation.

Change-Id: I52ceb06d67d11cde6d019c5ab510059f426a9bfb
This commit is contained in:
German Andryeyev
2022-05-06 16:12:22 -04:00
parent 6c458c7534
commit 04bfd93569
10 changed files with 77 additions and 47 deletions
+2 -1
View File
@@ -883,7 +883,8 @@ bool Buffer::create(bool alloc_local) {
const_cast<Device&>(dev()).updateFreeMemory(size(), false);
}
}
else {
// Hide private allocations from memory tracking
else if (owner()->getContext() != dev().context()) {
const_cast<Device&>(dev()).updateFreeMemory(size(), false);
}