[PATCH] D27215: [SLP] Fix for PR6246: vectorization for scalar ops on vector elements.

Artem Belevich via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 1 15:02:40 PST 2016


Reverted in r288431

On Thu, Dec 1, 2016 at 2:52 PM, Artem Belevich <tra at google.com> wrote:

> r288412 appears to cause severe regression compiling few clang files w/
> optimizations enabled.
> Compilation of clang/lib/Basic/Warnings.cpp takes forever now (didn't
> finish after 15 minutes) with all the time spent in SLPVectorizer.
>
> Reproduction:
> * do release build of clang ()
> # bin/clang --version
> clang version 4.0.0 (trunk 288414) (llvm/trunk 288417)
> Target: x86_64-unknown-linux-gnu
> Thread model: posix
> InstalledDir: /usr/local/google/home/tra/work/llvm/build/gpu/release/bin
>
> * compile clang/lib/Basic/Warnings.cpp with -O3:
> bin/clang -v -DCLANG_ENABLE_ARCMT -DCLANG_ENABLE_OBJC_REWRITER
> -DCLANG_ENABLE_STATIC_ANALYZER -DGTEST_HAS_RTTI=0 -D_DEBUG -D_GNU_SOURCE
> -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
> -Itools/clang/lib/Basic -I../../../tools/clang/lib/Basic
> -I../../../tools/clang/include -Itools/clang/include -Iinclude
> -I../../../include -fPIC -fvisibility-inlines-hidden -Wall -W
> -Wno-unused-parameter -Wwrite-strings -Wcast-qual
> -Wmissing-field-initializers -pedantic -Wno-long-long
> -Wcovered-switch-default -Wnon-virtual-dtor -Wdelete-non-virtual-dtor
> -Werror=date-time -std=c++11 -fcolor-diagnostics -ffunction-sections
> -fdata-sections -fno-common -Woverloaded-virtual -Wno-nested-anon-types -O3
>    -UNDEBUG  -fno-exceptions -fno-rtti -MMD -MT tools/clang/lib/Basic/
> CMakeFiles/clangBasic.dir/Warnings.cpp.o -MF tools/clang/lib/Basic/
> CMakeFiles/clangBasic.dir/Warnings.cpp.o.d -o tools/clang/lib/Basic/
> CMakeFiles/clangBasic.dir/Warnings.cpp.o -c ../../../tools/clang/lib/
> Basic/Warnings.cpp
>
> Typical stack trace:
>
> #0  0x0000000001bfb043 in llvm::SLPVectorizerPass::
> tryToVectorizeList(llvm::ArrayRef<llvm::Value*>,
> llvm::slpvectorizer::BoUpSLP&, llvm::ArrayRef<llvm::Value*>, bool) ()
> #1  0x0000000001bf83c3 in llvm::SLPVectorizerPass::
> vectorizeChainsInBlock(llvm::BasicBlock*, llvm::slpvectorizer::BoUpSLP&)
> ()
> #2  0x0000000001bf73b0 in llvm::SLPVectorizerPass::runImpl(llvm::Function&,
> llvm::ScalarEvolution*, llvm::TargetTransformInfo*,
> llvm::TargetLibraryInfo*, llvm::AAResults*, llvm::LoopInfo*,
> llvm::DominatorTree*, llvm::AssumptionCache*, llvm::DemandedBits*) ()
> #3  0x0000000001c00392 in (anonymous namespace)::SLPVectorizer::runOnFunction(llvm::Function&)
> ()
> #4  0x0000000001682b7f in llvm::FPPassManager::runOnFunction(llvm::Function&)
> ()
> #5  0x0000000001682dd3 in llvm::FPPassManager::runOnModule(llvm::Module&)
> ()
> #6  0x00000000016832d5 in llvm::legacy::PassManagerImpl::run(llvm::Module&)
> ()
> #7  0x0000000001c44097 in clang::EmitBackendOutput(clang::DiagnosticsEngine&,
> clang::CodeGenOptions const&, clang::TargetOptions const&,
> clang::LangOptions const&, llvm::DataLayout const&, llvm::Module*,
> clang::BackendAction, std::unique_ptr<llvm::raw_pwrite_stream,
> std::default_delete<llvm::raw_pwrite_stream> >) ()
> #8  0x0000000002380a74 in clang::BackendConsumer::
> HandleTranslationUnit(clang::ASTContext&) ()
> #9  0x0000000002850d05 in clang::ParseAST(clang::Sema&, bool, bool) ()
> #10 0x0000000002049728 in clang::FrontendAction::Execute() ()
> #11 0x000000000200f971 in clang::CompilerInstance::ExecuteAction(clang::FrontendAction&)
> ()
> #12 0x00000000020e351b in clang::ExecuteCompilerInvocation(clang::CompilerInstance*)
> ()
> #13 0x0000000000807b5e in cc1_main(llvm::ArrayRef<char const*>, char
> const*, void*) ()
>
>
>
> On Thu, Dec 1, 2016 at 12:16 PM, Alexey Bataev via Phabricator via
> llvm-commits <llvm-commits at lists.llvm.org> wrote:
>
>> This revision was automatically updated to reflect the committed changes.
>> Closed by commit rL288412: [SLP] Fix for PR6246: vectorization for scalar
>> ops on vector elements. (authored by ABataev).
>>
>> Changed prior to commit:
>>   https://reviews.llvm.org/D27215?vs=79588&id=79966#toc
>>
>> Repository:
>>   rL LLVM
>>
>> https://reviews.llvm.org/D27215
>>
>> Files:
>>   llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp
>>   llvm/trunk/test/Transforms/SLPVectorizer/X86/insert-element-
>> build-vector.ll
>>
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at lists.llvm.org
>> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
>>
>>
>
>
> --
> --Artem Belevich
>



-- 
--Artem Belevich
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161201/5a53bd52/attachment.html>


More information about the llvm-commits mailing list