P4 to Git Change 1545895 by gandryey@gera-w8 on 2018/04/24 18:25:56

SWDEV-79445 - OCL generic changes and code clean-up
	- Replace dynamic memory object allocation for the managed buffer with a preallocated object

Affected files ...

... //depot/stg/opencl/drivers/opencl/runtime/device/device.hpp#298 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palconstbuf.cpp#9 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palconstbuf.hpp#8 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palmemory.hpp#5 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palresource.cpp#64 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palresource.hpp#21 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palvirtual.cpp#94 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palvirtual.hpp#50 edit
This commit is contained in:
foreman
2018-04-24 18:35:32 -04:00
parent 03b72c3007
commit 2f41f41977
8 changed files with 61 additions and 39 deletions
@@ -321,6 +321,8 @@ Resource::~Resource() {
image_->Destroy();
delete[] reinterpret_cast<char*>(image_);
}
// Remove the current resource from the global resource list
gpuDevice_.removeResource(this);
}
@@ -1225,6 +1227,8 @@ void Resource::free()
if (!desc().buffer_) {
dev().srds().freeSrdSlot(hwSrd_);
}
memRef_ = nullptr;
}
// ================================================================================================