summaryrefslogtreecommitdiff
path: root/lib/Transforms
diff options
context:
space:
mode:
authorStepan Dyatkovskiy <stpworld@narod.ru>2014-06-21 20:13:24 +0000
committerStepan Dyatkovskiy <stpworld@narod.ru>2014-06-21 20:13:24 +0000
commit83ac8b35e91d69222095b6952f3302ba3f43426b (patch)
tree6996b1ea1b79aa1c6f898344b91fff6d1907d3ec /lib/Transforms
parent768231880a1013e0577c94bfa7fdc8b87f901b20 (diff)
downloadllvm-83ac8b35e91d69222095b6952f3302ba3f43426b.tar.gz
llvm-83ac8b35e91d69222095b6952f3302ba3f43426b.tar.bz2
llvm-83ac8b35e91d69222095b6952f3302ba3f43426b.tar.xz
MergeFunctions Pass, removed unused methods from old implementation.
Patch removed next old FunctionComparator methods: * enumerate * isEquivalentOperation * isEquivalentGEP * isEquivalentType This patch belongs to patch series that improves MergeFunctions performance time from O(N*N) to O(N*log(N)). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@211444 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms')
-rw-r--r--lib/Transforms/IPO/MergeFunctions.cpp21
1 files changed, 0 insertions, 21 deletions
diff --git a/lib/Transforms/IPO/MergeFunctions.cpp b/lib/Transforms/IPO/MergeFunctions.cpp
index 7130b54311..8ec8ff29af 100644
--- a/lib/Transforms/IPO/MergeFunctions.cpp
+++ b/lib/Transforms/IPO/MergeFunctions.cpp
@@ -308,10 +308,6 @@ private:
/// see comments for sn_mapL and sn_mapR.
int cmpValues(const Value *L, const Value *R);
- bool enumerate(const Value *V1, const Value *V2) {
- return cmpValues(V1, V2) == 0;
- }
-
/// Compare two Instructions for equivalence, similar to
/// Instruction::isSameOperationAs but with modifications to the type
/// comparison.
@@ -338,11 +334,6 @@ private:
/// strings for particular instruction, and could change sometimes.
int cmpOperation(const Instruction *L, const Instruction *R) const;
- bool isEquivalentOperation(const Instruction *I1,
- const Instruction *I2) const {
- return cmpOperation(I1, I2) == 0;
- }
-
/// Compare two GEPs for equivalent pointer arithmetic.
/// Parts to be compared for each comparison stage,
/// most significant stage first:
@@ -357,14 +348,6 @@ private:
return cmpGEP(cast<GEPOperator>(GEPL), cast<GEPOperator>(GEPR));
}
- bool isEquivalentGEP(const GEPOperator *GEP1, const GEPOperator *GEP2) {
- return cmpGEP(GEP1, GEP2) == 0;
- }
- bool isEquivalentGEP(const GetElementPtrInst *GEP1,
- const GetElementPtrInst *GEP2) {
- return isEquivalentGEP(cast<GEPOperator>(GEP1), cast<GEPOperator>(GEP2));
- }
-
/// cmpType - compares two types,
/// defines total ordering among the types set.
///
@@ -407,10 +390,6 @@ private:
/// 6. For all other cases put llvm_unreachable.
int cmpType(Type *TyL, Type *TyR) const;
- bool isEquivalentType(Type *Ty1, Type *Ty2) const {
- return cmpType(Ty1, Ty2) == 0;
- }
-
int cmpNumbers(uint64_t L, uint64_t R) const;
int cmpAPInt(const APInt &L, const APInt &R) const;