[OpenMP] Fix norespect affinity bug for Windows
authorPeyton, Jonathan L <jonathan.l.peyton@intel.com>
Thu, 3 Dec 2020 18:07:33 +0000 (12:07 -0600)
committerPeyton, Jonathan L <jonathan.l.peyton@intel.com>
Wed, 9 Dec 2020 20:32:48 +0000 (14:32 -0600)
commitfe3b244ef7c2656c5876ff3f91232406f9854c42
treeb55380abe0179959eeb782a1dc05da5379819c68
parent9b7d6a6bffce14c766eaa90c7a3d3b8d192cdfb0
[OpenMP] Fix norespect affinity bug for Windows

KMP_AFFINITY=norespect was triggering an error because the underlying
process affinity mask was not updated to include the entire machine.
The Windows documentation states that the thread affinities must be
subsets of the process affinity. This patch also moves the printing
(for KMP_AFFINITY=verbose) of whether the initial mask was respected
out of each topology detection function and to one location where the
initial affinity mask is read.

Differential Revision: https://reviews.llvm.org/D92587
openmp/runtime/src/kmp.h
openmp/runtime/src/kmp_affinity.cpp
openmp/runtime/src/kmp_affinity.h