ChuanqiXu added a comment.

In D105066#2845978 <https://reviews.llvm.org/D105066#2845978>, @lxfind wrote:

> Coroutine functions cannot be inlined before splitting, even if it's marked 
> "always_inline"

Yeah, but it may be inlined  after splitting, which could trigger coro elide.

> in fact, we should make it illegal to mark a coroutine "always_inline", 
> because there is no guarantee that a coroutine can be fully inlined, GCC does 
> that

To my understanding, it looks like that we shouldn't inline it since we 
couldn't inline all parts of the function. Is this what you want to say?
I think it may be a problem that we can't inline the full coroutine. But it's 
not the reason to forbid it.

---

Coro Elide is not defined in the standard (although it comes up in the 
proposal). So it should be a compiler optimization. In this way, it should be 
OK to remove it in O0.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D105066

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to