SWDEV-392367 - Fixes hipMemGetAddressRange returning device buffer size as 0
Change-Id: I6b5640b544390b2dfc53fad271acc7f30240e274
This commit is contained in:
committed by
Sourabh Betigeri
parent
b6aa27d4a3
commit
7aba1cf4cd
@@ -730,7 +730,8 @@ hipError_t hipMemGetAddressRange(hipDeviceptr_t* pbase, size_t* psize, hipDevice
|
|||||||
|
|
||||||
// Since we are using SVM buffer DevicePtr and HostPtr is the same
|
// Since we are using SVM buffer DevicePtr and HostPtr is the same
|
||||||
void* ptr = dptr;
|
void* ptr = dptr;
|
||||||
amd::Memory* svmMem = getMemoryObjectWithOffset(ptr);
|
size_t offset = 0;
|
||||||
|
amd::Memory* svmMem = getMemoryObject(ptr, offset);
|
||||||
if (svmMem == nullptr) {
|
if (svmMem == nullptr) {
|
||||||
HIP_RETURN(hipErrorNotFound);
|
HIP_RETURN(hipErrorNotFound);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user