Skip to content

Commit f924ff5

Browse files
committed
use memcpy not std::memcpy in hip
1 parent 5041e5a commit f924ff5

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

hip/components/memory.hip.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ __device__ __forceinline__ ValueType load_generic(const ValueType* ptr)
9999
auto cast_value = HIP_ATOMIC_LOAD(reinterpret_cast<const atomic_type*>(ptr),
100100
memorder, scope);
101101
ValueType result{};
102-
std::memcpy(&result, &cast_value, sizeof(ValueType));
102+
memcpy(&result, &cast_value, sizeof(ValueType));
103103
return result;
104104
}
105105

@@ -122,7 +122,7 @@ __device__ __forceinline__ void store_generic(ValueType* ptr, ValueType value)
122122
static_assert(sizeof(atomic_type) == sizeof(ValueType), "invalid map");
123123
static_assert(alignof(atomic_type) == alignof(ValueType), "invalid map");
124124
atomic_type cast_value{};
125-
std::memcpy(&cast_value, &value, sizeof(ValueType));
125+
memcpy(&cast_value, &value, sizeof(ValueType));
126126
HIP_ATOMIC_STORE(reinterpret_cast<atomic_type*>(ptr), cast_value, memorder,
127127
scope);
128128
}

0 commit comments

Comments
 (0)