https://llvm.org/bugs/show_bug.cgi?id=26974
Bug ID: 26974 Summary: crash on valid code at -O3 in 64-bit mode on x86_64-linux-gnu (Assertion `L->isLCSSAForm(*DT)' failed) Product: clang Version: trunk Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: -New Bugs Assignee: unassignedclangb...@nondot.org Reporter: chengnian...@gmail.com CC: llvm-bugs@lists.llvm.org Classification: Unclassified $: clang-trunk -v clang version 3.9.0 (trunk 263641) Target: x86_64-unknown-linux-gnu Thread model: posix InstalledDir: /usr/local/bin Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/5.3.0 Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.8 Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.8.5 Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.9 Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.9.2 Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.9.3 Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5.3.0 Selected GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.8 Candidate multilib: .;@m64 Candidate multilib: 32;@m32 Candidate multilib: x32;@mx32 Selected multilib: .;@m64 $: $: clang-trunk -m64 small.c -O3 -c clang-3.9: /tmp/llvm-builder/llvm-source-trunk/lib/Transforms/Scalar/IndVarSimplify.cpp:695: void {anonymous}::IndVarSimplify::rewriteFirstIterationLoopExitValues(llvm::Loop*): Assertion `L->isLCSSAForm(*DT)' failed. 0 clang-3.9 0x0000000001abe055 llvm::sys::PrintStackTrace(llvm::raw_ostream&) + 37 1 clang-3.9 0x0000000001abbe06 llvm::sys::RunSignalHandlers() + 54 2 clang-3.9 0x0000000001abc031 3 libpthread.so.0 0x00007f5cad58b340 4 libc.so.6 0x00007f5cac7a9cc9 gsignal + 57 5 libc.so.6 0x00007f5cac7ad0d8 abort + 328 6 libc.so.6 0x00007f5cac7a2b86 7 libc.so.6 0x00007f5cac7a2c32 8 clang-3.9 0x000000000197d4c8 9 clang-3.9 0x0000000002289287 llvm::LPPassManager::runOnFunction(llvm::Function&) + 1431 10 clang-3.9 0x0000000001777ab3 llvm::FPPassManager::runOnFunction(llvm::Function&) + 643 11 clang-3.9 0x000000000226b680 12 clang-3.9 0x000000000177817f llvm::legacy::PassManagerImpl::run(llvm::Module&) + 751 13 clang-3.9 0x0000000001be80a8 clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::CodeGenOptions const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::DataLayout const&, llvm::Module*, clang::BackendAction, llvm::raw_pwrite_stream*) + 3144 14 clang-3.9 0x00000000021726ec 15 clang-3.9 0x000000000248b1eb clang::ParseAST(clang::Sema&, bool, bool) + 571 16 clang-3.9 0x000000000217287e clang::CodeGenAction::ExecuteAction() + 78 17 clang-3.9 0x0000000001ec5696 clang::FrontendAction::Execute() + 534 18 clang-3.9 0x0000000001ea1f5e clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 318 19 clang-3.9 0x0000000001f4948c clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 2300 20 clang-3.9 0x00000000009e2a98 cc1_main(llvm::ArrayRef<char const*>, char const*, void*) + 2344 21 clang-3.9 0x000000000099e895 main + 6213 22 libc.so.6 0x00007f5cac794ec5 __libc_start_main + 245 23 clang-3.9 0x00000000009dea44 Stack dump: 0. Program arguments: /usr/local/clang-trunk/bin/clang-3.9 -cc1 -triple x86_64-unknown-linux-gnu -emit-obj -disable-free -main-file-name small.c -mrelocation-model static -mthread-model posix -fmath-errno -masm-verbose -mconstructor-aliases -munwind-tables -fuse-init-array -target-cpu x86-64 -momit-leaf-frame-pointer -dwarf-column-info -debugger-tuning=gdb -coverage-file /home/cnsun/temp/clang-shal/small.c -resource-dir /usr/local/clang-trunk/bin/../lib/clang/3.9.0 -c-isystem . -c-isystem /usr/local/include/csmith-2.2.0/ -internal-isystem /usr/local/include -internal-isystem /usr/local/clang-trunk/bin/../lib/clang/3.9.0/include -internal-externc-isystem /usr/include/x86_64-linux-gnu -internal-externc-isystem /include -internal-externc-isystem /usr/include -O3 -fdebug-compilation-dir /home/cnsun/temp/clang-shal -ferror-limit 19 -fmessage-length 126 -fobjc-runtime=gcc -fdiagnostics-show-option -fcolor-diagnostics -vectorize-loops -vectorize-slp -o small.o -x c small.c 1. <eof> parser at end of file 2. Per-module optimization passes 3. Running pass 'CallGraph Pass Manager' on module 'small.c'. 4. Running pass 'Loop Pass Manager' on function '@fn1' 5. Running pass 'Induction Variable Simplification' on basic block '%for.cond13' clang-3.9: error: unable to execute command: Aborted (core dumped) clang-3.9: error: clang frontend command failed due to signal (use -v to see invocation) clang version 3.9.0 (trunk 263641) Target: x86_64-unknown-linux-gnu Thread model: posix InstalledDir: /usr/local/bin clang-3.9: note: diagnostic msg: PLEASE submit a bug report to http://llvm.org/bugs/ and include the crash backtrace, preprocessed source, and associated run script. clang-3.9: note: diagnostic msg: ******************** PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT: Preprocessed source(s) and associated run script(s) are located at: clang-3.9: note: diagnostic msg: /home/cnsun/ramdisk/tmp/small-9083e8.c clang-3.9: note: diagnostic msg: /home/cnsun/ramdisk/tmp/small-9083e8.sh clang-3.9: note: diagnostic msg: ******************** $: $: clang-trunk -m64 small.c -O2 -c $: $: cat small.c int a, c; #define H(x, y, z) x ^ z void fn1() { int i = 0, b = 0, d, t; for (; i < 80; i++) t = c; a = 0; for (; i < 0; a++) ; for (; a < 40; i++) b = d = t; for (; i; i++) { d = t; t = b; } for (;;) b = H(b, , d) + b; } $: -- 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