[clang] [CIR] Fix cleanup ordering of coroutines (PR #230574)
via cfe-commits
cfe-commits at lists.llvm.org
Thu Oct 15 18:45:53 PDT 2026
================
@@ -3834,12 +3833,11 @@ void cir::CoroutineOp::getSuccessorRegions(
return;
}
- // destroy has two possible outcomes depending on why it was entered:
- // ordinary destroy dispatch falls through to exit (normal return); an
- // exception that reached destroy needs to keep propagating instead, i.e.
- // leave the whole op rather than go through exit's cir.return.
+ // destroy falls through to exit (normal return).
if (parent == &getDestroy()) {
regions.emplace_back(&getExit());
+ // Replace the parent edge with the unwind region once it is implemetend.
+ assert(!cir::MissingFeatures::coroUnwindRegion());
----------------
Andres-Salamanca wrote:
+1
https://github.com/llvm/llvm-project/pull/230574
More information about the cfe-commits
mailing list