aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/SafeStack.cpp
diff options
context:
space:
mode:
authorGeorge Rokos <georgios.rokos@intel.com>2021-05-20 16:25:54 -0700
committerGeorge Rokos <georgios.rokos@intel.com>2021-05-21 10:52:08 -0700
commitd0bc04d6b91d6bc5f15c981da9d2b911fb578c59 (patch)
tree46693cd7e3342abd76f15eb52ef252419e3a407f /llvm/lib/CodeGen/SafeStack.cpp
parent16b284e99e4bca8d1e571310f545f10512dc979b (diff)
downloadllvm-d0bc04d6b91d6bc5f15c981da9d2b911fb578c59.zip
llvm-d0bc04d6b91d6bc5f15c981da9d2b911fb578c59.tar.gz
llvm-d0bc04d6b91d6bc5f15c981da9d2b911fb578c59.tar.bz2
[libomptarget] Fix a bug whereby firstprivates are not copied over to the device
The check for the TO flag when processing firstprivates is missing. As a result, sometimes the device copy of a firstprivate never gets initialized. Currectly we try to force lambda structs to be allocated immediately by marking them as a non-firstprivate, so that PrivateArgumentManagerTy::addArg allocates memory for them immediately. However, calling addArg with IsFirstPrivate=false makes the function skip initializing the device copy. Whether an argument is firstprivate and whether we need to allocate memory immediately are not synonyms, so this patch introduces one more control variable for immediate allocation and sets it apart from initialization. Differential Revision: https://reviews.llvm.org/D102890
Diffstat (limited to 'llvm/lib/CodeGen/SafeStack.cpp')
0 files changed, 0 insertions, 0 deletions