we briefly discussed the following with Jonathan, Andrey and Hansang at the OpenMP LC F2F meeting last week.
OpenMP 5.0 will not only bring OMPT, which is already implemented in trunk, but also OMPD. OMPD is an interface for tools that execute in a separate process (aka. third-party tools), which is typically the case for debuggers. The architecture of OMPD is similar to libthread_db.#
A preliminary specification of OMPD can be found in TR6 of the spec.
We were working internally on an implementation while specifying the interface. We are currently pushing the code to the repository of the OpenMP tools working group:
Similar as with OMPT, we will develop and update the implementation in this repository and then push the implementation to trunk.
To get started, we want to clear some organizing questions:
Name of the OMPD library?
We have several names in discussion: libompd.so, libomp-debug.so, libompdebug.so, or libomp_db.so
From the interface point of view the name does not matter, the runtime will contain a breadcrumb telling the debugger the name of the library.
Finally, OMPD will give a tool insight into host runtime and at the same time into the device runtime. Therefore we suggest to create a new directory at the top level, i.e., new sibling to runtime and libomptarget.
The suggested name for the directory is the library name.
The architecture of OMPD requires a tool loading the debugging library. The tool needs to provide basic debugging functionality (lookup names, reading memory, ...) to the library. While it is possible to implement basic regression tests as a standalone application, to test the real functionality, an OpenMP application executing under control of a debugging tool is necessary. To verify the consistency of information provided by OMPD, we can compare the information to OMPT or OpenMP runtime calls.
During our development, we worked with Dyninst for automatic regression testing. The same workflow could also be implemented with another debugger like gdb (, or probably lldb?)
The question here, what is the preferred approach for testing? What dependencies are acceptable?
PS: Sorry for double-post in case my earlier mail gets through moderation.