[Openmp-commits] [PATCH] D122667: llvm14 patch: hwloc include directory for libompd
Bernhard Kaindl via Phabricator via Openmp-commits
openmp-commits at lists.llvm.org
Fri Apr 15 19:48:47 PDT 2022
bernhardkaindl added a comment.
In D122667#3455056 <https://reviews.llvm.org/D122667#3455056>, @tianshilei1992 wrote:
> An add-up to this patch is, if both `ompd` and `omp` depend on `hwloc` (like including `hwloc` headers`), both should set `target_link_libraries`. The dependence should be:
>
> omp---->hwloc
> ^
> ompd-----|
>
> The transitive dependence is bad practice.
The dependency at the build failure is:
openmp/libompd/src/omp-icv.cpp:21:
-> openmp/runtime/src/kmp.h:96:
--> #include "hwloc.h"
The size of struct dispatch_shared_info / dispatch_shared_info_t depends on if #KMP_USE_HWLOC is set, from `openmp/runtime/src/kmp.h`
#if KMP_USE_HWLOC
// When linking with libhwloc, the ORDERED EPCC test slows down on big
// machines (> 48 cores). Performance analysis showed that a cache thrash
// was occurring and this padding helps alleviate the problem.
char padding[64];
#endif
} dispatch_shared_info_t;
ompd does not appear to use seems to use hwloc-related directly, but I'd say risking to break code just to avoid the include path in libompd does not appear to be worth any breakage.
I uploaded my revision as https://reviews.llvm.org/D123888
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D122667/new/
https://reviews.llvm.org/D122667
More information about the Openmp-commits
mailing list