[llvm] c2e0afe - [Coroutines][NFC] Remove @llvm.coro.id.async intrinsics from CoroElide (#92956)

via llvm-commits llvm-commits at lists.llvm.org
Tue May 21 18:57:48 PDT 2024


Author: Yuxuan Chen
Date: 2024-05-21T18:57:45-07:00
New Revision: c2e0afe95efd495f5c76bbea410730a321a69e9c

URL: https://github.com/llvm/llvm-project/commit/c2e0afe95efd495f5c76bbea410730a321a69e9c
DIFF: https://github.com/llvm/llvm-project/commit/c2e0afe95efd495f5c76bbea410730a321a69e9c.diff

LOG: [Coroutines][NFC] Remove @llvm.coro.id.async intrinsics from CoroElide (#92956)

Added: 
    

Modified: 
    llvm/lib/Transforms/Coroutines/CoroElide.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Transforms/Coroutines/CoroElide.cpp b/llvm/lib/Transforms/Coroutines/CoroElide.cpp
index bb244489e4c2c..74b5ccb7b9b71 100644
--- a/llvm/lib/Transforms/Coroutines/CoroElide.cpp
+++ b/llvm/lib/Transforms/Coroutines/CoroElide.cpp
@@ -464,13 +464,9 @@ bool CoroIdElider::attemptElide() {
   return true;
 }
 
-static bool declaresCoroElideIntrinsics(Module &M) {
-  return coro::declaresIntrinsics(M, {"llvm.coro.id", "llvm.coro.id.async"});
-}
-
 PreservedAnalyses CoroElidePass::run(Function &F, FunctionAnalysisManager &AM) {
   auto &M = *F.getParent();
-  if (!declaresCoroElideIntrinsics(M))
+  if (!coro::declaresIntrinsics(M, {"llvm.coro.id"}))
     return PreservedAnalyses::all();
 
   FunctionElideInfo FEI{&F};


        


More information about the llvm-commits mailing list