[llvm] [SimplifyCFG] Remove unused variable. NFC. (PR #134211)

Yingwei Zheng via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 3 00:21:47 PDT 2025


https://github.com/dtcxzyw created https://github.com/llvm/llvm-project/pull/134211

None

>From aafc911fa111c1aaf07fa8e882637cc6b1f2c767 Mon Sep 17 00:00:00 2001
From: Yingwei Zheng <dtcxzyw2333 at gmail.com>
Date: Thu, 3 Apr 2025 15:21:16 +0800
Subject: [PATCH] [SimplifyCFG] Remove unused variable. NFC.

---
 llvm/lib/Transforms/Utils/SimplifyCFG.cpp | 1 -
 1 file changed, 1 deletion(-)

diff --git a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp b/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
index e7c550be00b14..eac7e7c209c95 100644
--- a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
+++ b/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
@@ -6228,7 +6228,6 @@ static bool initializeUniqueCases(SwitchInst *SI, PHINode *&PHI,
   }
   // Find the default result value.
   SmallVector<std::pair<PHINode *, Constant *>, 1> DefaultResults;
-  BasicBlock *DefaultDest = SI->getDefaultDest();
   getCaseResults(SI, nullptr, SI->getDefaultDest(), &CommonDest, DefaultResults,
                  DL, TTI);
   // If the default value is not found abort unless the default destination



More information about the llvm-commits mailing list