When OMP_PLACES contains an invalid value, the warning informs the user
that the fallback is OMP_PLACES=threads, but the actual internal setting
is OMP_PLACES=cores and is detected as such with KMP_SETTINGS=1.
This patch fixes the warning message to display that OMP_PLACES=cores will be used.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
In my quick test, env KMP_SETTINGS=1 OMP_PROC_BIND=spread ./a.out reports OMP_PLACES='cores'. I could not find the code path that sets places to cores in this case, but I think it would be more consistent to have consistent setting in the unset and the invalid case.
Is there a reason to choose threads?
Comment Actions
Internally here at Intel we did have it at threads at one point, then somehow it got changed, and this was just to change it back to threads. It would be more consistent to have it default to OMP_PLACES=cores because of the case you mentioned and KMP_AFFINITY defaults to core granularity as well. @AndreyChurbanov , are you ok with keeping it as OMP_PLACES="cores" and just changing the warning message to cores instead?
clang-tidy: warning: invalid case style for function '__kmp_omp_places_syntax_warn' [readability-identifier-naming]
not useful
clang-tidy: warning: invalid case style for parameter 'var' [readability-identifier-naming]
not useful