Skip to content

Commit 58f8d40

Browse files
kmorelJieyangChen7
authored andcommitted
Fix reference to HIP point attribute structure
When checking whether a pointer is on a HIP device, the previous code had an incorrect name for the member of the `hipPointerAttribute_t` structure. The code is changed to use the correct identifier for this member.
1 parent 5155138 commit 58f8d40

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/mgard-x/RuntimeX/DeviceAdapters/DeviceAdapterHip.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -928,7 +928,7 @@ template <> class MemoryManager<HIP> {
928928
log::dbg("Calling MemoryManager<HIP>::IsDevicePointer");
929929
hipPointerAttribute_t attr;
930930
hipPointerGetAttributes(&attr, ptr);
931-
return attr.memoryType == hipMemoryTypeDevice;
931+
return attr.type == hipMemoryTypeDevice;
932932
}
933933

934934
template <typename T> MGARDX_CONT static int GetPointerDevice(T *ptr) {

0 commit comments

Comments
 (0)