[all-commits] [llvm/llvm-project] 1d04dc: [Coroutine] Do not CoroElide if there are musttail...
Xun Li via All-commits
all-commits at lists.llvm.org
Mon Jan 18 09:11:28 PST 2021
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: 1d04dc52dd24d791970e56053cdd67fe149b0554
https://github.com/llvm/llvm-project/commit/1d04dc52dd24d791970e56053cdd67fe149b0554
Author: Xun Li <lxfind at gmail.com>
Date: 2021-01-18 (Mon, 18 Jan 2021)
Changed paths:
M llvm/lib/Transforms/Coroutines/CoroElide.cpp
A llvm/test/Transforms/Coroutines/coro-elide-musttail.ll
Log Message:
-----------
[Coroutine] Do not CoroElide if there are musttail calls
This is to address https://bugs.llvm.org/show_bug.cgi?id=48626.
When there are musttail calls that use parameters aliasing the newly created coroutine frame, the existing implementation will fatal.
We simply cannot perform CoroElide in such cases. In theory a precise analysis can be done to check whether the parameters of the musttail call
actually alias the frame, but it's very hard to do it before the transformation happens. Also in most cases the existence of musttail call is
generated due to symmetric transfers, and in those cases alias analysis won't be able to tell that they don't alias anyway.
Differential Revision: https://reviews.llvm.org/D94834
More information about the All-commits
mailing list