From e76ddfa9ef718a8b9b13fb76ac8ee061015175c6 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Fri, 30 Jul 2021 08:56:49 -0700 Subject: [PATCH] [Transforms] Remove HasValueForBlock (NFC) The function seems to be unused for at least one year. --- llvm/include/llvm/Transforms/Utils/SSAUpdaterBulk.h | 4 ---- llvm/lib/Transforms/Utils/SSAUpdaterBulk.cpp | 6 ------ 2 files changed, 10 deletions(-) diff --git a/llvm/include/llvm/Transforms/Utils/SSAUpdaterBulk.h b/llvm/include/llvm/Transforms/Utils/SSAUpdaterBulk.h index 3a78e22..5de575a 100644 --- a/llvm/include/llvm/Transforms/Utils/SSAUpdaterBulk.h +++ b/llvm/include/llvm/Transforms/Utils/SSAUpdaterBulk.h @@ -70,10 +70,6 @@ public: /// rewritten value when RewriteAllUses is called. void AddUse(unsigned Var, Use *U); - /// Return true if the SSAUpdater already has a value for the specified - /// variable in the specified block. - bool HasValueForBlock(unsigned Var, BasicBlock *BB); - /// Perform all the necessary updates, including new PHI-nodes insertion and /// the requested uses update. /// diff --git a/llvm/lib/Transforms/Utils/SSAUpdaterBulk.cpp b/llvm/lib/Transforms/Utils/SSAUpdaterBulk.cpp index 917d5e0..7de76b8 100644 --- a/llvm/lib/Transforms/Utils/SSAUpdaterBulk.cpp +++ b/llvm/lib/Transforms/Utils/SSAUpdaterBulk.cpp @@ -65,12 +65,6 @@ void SSAUpdaterBulk::AddUse(unsigned Var, Use *U) { Rewrites[Var].Uses.push_back(U); } -/// Return true if the SSAUpdater already has a value for the specified variable -/// in the specified block. -bool SSAUpdaterBulk::HasValueForBlock(unsigned Var, BasicBlock *BB) { - return (Var < Rewrites.size()) ? Rewrites[Var].Defines.count(BB) : false; -} - // Compute value at the given block BB. We either should already know it, or we // should be able to recursively reach it going up dominator tree. Value *SSAUpdaterBulk::computeValueAt(BasicBlock *BB, RewriteInfo &R, -- 2.7.4