[llvm] Extend `retcon.once` coroutines lowering to optionally produce a normal result (PR #66333)

Anton Korobeynikov via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 14 10:50:08 PDT 2023

@@ -3046,7 +3046,8 @@ void coro::buildCoroutineFrame(
   // Collect the spills for arguments and other not-materializable values.
   for (Argument &A : F.args())
     for (User *U : A.users())
-      if (Checker.isDefinitionAcrossSuspend(A, U))
+      if (Checker.isDefinitionAcrossSuspend(A, U) ||
+          isa<CoroEndInst>(U))
asl wrote:

Ok, I'll give it a try. Note that this will be a C++ API breaking change though as we will always need to pass an extra argument.


More information about the llvm-commits mailing list