Implementation of nowait and async in libomptarget

Hi everyone,

I'm looking into the use of `nowait` with target regions and I have some questions about the implementation in libomptarget, maybe someone here can help me with some details.

Libomptarget has an optional async interface, for plugins to implement. I orignally expected, that nowait target regions would be implemented with a call to __tgt_run_target_region_async(), but the implementation in libomptarget seems to always use the async interface when available (even for blocking target region executions) and always tries to synchronize after a target region is executed.

Can someone tell me if I got this right and how a `#pragma omp target nowait` is handled by the openmp runtime?


Manoel Römmer

Hi Manoel,

Shilei (CC'ed) has a proper implementation of target nowait, for now we basically implement it synchronously.

The reviews are online and Shilei will share the links. Feel free to join our weekly meeting [1] to as we discuss it there as well.

~ Johannes

[1] OpenMP in LLVM - Weekly Meeting - Google Docs

Hi Manoel,

You could refer to and for more design details. :slight_smile: