[Openmp-commits] [PATCH] D40624: Eliminate double printing of verbose affinity settings

Jonathan Peyton via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Wed Nov 29 14:56:49 PST 2017


jlpeyton created this revision.
jlpeyton added a project: OpenMP.

Redundant extra verbose output of binding to full mask in case affinity=balanced or OMP_PLACES=<any> or OMP_PROC_BIND=<any>


Repository:
  rOMP OpenMP

https://reviews.llvm.org/D40624

Files:
  runtime/src/kmp_affinity.cpp


Index: runtime/src/kmp_affinity.cpp
===================================================================
--- runtime/src/kmp_affinity.cpp
+++ runtime/src/kmp_affinity.cpp
@@ -4467,7 +4467,9 @@
 
   KMP_CPU_COPY(th->th.th_affin_mask, mask);
 
-  if (__kmp_affinity_verbose) {
+  if (__kmp_affinity_verbose
+      /* to avoid duplicate printing (will be correctly printed on barrier) */
+      && (__kmp_affinity_type == affinity_none || i != KMP_PLACE_ALL)) {
     char buf[KMP_AFFIN_MASK_PRINT_LEN];
     __kmp_affinity_print_mask(buf, KMP_AFFIN_MASK_PRINT_LEN,
                               th->th.th_affin_mask);


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D40624.124827.patch
Type: text/x-patch
Size: 615 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20171129/499007e7/attachment.bin>


More information about the Openmp-commits mailing list