[llvm] [NFC][Coroutines] Remove redundant checks for replacing PrepareFns (PR #98392)

Yuxuan Chen via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 10 19:14:07 PDT 2024


================
@@ -2108,12 +2108,6 @@ PreservedAnalyses CoroSplitPass::run(LazyCallGraph::SCC &C,
   if (Coroutines.empty() && PrepareFns.empty())
     return PreservedAnalyses::all();
 
-  if (Coroutines.empty()) {
----------------
yuxuanchen1997 wrote:

Because the next lines reads "for each coroutine in Coroutines". It's the same condition the if statement is checking for, then execute the exact same logic.

https://github.com/llvm/llvm-project/pull/98392


More information about the llvm-commits mailing list