[OPENMP] Handle re-declaration of captured variables in CodeGen.
authorAlexey Bataev <a.bataev@hotmail.com>
Fri, 22 Sep 2017 16:56:13 +0000 (16:56 +0000)
committerAlexey Bataev <a.bataev@hotmail.com>
Fri, 22 Sep 2017 16:56:13 +0000 (16:56 +0000)
commitb7f18c3297df93b1245893b97b549e369f4e8f9c
treeb7f832ddc8dbc6a03c912bb7cd47c0477ed96012
parent09273239d1e17e1079a07238ecc384ec5479c06f
[OPENMP] Handle re-declaration of captured variables in CodeGen.

If the captured variable has re-declaration we may end up with the
situation where the captured variable is the re-declaration while the
referenced variable is the canonical declaration (or vice versa). In
this case we may generate wrong code. Patch fixes this situation.

llvm-svn: 313995
clang/lib/CodeGen/CodeGenFunction.h
clang/test/OpenMP/target_codegen.cpp