When using asynchronous plugin calls, shadow pointer restore could happen before the D2H copy for the entire struct has completed, effectively leaving a device pointer in a host struct. This patch fixes the problem by delaying restore's to after a synchronization happens (target regions) and by calling early synchronization (target update).
Details
Details
Diff Detail
Diff Detail
Event Timeline
openmp/libomptarget/src/omptarget.cpp | ||
---|---|---|
897 | Why don't we do this above as well. Seems much simpler and the delay we buy us with the complexity is minimal anyway. |
openmp/libomptarget/src/omptarget.cpp | ||
---|---|---|
897 | Agreed: good short term solution and keeps complexity down. I will update the patch asap. |
Comment Actions
Nits: Wait (capital W) and "." at the end. Both comments should be proper sentences.
LG
clang-format: please reformat the code