From 388f4918fbd8349a6c5b8403e31f65aa3408add6 Mon Sep 17 00:00:00 2001 From: Nick Lewycky Date: Wed, 26 Jan 2011 08:50:18 +0000 Subject: [PATCH] There are no vectors of pointer or arrays, so we don't need to check vector elements for type equivalence. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124284 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Transforms/IPO/MergeFunctions.cpp | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/lib/Transforms/IPO/MergeFunctions.cpp b/lib/Transforms/IPO/MergeFunctions.cpp index 15b6c56b667..8aa7cb24b95 100644 --- a/lib/Transforms/IPO/MergeFunctions.cpp +++ b/lib/Transforms/IPO/MergeFunctions.cpp @@ -295,6 +295,7 @@ bool FunctionComparator::isEquivalentType(const Type *Ty1, // Fall through in Release mode. case Type::IntegerTyID: case Type::OpaqueTyID: + case Type::VectorTyID: // Ty1 == Ty2 would have returned true earlier. return false; @@ -353,13 +354,6 @@ bool FunctionComparator::isEquivalentType(const Type *Ty1, return ATy1->getNumElements() == ATy2->getNumElements() && isEquivalentType(ATy1->getElementType(), ATy2->getElementType()); } - - case Type::VectorTyID: { - const VectorType *VTy1 = cast(Ty1); - const VectorType *VTy2 = cast(Ty2); - return VTy1->getNumElements() == VTy2->getNumElements() && - isEquivalentType(VTy1->getElementType(), VTy2->getElementType()); - } } }