Skip to content

Commit 0028ef6

Browse files
[llvm] Remove unused local variables (NFC) (#167106)
Identified with bugprone-unused-local-non-trivial-variable.
1 parent ee0652b commit 0028ef6

File tree

5 files changed

+0
-8
lines changed

5 files changed

+0
-8
lines changed

llvm/lib/CAS/UnifiedOnDiskCache.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -331,8 +331,6 @@ Expected<ValidationResult> UnifiedOnDiskCache::validateIfNeeded(
331331
if (Error E = getBootTime().moveInto(BootTime))
332332
return std::move(E);
333333

334-
std::string LogValidationError;
335-
336334
if (ValidationBootTime == BootTime && !ForceValidation)
337335
return ValidationResult::Skipped;
338336

llvm/lib/CodeGen/WindowsSecureHotPatching.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -461,8 +461,6 @@ static bool searchConstantExprForGlobalVariables(
461461
Value *V, SmallDenseMap<GlobalVariable *, Value *> &GVLoadMap,
462462
SmallVector<GlobalVariableUse> &GVUses) {
463463

464-
SmallVector<Value *, 8> ReplacedOperands;
465-
466464
if (GlobalVariable *GV = dyn_cast<GlobalVariable>(V)) {
467465
if (globalVariableNeedsRedirect(GV)) {
468466
GVLoadMap[GV] = nullptr;

llvm/lib/Target/ARM/ARMLowOverheadLoops.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1051,7 +1051,6 @@ bool LowOverheadLoop::ValidateLiveOuts() {
10511051
// check where it gets its false lanes from, if any.
10521052
int InactiveIdx = findVPTInactiveOperandIdx(*MI);
10531053
if (InactiveIdx != -1) {
1054-
SmallPtrSet<MachineInstr *, 2> Defs;
10551054
MachineInstr *FalseSrc = RDI.getUniqueReachingMIDef(
10561055
MI, MI->getOperand(InactiveIdx).getReg());
10571056
if (FalseSrc) {

llvm/lib/Transforms/IPO/SampleProfile.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2293,7 +2293,6 @@ bool SampleProfileLoader::runOnFunction(Function &F,
22932293
// count value.
22942294
if (!F.getEntryCount())
22952295
F.setEntryCount(ProfileCount(initialEntryCount, Function::PCT_Real));
2296-
std::unique_ptr<OptimizationRemarkEmitter> OwnedORE;
22972296
auto &FAM = AM.getResult<FunctionAnalysisManagerModuleProxy>(*F.getParent())
22982297
.getManager();
22992298
ORE = &FAM.getResult<OptimizationRemarkEmitterAnalysis>(F);

llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5368,7 +5368,6 @@ class BoUpSLP {
53685368
Lane = P.first->ReorderIndices[Lane];
53695369
assert(Lane < static_cast<int>(P.first->Scalars.size()) &&
53705370
"Couldn't find extract lane");
5371-
SmallVector<unsigned> OpIndices;
53725371
for (unsigned OpIdx :
53735372
seq<unsigned>(::getNumberOfPotentiallyCommutativeOps(
53745373
P.first->getMainOp()))) {
@@ -8815,7 +8814,6 @@ void BoUpSLP::buildExternalUses(
88158814
const ExtraValueToDebugLocsMap &ExternallyUsedValues) {
88168815
const size_t NumVectScalars = ScalarToTreeEntries.size() + 1;
88178816
DenseMap<Value *, unsigned> ScalarToExtUses;
8818-
SmallPtrSet<Value *, 4> ExternalUsers;
88198817
// Collect the values that we need to extract from the tree.
88208818
for (auto &TEPtr : VectorizableTree) {
88218819
TreeEntry *Entry = TEPtr.get();

0 commit comments

Comments
 (0)