https://bugs.llvm.org/show_bug.cgi?id=38154

            Bug ID: 38154
           Summary: SVN r336812 triggers assert "Assertion
                    `(allConstant(VL) || allSameType(VL)) && "Invalid
                    types!"' failed."
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Transformation Utilities
          Assignee: unassignedb...@nondot.org
          Reporter: mar...@martin.st
                CC: llvm-bugs@lists.llvm.org

Created attachment 20552
  --> https://bugs.llvm.org/attachment.cgi?id=20552&action=edit
Crash reproduction case

Since SVN r336812 (or r336804), building of quite a few different projects
start triggering asserts like this:

clang: ../lib/Transforms/Vectorize/SLPVectorizer.cpp:1391: void
llvm::slpvectorizer::BoUpSLP::buildTree_rec(llvm::ArrayRef<llvm::Value*>,
unsigned int, int): Assertion `(allConstant(VL) || allSameType(VL)) && "Invalid
types!"' failed.  
Stack dump: 
0.      Program arguments: bin/clang -cc1 -triple x86_64-w64-windows-gnu
-emit-obj -disable-free -main-file-name hb-ot-font.cc -mrelocation-model pic
-pic-level 2 -mthread-model posix -fmath-errno -masm-verbose
-mconstructor-aliases -munwind-tables -target-cpu x86-64 -dwarf-column-info
-debugger-tuning=gdb -momit-leaf-frame-pointer -coverage-notes-file
/home/martin/fate/qt/build-5.11-x86_64/src/3rdparty/harfbuzz-ng/.obj/release/hb-ot-font.gcno
-D UNICODE -D _UNICODE -D WIN32 -D WINVER=0x0601 -D _WIN32_WINNT=0x0601 -D
QT_NO_NARROWING_CONVERSIONS_IN_CONNECT -D HAVE_CONFIG_H -D HB_NO_UNICODE_FUNCS
-D HB_DISABLE_DEPRECATED -D HB_NDEBUG -D HB_EXTERN= -D HAVE_ATEXIT -D
HB_NO_WIN1256 -D QT_NO_VERSION_TAGGING -D HAVE_OT -D QT_NO_DYNAMIC_CAST -D
QT_NO_EXCEPTIONS -O2 -w -std=c++1z -fdeprecated-macro -ferror-limit 19
-fmessage-length 0 -fno-rtti -fno-use-cxa-atexit -fobjc-runtime=gcc
-fdwarf-exceptions -fdiagnostics-show-option -vectorize-loops -vectorize-slp -x
c++ hb-ot-font-f498e6.cpp  
1.      <eof> parser at end of file
2.      Per-module optimization passes 
3.      Running pass 'Function Pass Manager' on module 'hb-ot-font-f498e6.cpp'. 
4.      Running pass 'SLP Vectorizer' on function
'@_ZNK2OT4CBDT13accelerator_t11get_extentsEjP18hb_glyph_extents_t'
#0 0x00000000019a77aa llvm::sys::PrintStackTrace(llvm::raw_ostream&)
(bin/clang+
0x19a77aa)
#1 0x00000000019a5c2c llvm::sys::RunSignalHandlers() (bin/clang+0x19a5c2c)
#2 0x00000000019a5d97 SignalHandler(int) (bin/clang+0x19a5d97)
#3 0x00007f4c18821390 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x1139
0)
#4 0x00007f4c17593428 gsignal
/build/glibc-Cl5G7W/glibc-2.23/signal/../sysdeps/u
nix/sysv/linux/raise.c:54:0
#5 0x00007f4c1759502a abort /build/glibc-Cl5G7W/glibc-2.23/stdlib/abort.c:91:0
#6 0x00007f4c1758bbd7 __assert_fail_base
/build/glibc-Cl5G7W/glibc-2.23/assert/a
ssert.c:92:0
#7 0x00007f4c1758bc82 (/lib/x86_64-linux-gnu/libc.so.6+0x2dc82)
#8 0x0000000001b0fb9a
llvm::slpvectorizer::BoUpSLP::buildTree_rec(llvm::ArrayRef
<llvm::Value*>, unsigned int, int) (bin/clang+0x1b0fb9a)
#9 0x0000000001b0f9b7
llvm::slpvectorizer::BoUpSLP::buildTree_rec(llvm::ArrayRef
<llvm::Value*>, unsigned int, int) (bin/clang+0x1b0f9b7)
#10 0x0000000001b10f12
llvm::slpvectorizer::BoUpSLP::buildTree_rec(llvm::ArrayRe
f<llvm::Value*>, unsigned int, int) (bin/clang+0x1b10f12)
#11 0x0000000001b10493
llvm::slpvectorizer::BoUpSLP::buildTree_rec(llvm::ArrayRe
f<llvm::Value*>, unsigned int, int) (bin/clang+0x1b10493)
#12 0x0000000001b1122c
llvm::slpvectorizer::BoUpSLP::buildTree_rec(llvm::ArrayRe
f<llvm::Value*>, unsigned int, int) (bin/clang+0x1b1122c)
#13 0x0000000001b12900
llvm::slpvectorizer::BoUpSLP::buildTree(llvm::ArrayRef<ll
vm::Value*>, llvm::MapVector<llvm::Value*,
llvm::SmallVector<llvm::Instruction*,
 2u>, llvm::DenseMap<llvm::Value*, unsigned int,
llvm::DenseMapInfo<llvm::Value*
>, llvm::detail::DenseMapPair<llvm::Value*, unsigned int> >, std::vector<std::pa
ir<llvm::Value*, llvm::SmallVector<llvm::Instruction*, 2u> >,
std::allocator<std
::pair<llvm::Value*, llvm::SmallVector<llvm::Instruction*, 2u> > > > >&,
llvm::A
rrayRef<llvm::Value*>) (bin/clang+0x1b12900)
#14 0x0000000001b13298
llvm::slpvectorizer::BoUpSLP::buildTree(llvm::ArrayRef<ll
vm::Value*>, llvm::ArrayRef<llvm::Value*>) (bin/clang+0x1b13298)
#15 0x0000000001b14e3b
llvm::SLPVectorizerPass::vectorizeStoreChain(llvm::ArrayR
ef<llvm::Value*>, llvm::slpvectorizer::BoUpSLP&, unsigned int)
(bin/clang+0x1b14
e3b)
#16 0x0000000001b159f5
llvm::SLPVectorizerPass::vectorizeStores(llvm::ArrayRef<l
lvm::StoreInst*>, llvm::slpvectorizer::BoUpSLP&) (bin/clang+0x1b159f5)
#17 0x0000000001b161db
llvm::SLPVectorizerPass::vectorizeStoreChains(llvm::slpve
ctorizer::BoUpSLP&) (bin/clang+0x1b161db)
#18 0x0000000001b1c7de llvm::SLPVectorizerPass::runImpl(llvm::Function&,
llvm::S
calarEvolution*, llvm::TargetTransformInfo*, llvm::TargetLibraryInfo*,
llvm::AAR
esults*, llvm::LoopInfo*, llvm::DominatorTree*, llvm::AssumptionCache*,
llvm::De
mandedBits*, llvm::OptimizationRemarkEmitter*) (.part.1306)
(bin/clang+0x1b1c7de
)
#19 0x0000000001b1dba9 (anonymous
namespace)::SLPVectorizer::runOnFunction(llvm:
:Function&) (bin/clang+0x1b1dba9)

The attached files are allows reproducing this issue.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to