Changes from Git (git http://labmaster3.local/git/llvm-project.git)


  1. [Coroutines] Remove corresponding phi values when apply (details)
Commit 83a9321f60d837e4d41c9c08c09ab9e4c171ada4 by modocache
[Coroutines] Remove corresponding phi values when apply
Summary: In addMustTailToCoroResumes, we set musttail on those resume
instructions that are followed by a ret instruction. This is done by
simplifyTerminatorLeadingToRet which replace a sequence of branches
leading to a ret with a clone of the ret.
However it forgets to remove corresponding PHI values that come from
basic block of replaced branch, and may cause jumpthreading pass hangs
This patch fix this issue
Test Plan: cppcoro library with O3+flto check-llvm
Reviewers: modocache, GorNishanov, lewissbaker
Reviewed By: modocache
Subscribers: mehdi_amini, EricWF, hiraditya, dexonsmith, jfb,
Tags: #llvm
Differential Revision:
Patch by junparser (JunMa)!
The file was modifiedllvm/lib/Transforms/Coroutines/CoroSplit.cpp
The file was modifiedllvm/test/Transforms/Coroutines/coro-split-musttail.ll
The file was addedllvm/test/Transforms/Coroutines/coro-split-musttail1.ll