[PATCH] D145641: [Coroutines] Implement fix for cwg2563 issue and enable RVO under certain conditions
Bruno Cardoso Lopes via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Mar 8 19:15:28 PST 2023
bruno created this revision.
bruno added reviewers: ChuanqiXu, clang-language-wg.
Herald added subscribers: hoy, modimo, wenlei.
Herald added a project: All.
bruno requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
- The cwg2563 issue is fixed by delaying GRO initialization only when the types mismatch between GRO and function return.
- When the types match, directly initialize, enabling RVO to kick in as introduced in https://reviews.llvm.org/D117087
Background:
https://github.com/llvm/llvm-project/issues/56532
https://cplusplus.github.io/CWG/issues/2563.html
https://github.com/cplusplus/papers/issues/1414
Depends on D145639 <https://reviews.llvm.org/D145639>
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D145641
Files:
clang/include/clang/AST/StmtCXX.h
clang/lib/CodeGen/CGCoroutine.cpp
clang/lib/Sema/SemaCoroutine.cpp
clang/lib/Sema/TreeTransform.h
clang/test/SemaCXX/coroutine-no-move-ctor.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D145641.503599.patch
Type: text/x-patch
Size: 10954 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230309/8eb6a223/attachment.bin>
More information about the cfe-commits
mailing list