Visible to Intel only — GUID: GUID-6BBCC200-86D5-4386-B381-8416B61A74D7
Visible to Intel only — GUID: GUID-6BBCC200-86D5-4386-B381-8416B61A74D7
DPCT1124
Message
<API name> is migrated to asynchronous memcpy API. While the origin API might be synchronous, it depends on the type of operand memory, so you may need to call wait() on event return by memcpy API to ensure synchronization behavior.
Detailed Help
Some CUDA* asynchronous API might be synchronous with respect to host. For example, asynchronous memcpy API might be synchronous in the following 3 cases: data transfers between device memory and pageable host memory, data transfers between host memory, and data transfers involving pinned memory.
Suggestions to Fix
For example, this original CUDA code:
cudaMemcpyAsync(host_dst, host_src, size, cudaMemcpyHostToHost);
results in the following migrated SYCL* code:
/*
DPCT1124:0: cudaMemcpyAsync is migrated to asynchronous memcpy API. While the
origin API might be synchronous, it depends on the type of operand memory, so
you may need to call wait() on event return by memcpy API to ensure
synchronization behavior.
*/
dpct::get_in_order_queue().memcpy(host_dst, host_src, size);
which needs to be rewritten to:
dpct::get_in_order_queue().memcpy(host_dst, host_src, size).wait();