https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114765

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
(In reply to Stijn De Weirdt from comment #2)
> apologies for my ignorance, but how is working as expected? i can't make
> this up from the description of the variable; and it's unexpected since
> there is no openmp code being run (naively then; clearly libgomp does
> something).

libgomp has library constructors which already do something.

> we have an environment where we set OMP_PROC_BIND=true because openmp code
> clearly benefits from it; but it also affects code where libgomp is simply
> linked to it, but nothing else is done with it.

See the OpenMP standard.  By using that env variable (or similar), you request
that the initial thread binds to a certain CPU/thread (the OMP_PROC_BIND=true
case is less specified than when using say OMP_PLACES and exact rules which
thread binds to which place).

Reply via email to