Recommendation for building with -DLIBOMP_USE_HWLOC=ON

Hi,

What's the general recommendation for building openmp with
-DLIBOMP_USE_HWLOC=ON ? Is hwloc better than the default topology
code?

Thanks,
Tom

Hi Tom,

The hwloc topology discovery code is proven to be slower, but can give some NUMA awareness features.

For example on Intel Xeon Phi (KNL) it allows to bind threads to tiles (pairs of cores with shared L2 cache); and it allows to limit program affinity mask to particular NUMA node(s) inside package using KMP_HW_SUBSET environment variable.

If you don't need mentioned features than legacy topology code will work similarly but with faster initialization time.

Note also that the code base does not have hwloc library, so you will need to provide it for the build in order to use it.

Regards,
Andrey