summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenModule.cpp
diff options
context:
space:
mode:
authorGor Nishanov <GorNishanov@gmail.com>2017-05-24 02:38:26 +0000
committerGor Nishanov <GorNishanov@gmail.com>2017-05-24 02:38:26 +0000
commit4c2f68fd7cb06adf873f8f5b83c121329a1e85e6 (patch)
tree1ed51a65a0c701cbcb101072b30c3d1cf2284249 /clang/lib/CodeGen/CodeGenModule.cpp
parentfd9100e056e6417335bc839d35daa549e9848bee (diff)
downloadbcm5719-llvm-4c2f68fd7cb06adf873f8f5b83c121329a1e85e6.tar.gz
bcm5719-llvm-4c2f68fd7cb06adf873f8f5b83c121329a1e85e6.zip
[coroutines] Implement correct GRO lifetime
Summary: Sema creates a declaration for gro variable as: auto $gro = $promise.get_return_object(); However, gro variable has to outlive coroutine frame and coroutine promise, but, it can only be initialized after the coroutine promise was created, thus, we split its emission in two parts: EmitGroAlloca emits an alloca and sets up the cleanups. Later when the coroutine promise is available we initialize the gro and set the flag that the cleanup is now active. Duplicate of: https://reviews.llvm.org/D31670 (which arc patch refuses to apply for some reason) Reviewers: GorNishanov, rsmith Reviewed By: GorNishanov Subscribers: EricWF, cfe-commits Differential Revision: https://reviews.llvm.org/D33477 llvm-svn: 303716
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud