diff --git a/paddle/phi/kernels/funcs/strided_memcpy.h b/paddle/phi/kernels/funcs/strided_memcpy.h index 19a542bd2b5e9bdfc4b8e9f866a00cc9e2427ebf..de38e40d317e19ca058db2f42185fc20ca747194 100644 --- a/paddle/phi/kernels/funcs/strided_memcpy.h +++ b/paddle/phi/kernels/funcs/strided_memcpy.h @@ -56,7 +56,8 @@ inline void CopyWithContext(const Context& ctx, const Place& src_place, const void* src, size_t num) { -#if defined(PADDLE_WITH_CUDA) || defined(PADDLE_WITH_HIP) +#if defined(PADDLE_WITH_CUDA) || defined(PADDLE_WITH_HIP) || \ + defined(PADDLE_WITH_CUSTOM_DEVICE) memory_utils::Copy(dst_place, dst, src_place, src, num, ctx.stream()); #else PADDLE_THROW(