summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
diff options
context:
space:
mode:
authorMichael Zolotukhin <mzolotukhin@apple.com>2015-03-17 20:31:56 +0000
committerMichael Zolotukhin <mzolotukhin@apple.com>2015-03-17 20:31:56 +0000
commit9ef5671d36f4be2e173b2c77626d712bb2134e81 (patch)
tree98de26f697f0e495d165bc9fb8c32518a6316f03 /llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
parent9ab09237dcfedb123340676d75e59821dac35513 (diff)
downloadbcm5719-llvm-9ef5671d36f4be2e173b2c77626d712bb2134e81.tar.gz
bcm5719-llvm-9ef5671d36f4be2e173b2c77626d712bb2134e81.zip
Try to fix a test broken by one of my previous commits.
llvm-svn: 232536
Diffstat (limited to 'llvm/lib/Transforms/Vectorize/LoopVectorize.cpp')
-rw-r--r--llvm/lib/Transforms/Vectorize/LoopVectorize.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
index 47263ff6d31..b7d0ae4478f 100644
--- a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
+++ b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
@@ -2638,6 +2638,9 @@ static Value *addFastMathFlag(Value *V) {
/// the result needs to be inserted and/or extracted from vectors.
static unsigned getScalarizationOverhead(Type *Ty, bool Insert, bool Extract,
const TargetTransformInfo &TTI) {
+ if (Ty->isVoidTy())
+ return 0;
+
assert(Ty->isVectorTy() && "Can only scalarize vectors");
unsigned Cost = 0;
OpenPOWER on IntegriCloud