[OPENMP]Fix PR37283: Assertion failure on openmp task with by reference
authorAlexey Bataev <a.bataev@hotmail.com>
Wed, 13 Mar 2019 20:46:28 +0000 (20:46 +0000)
committerAlexey Bataev <a.bataev@hotmail.com>
Wed, 13 Mar 2019 20:46:28 +0000 (20:46 +0000)
commitab41ea6282a75c3ece5cef037ced75f3f7acc724
tree0178b23b113ba4038b9b9a51f092e6a07c612ff1
parentf653e56a6773ca1ba52f45d8ea89307fe16d3868
[OPENMP]Fix PR37283: Assertion failure on openmp task with by reference
array.

If the firstprivate variable is a reference, we may incorrectly classify
the kind of the private copy. Use the type of the private copy instead
of the original shared variable.

llvm-svn: 356098
clang/lib/CodeGen/CGOpenMPRuntime.cpp
clang/test/OpenMP/task_firstprivate_codegen.cpp