[Openmp-commits] [PATCH] D82301: [OpenMP][NFC] Cleanup: put two more usages of __kmp_mic_type under KMP_MIC_SUPPORTED macro.

Andrey Churbanov via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Mon Jun 29 04:17:54 PDT 2020


This revision was automatically updated to reflect the committed changes.
Closed by commit rG7f3d9cc1c059: [openmp][NFC] Cleanup: guard __kmp_mic_type by KMP_MIC_SUPPORTED macro. (authored by AndreyChurbanov).

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D82301/new/

https://reviews.llvm.org/D82301

Files:
  openmp/runtime/src/kmp_affinity.cpp


Index: openmp/runtime/src/kmp_affinity.cpp
===================================================================
--- openmp/runtime/src/kmp_affinity.cpp
+++ openmp/runtime/src/kmp_affinity.cpp
@@ -1968,7 +1968,8 @@
   __kmp_hier_max_units[kmp_hier_layer_e::LAYER_THREAD + 1] =
       nPackages * nCoresPerPkg * __kmp_nThreadsPerCore;
   __kmp_hier_max_units[kmp_hier_layer_e::LAYER_L1 + 1] = __kmp_ncores;
-#if KMP_ARCH_X86_64 && (KMP_OS_LINUX || KMP_OS_FREEBSD || KMP_OS_WINDOWS)
+#if KMP_ARCH_X86_64 && (KMP_OS_LINUX || KMP_OS_FREEBSD || KMP_OS_WINDOWS) && \
+    KMP_MIC_SUPPORTED
   if (__kmp_mic_type >= mic3)
     __kmp_hier_max_units[kmp_hier_layer_e::LAYER_L2 + 1] = __kmp_ncores / 2;
   else
@@ -1982,7 +1983,8 @@
   __kmp_hier_threads_per[kmp_hier_layer_e::LAYER_THREAD + 1] = 1;
   __kmp_hier_threads_per[kmp_hier_layer_e::LAYER_L1 + 1] =
       __kmp_nThreadsPerCore;
-#if KMP_ARCH_X86_64 && (KMP_OS_LINUX || KMP_OS_FREEBSD || KMP_OS_WINDOWS)
+#if KMP_ARCH_X86_64 && (KMP_OS_LINUX || KMP_OS_FREEBSD || KMP_OS_WINDOWS) && \
+    KMP_MIC_SUPPORTED
   if (__kmp_mic_type >= mic3)
     __kmp_hier_threads_per[kmp_hier_layer_e::LAYER_L2 + 1] =
         2 * __kmp_nThreadsPerCore;


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D82301.274053.patch
Type: text/x-patch
Size: 1185 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20200629/c6cb93a0/attachment-0001.bin>


More information about the Openmp-commits mailing list