From 7889d8e7ebde9f0b968f7816ec09920adf24e0d3 Mon Sep 17 00:00:00 2001 From: Richard Smith Date: Fri, 15 Nov 2019 12:49:35 -0800 Subject: [PATCH] Revert "[LoadStoreVectorize] Use '||' instead of '|' between sides with function calls. NFCI." This broke two tests. Presumably the non-short-circuting '|' was intentional here. This reverts commit f7efea0ded8e16c7751b378523407a491016edd6. --- .../lib/Transforms/Vectorize/LoadStoreVectorizer.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/llvm/lib/Transforms/Vectorize/LoadStoreVectorizer.cpp b/llvm/lib/Transforms/Vectorize/LoadStoreVectorizer.cpp index 15a2e2ceaeff..7478daa2a0a5 100644 --- a/llvm/lib/Transforms/Vectorize/LoadStoreVectorizer.cpp +++ b/llvm/lib/Transforms/Vectorize/LoadStoreVectorizer.cpp @@ -1004,7 +1004,7 @@ bool Vectorizer::vectorizeStoreChain( LLVM_DEBUG(dbgs() << "LSV: Chain doesn't match with the vector factor." " Creating two separate arrays.\n"); return vectorizeStoreChain(Chain.slice(0, TargetVF), - InstructionsProcessed) || + InstructionsProcessed) | vectorizeStoreChain(Chain.slice(TargetVF), InstructionsProcessed); } @@ -1022,7 +1022,7 @@ bool Vectorizer::vectorizeStoreChain( if (accessIsMisaligned(SzInBytes, AS, Alignment)) { if (S0->getPointerAddressSpace() != DL.getAllocaAddrSpace()) { auto Chains = splitOddVectorElts(Chain, Sz); - return vectorizeStoreChain(Chains.first, InstructionsProcessed) || + return vectorizeStoreChain(Chains.first, InstructionsProcessed) | vectorizeStoreChain(Chains.second, InstructionsProcessed); } @@ -1035,7 +1035,7 @@ bool Vectorizer::vectorizeStoreChain( if (!TTI.isLegalToVectorizeStoreChain(SzInBytes, Alignment, AS)) { auto Chains = splitOddVectorElts(Chain, Sz); - return vectorizeStoreChain(Chains.first, InstructionsProcessed) || + return vectorizeStoreChain(Chains.first, InstructionsProcessed) | vectorizeStoreChain(Chains.second, InstructionsProcessed); } @@ -1153,7 +1153,7 @@ bool Vectorizer::vectorizeLoadChain( if (ChainSize > VF || (VF != TargetVF && TargetVF < ChainSize)) { LLVM_DEBUG(dbgs() << "LSV: Chain doesn't match with the vector factor." " Creating two separate arrays.\n"); - return vectorizeLoadChain(Chain.slice(0, TargetVF), InstructionsProcessed) || + return vectorizeLoadChain(Chain.slice(0, TargetVF), InstructionsProcessed) | vectorizeLoadChain(Chain.slice(TargetVF), InstructionsProcessed); } @@ -1165,7 +1165,7 @@ bool Vectorizer::vectorizeLoadChain( if (accessIsMisaligned(SzInBytes, AS, Alignment)) { if (L0->getPointerAddressSpace() != DL.getAllocaAddrSpace()) { auto Chains = splitOddVectorElts(Chain, Sz); - return vectorizeLoadChain(Chains.first, InstructionsProcessed) || + return vectorizeLoadChain(Chains.first, InstructionsProcessed) | vectorizeLoadChain(Chains.second, InstructionsProcessed); } @@ -1175,7 +1175,7 @@ bool Vectorizer::vectorizeLoadChain( if (!TTI.isLegalToVectorizeLoadChain(SzInBytes, Alignment, AS)) { auto Chains = splitOddVectorElts(Chain, Sz); - return vectorizeLoadChain(Chains.first, InstructionsProcessed) || + return vectorizeLoadChain(Chains.first, InstructionsProcessed) | vectorizeLoadChain(Chains.second, InstructionsProcessed); }