getFoldedOffsetOf no longer does anything special with vector types.
authorDan Gohman <gohman@apple.com>
Sat, 5 Jun 2010 00:47:34 +0000 (00:47 +0000)
committerDan Gohman <gohman@apple.com>
Sat, 5 Jun 2010 00:47:34 +0000 (00:47 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@105514 91177308-0d34-0410-b5e6-96231b3b80d8

lib/VMCore/ConstantFold.cpp

index 549977c2342ebb2501f612f3d8ce64be02b5b21b..c854c852a95a0961772b727fd1d7ec88e8fc7ccf 100644 (file)
@@ -658,7 +658,7 @@ Constant *llvm::ConstantFoldCastInstruction(unsigned opc, Constant *V,
               }
             }
           // Handle an offsetof-like expression.
-          if (Ty->isStructTy() || Ty->isArrayTy() || Ty->isVectorTy()){
+          if (Ty->isStructTy() || Ty->isArrayTy(){
             if (Constant *C = getFoldedOffsetOf(Ty, CE->getOperand(2),
                                                 DestTy, false))
               return C;