[llvm] [SROA][NFC] Remove Unused Parameter in `promoteAllocas()` (PR #128382)
via llvm-commits
llvm-commits at lists.llvm.org
Sat Feb 22 16:25:07 PST 2025
https://github.com/veera-sivarajan created https://github.com/llvm/llvm-project/pull/128382
Removing it because `Function &F` is not used by `promoteAllocas()`.
>From 8f8479bd76ac9d75a8228cf6ec19b9abef654508 Mon Sep 17 00:00:00 2001
From: Veera <sveera.2001 at gmail.com>
Date: Sun, 23 Feb 2025 00:20:42 +0000
Subject: [PATCH] [SROA][NFC] Remove Unused Parameter in `promoteAllocas()`
---
llvm/lib/Transforms/Scalar/SROA.cpp | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/llvm/lib/Transforms/Scalar/SROA.cpp b/llvm/lib/Transforms/Scalar/SROA.cpp
index e88c130cccf20..69e7ce83f82e4 100644
--- a/llvm/lib/Transforms/Scalar/SROA.cpp
+++ b/llvm/lib/Transforms/Scalar/SROA.cpp
@@ -252,7 +252,7 @@ class SROA {
std::pair<bool /*Changed*/, bool /*CFGChanged*/> runOnAlloca(AllocaInst &AI);
void clobberUse(Use &U);
bool deleteDeadInstructions(SmallPtrSetImpl<AllocaInst *> &DeletedAllocas);
- bool promoteAllocas(Function &F);
+ bool promoteAllocas();
};
} // end anonymous namespace
@@ -5693,7 +5693,7 @@ bool SROA::deleteDeadInstructions(
/// This attempts to promote whatever allocas have been identified as viable in
/// the PromotableAllocas list. If that list is empty, there is nothing to do.
/// This function returns whether any promotion occurred.
-bool SROA::promoteAllocas(Function &F) {
+bool SROA::promoteAllocas() {
if (PromotableAllocas.empty())
return false;
@@ -5750,7 +5750,7 @@ std::pair<bool /*Changed*/, bool /*CFGChanged*/> SROA::runSROA(Function &F) {
}
}
- Changed |= promoteAllocas(F);
+ Changed |= promoteAllocas();
Worklist = PostPromotionWorklist;
PostPromotionWorklist.clear();
More information about the llvm-commits
mailing list