[PATCH] D100415: [Coroutines] Split coroutine during CoroEarly into an init and ramp function

Chuanqi Xu via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 15 19:10:26 PDT 2021


ChuanqiXu added a comment.

In D100415#2691666 <https://reviews.llvm.org/D100415#2691666>, @lxfind wrote:

> @ChuanqiXu Thank you for the detailed review! Really appreciate it.
> I agree we should create a coroutine benchmark at some point, ideally some realistic production-code driven benchmark. We can work on that in the future. For this patch, it's probably not worth it to hide it behind an option, for two reasons: 1) it would be extremely complicated, 2) most parameters would end up on the frame anyway 3) this patch actually doesn't force parameters to be put on the frame. Before frame creation, all the parameters are put back to allocas, the current alloca analysis and optimization still applies to them. So some parameters may actually end up not put on the frame. So I wouldn't expect this to increase frame size in most cases.
>
> I will add documentation latter once the we all agree on the high-level idea/direction of this patch.

Thanks for the disclaimer. Although I am not familiar with many details in this patch, the high-level idea looks good to me.



================
Comment at: llvm/lib/Transforms/Coroutines/CoroSplit.cpp:2231
 // coroutine.
 struct CoroSplitLegacy : public CallGraphSCCPass {
   static char ID; // Pass identification, replacement for typeid
----------------
I am not familiar with the policy in LLVM that how should we treat LegacyPass in trunk. I mean, are we responsible to update the LegacyPassManager?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D100415/new/

https://reviews.llvm.org/D100415



More information about the llvm-commits mailing list