diff options
| author | Jonathan Peyton <jonathan.l.peyton@intel.com> | 2018-04-18 19:25:48 +0000 |
|---|---|---|
| committer | Jonathan Peyton <jonathan.l.peyton@intel.com> | 2018-04-18 19:25:48 +0000 |
| commit | 1482db9e03f00dc646c02b0bbc1652ca9d31557f (patch) | |
| tree | fbc65f67f52b603c61806db2f2c1c004785a5da9 /clang/lib/Sema/SemaOpenMP.cpp | |
| parent | 27a677fc95c77d9cc31762bb1dd11da3173de8a1 (diff) | |
| download | bcm5719-llvm-1482db9e03f00dc646c02b0bbc1652ca9d31557f.tar.gz bcm5719-llvm-1482db9e03f00dc646c02b0bbc1652ca9d31557f.zip | |
[OpenMP] Fix affinity API for KMP_AFFINITY=none|compact|scatter
Currently, the affinity API reports garbage for the initial place list and any
thread's place lists when using KMP_AFFINITY=none|compact|scatter.
This patch does two things:
for KMP_AFFINITY=none, Creates a one entry table for the places, this way, the
initial place list is just a single place with all the proc ids in it. We also
set the initial place of any thread to 0 instead of KMP_PLACE_ALL so that the
thread reports that single place (place 0) instead of garbage (-1) when using
the affinity API.
When non-OMP_PROC_BIND affinity is used
(including KMP_AFFINITY=compact|scatter), a thread's place list is populated
correctly. We assume that each thread is assigned to a single place. This is
implemented in two of the affinity API functions
Differential Revision: https://reviews.llvm.org/D45527
llvm-svn: 330283
Diffstat (limited to 'clang/lib/Sema/SemaOpenMP.cpp')
0 files changed, 0 insertions, 0 deletions

