On Thu, Jun 25, 2020 at 12:27:32PM -0400, y2s1982 . via Gcc-patches wrote:
> > > --- /dev/null
> > > +++ b/libgomp/libgompd.map
> > > @@ -0,0 +1,49 @@
> > > +OMPD_5.0 {
> > > +  global:
> > > +     ompd_dll_locations_valid;
> >
> > ompd_dll_locations and ompd_dll_locations_valid both need to be exported,
> > but not from libgompd.so.1 but from libgomp.so.1, so they need to go into
> > libgomp.map and be defined somewhere in libgomp.so.1, so likely env.c.
> > Include omp-tools.h and plugin-suffix.h in there and move
> > ompd_dll_locations
> > definition in there (into the #ifndef LIBGOMP_OFFLOADED_ONLY section)
> > and for ompd_dll_locations_valid, e.g. make it an alias to
> > initialize_env or for the time being just an empty function with
> > __attribute__((noipa)) that initialize_env
> > calls and I'll help with making it an alias afterwards.
> >
> 
> Also, for libgomp.map, which block should I place the ompd_dll_locations
> and ompd_dll_locations_valid?

It is not block, but a symbol version what we are talking about, and please
use OMPD_5.0 for those symbols.  The general rule is once a compiler is
released with certain symbols in some symbol version no new symbols are
added to that symbol version, that is why we have OMP_5.0.1 even when there
is no OpenMP 5.0.1 standard, but we have shipped GCC 9/10 with some OMP_5.0
symbols already, so the ones added in 11 had to go into OMP_5.0.1.
And the symbol version name tries to reflect the kind of symbols too,
GOMP_* stands for implementation specific symbols, OMP_* for the OpenMP
standard mandated APIs, and OMPD_* matches that to cover the OMPD symbols.

        Jakub

Reply via email to