diff options
Diffstat (limited to 'llvm')
-rw-r--r-- | llvm/lib/Transforms/Scalar/NewGVN.cpp | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/llvm/lib/Transforms/Scalar/NewGVN.cpp b/llvm/lib/Transforms/Scalar/NewGVN.cpp index ab195e4000c..d09a1daf608 100644 --- a/llvm/lib/Transforms/Scalar/NewGVN.cpp +++ b/llvm/lib/Transforms/Scalar/NewGVN.cpp @@ -308,7 +308,6 @@ private: PHIExpression *createPHIExpression(Instruction *); const VariableExpression *createVariableExpression(Value *); const ConstantExpression *createConstantExpression(Constant *); - const Expression *createVariableOrConstant(Value *V); const UnknownExpression *createUnknownExpression(Instruction *); const StoreExpression *createStoreExpression(StoreInst *, MemoryAccess *); LoadExpression *createLoadExpression(Type *, Value *, LoadInst *, @@ -671,13 +670,6 @@ const VariableExpression *NewGVN::createVariableExpression(Value *V) { return E; } -const Expression *NewGVN::createVariableOrConstant(Value *V) { - auto Leader = lookupOperandLeader(V); - if (auto *C = dyn_cast<Constant>(Leader)) - return createConstantExpression(C); - return createVariableExpression(Leader); -} - const ConstantExpression *NewGVN::createConstantExpression(Constant *C) { auto *E = new (ExpressionAllocator) ConstantExpression(C); E->setOpcode(C->getValueID()); |