[all-commits] [llvm/llvm-project] 9f87c6: [OpenMP] Fix HWLOC topology detection for 2.0.x

Jonathan Peyton via All-commits all-commits at lists.llvm.org
Wed Jan 27 12:28:14 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 9f87c6b47df977f2be04535021e7fd08abb9376d
      https://github.com/llvm/llvm-project/commit/9f87c6b47df977f2be04535021e7fd08abb9376d
  Author: Peyton, Jonathan L <jonathan.l.peyton at intel.com>
  Date:   2021-01-27 (Wed, 27 Jan 2021)

  Changed paths:
    M openmp/runtime/src/i18n/en_US.txt
    M openmp/runtime/src/kmp.h
    M openmp/runtime/src/kmp_affinity.cpp

  Log Message:
  -----------
  [OpenMP] Fix HWLOC topology detection for 2.0.x

HWLOC 2.0 has numa nodes as separate children and are not in the main
parent/child topology tree anymore.  This change takes this into
account.  The main topology detection loop in the create_hwloc_map()
routine starts at a hardware thread within the initial affinity mask and
goes up the topology tree setting the socket/core/thread labels
correctly.

This change also introduces some of the more generic changes that the
future kmp_topology_t structure will take advantage of including a
generic ratio & count array (finding all ratios of topology layers like
threads/core cores/socket and finding all counts of each topology
layer), generic radix1 reduction step, generic uniformity check, and
generic printing of topology (en_US.txt)

Differential Revision: https://reviews.llvm.org/D95156


  Commit: 598c590b3c9684471a5186221c500b1fd7a4e325
      https://github.com/llvm/llvm-project/commit/598c590b3c9684471a5186221c500b1fd7a4e325
  Author: Peyton, Jonathan L <jonathan.l.peyton at intel.com>
  Date:   2021-01-27 (Wed, 27 Jan 2021)

  Changed paths:
    M openmp/runtime/src/i18n/en_US.txt
    M openmp/runtime/src/kmp.h
    M openmp/runtime/src/kmp_affinity.cpp
    M openmp/runtime/src/kmp_global.cpp
    M openmp/runtime/src/kmp_settings.cpp

  Log Message:
  -----------
  [OpenMP] Add cpuid leaf 1f topology discovery

This patch adds the new algorithm for topology discovery using cpuid
leaf 1f.  Only the new die level is detected and integrated into the
current affinity mechanisms including KMP_AFFINITY (granularity level
and compact/scatter algorithm), OMP_PLACES=dies, and KMP_HW_SUBSET.

Differential Revision: https://reviews.llvm.org/D95157


  Commit: 8e6713436462daa43d84f8450d07a54f7657c31b
      https://github.com/llvm/llvm-project/commit/8e6713436462daa43d84f8450d07a54f7657c31b
  Author: Peyton, Jonathan L <jonathan.l.peyton at intel.com>
  Date:   2021-01-27 (Wed, 27 Jan 2021)

  Changed paths:
    M openmp/runtime/src/kmp_settings.cpp
    A openmp/runtime/test/affinity/omp-places-invalid-syntax.c

  Log Message:
  -----------
  [OpenMP] Fix misleading warning for OMP_PLACES

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 informs the user that OMP_PLACES=cores is being used instead
of OMP_PLACES=threads.

Differential Revision: https://reviews.llvm.org/D95170


Compare: https://github.com/llvm/llvm-project/compare/ff038b316d77...8e6713436462


More information about the All-commits mailing list