[Openmp-dev] OMPT callbacks for target

John Mellor-Crummey via Openmp-dev openmp-dev at lists.llvm.org
Tue Oct 22 07:43:53 PDT 2019


We have implemented a draft of all of libomptarget OpenMP 5.0 device support here: https://github.com/jmellorcrummey/llvm-openmp-5
The default branch is openmp5-gpu, which includes the device-independent support in libomptarget as well as device-dependent support for NVIDIA GPUs.
While we merged changes from LLVM OpenMP recently (over the summer), our version is likely not completely up to date with changes in LLVM OpenMP.

The only difference between what we have implemented and the OpenMP 5.0 standard is that we changed the implementation to provide begin/end pairs for ompt_callback_target_submit and ompt_callback_target_data_op callbacks, as described in the attached document, which we proposed as a change for OpenMP 5.1.  There is a discussion of this suggested change vs. alternative ways of supporting mixed programming models (e.g. CUDA+OpenMP5, HIP+OpenMP5, SYCL+OpenMP5) on the OpenMP tools telecon today 1.25 hours from now.

Besides the libomptarget support, the repository above also has fixes for handling OMPT frames for call stack introspection. We need to separate the libomptarget work from the rest and submit them upstream as separate pull requests.
--
John Mellor-Crummey		Professor
Dept of Computer Science	Rice University
email: johnmc at rice.edu		phone: 713-348-5179

> On Oct 22, 2019, at 9:22 AM, Hervé Yviquel via Openmp-dev <openmp-dev at lists.llvm.org> wrote:
> 
> Hi all,
> 
> We are developing a tracing tool relying on OMPT callbacks which works quite good for tasks and parallel regions but not that for target regions:
> 0: Could not register callback 'ompt_callback_device_initialize'
> 0: Could not register callback 'ompt_callback_device_load'
> 0: Could not register callback 'ompt_callback_target'
> After looking at libomp and libomptarget code, it seems all target-related data structures are implemented on the OMPT sides but not the callbacks on libomptarget side. We are considering implementing it then submitting a patch but I would like to know if someone in the openmp community is already looking at it? Indeed, we don't want to reimplement something that is already available but not yet upstream.
> 
> Thanks,
> Hervé
> _______________________________________________
> Openmp-dev mailing list
> Openmp-dev at lists.llvm.org
> https://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/openmp-dev/attachments/20191022/7f5ad34d/attachment-0002.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: openmp-changes-diffs.pdf
Type: application/pdf
Size: 231893 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-dev/attachments/20191022/7f5ad34d/attachment-0001.pdf>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/openmp-dev/attachments/20191022/7f5ad34d/attachment-0003.html>


More information about the Openmp-dev mailing list