[llvm] 7c8176e - [Coroutines] Remove unused function (NFC)
Jie Fu via llvm-commits
llvm-commits at lists.llvm.org
Wed May 15 07:09:12 PDT 2024
Author: Jie Fu
Date: 2024-05-15T22:08:17+08:00
New Revision: 7c8176ebd39c357fc4fa488861318409cd87d8f2
URL: https://github.com/llvm/llvm-project/commit/7c8176ebd39c357fc4fa488861318409cd87d8f2
DIFF: https://github.com/llvm/llvm-project/commit/7c8176ebd39c357fc4fa488861318409cd87d8f2.diff
LOG: [Coroutines] Remove unused function (NFC)
llvm-project/llvm/lib/Transforms/Coroutines/CoroSplit.cpp:1223:1:
error: unused function 'scanPHIsAndUpdateValueMap' [-Werror,-Wunused-function]
scanPHIsAndUpdateValueMap(Instruction *Prev, BasicBlock *NewBlock,
^
1 error generated.
Added:
Modified:
llvm/lib/Transforms/Coroutines/CoroSplit.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/Coroutines/CoroSplit.cpp b/llvm/lib/Transforms/Coroutines/CoroSplit.cpp
index 450ea82343715..1d9cf185b75a7 100644
--- a/llvm/lib/Transforms/Coroutines/CoroSplit.cpp
+++ b/llvm/lib/Transforms/Coroutines/CoroSplit.cpp
@@ -1217,23 +1217,6 @@ static void postSplitCleanup(Function &F) {
#endif
}
-// Assuming we arrived at the block NewBlock from Prev instruction, store
-// PHI's incoming values in the ResolvedValues map.
-static void
-scanPHIsAndUpdateValueMap(Instruction *Prev, BasicBlock *NewBlock,
- DenseMap<Value *, Value *> &ResolvedValues) {
- auto *PrevBB = Prev->getParent();
- for (PHINode &PN : NewBlock->phis()) {
- auto V = PN.getIncomingValueForBlock(PrevBB);
- // See if we already resolved it.
- auto VI = ResolvedValues.find(V);
- if (VI != ResolvedValues.end())
- V = VI->second;
- // Remember the value.
- ResolvedValues[&PN] = V;
- }
-}
-
// Coroutine has no suspend points. Remove heap allocation for the coroutine
// frame if possible.
static void handleNoSuspendCoroutine(coro::Shape &Shape) {
More information about the llvm-commits
mailing list