[llvm-bugs] [Bug 35777] New: Invalid InsertValueInst operands!

via llvm-bugs llvm-bugs at lists.llvm.org
Sat Dec 30 06:58:48 PST 2017


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

            Bug ID: 35777
           Summary: Invalid InsertValueInst operands!
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: -New Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: stephan.bergmann.secondary at googlemail.com
                CC: llvm-bugs at lists.llvm.org

At least with recent trunk towards 6.0 built with -DLLVM_ENABLE_ASSERTIONS=ON I
get the following error:

> $ cat test.cc
> struct S {
>  long a, b;
>  S(long x, long y): a(x), b(y) {}
> };
> double a[6];
> S f(double y) { return S(int(a[0] + y*a[2] + a[4]), int(a[1] + y*a[3] + a[5])); }
> 
> $ clang++ -O2 -c test.cc -v
> clang version 6.0.0 
> Target: x86_64-unknown-linux-gnu
> Thread model: posix
> InstalledDir: /home/sbergman/llvm/inst/bin
> Found candidate GCC installation: /usr/lib/gcc/x86_64-redhat-linux/7
> Selected GCC installation: /usr/lib/gcc/x86_64-redhat-linux/7
> Candidate multilib: .;@m64
> Candidate multilib: 32;@m32
> Selected multilib: .;@m64
>  "/home/sbergman/llvm/inst/bin/clang-6.0" -cc1 -triple x86_64-unknown-linux-gnu -emit-obj -disable-free -main-file-name test.cc -mrelocation-model static -mthread-model posix -fmath-errno -masm-verbose -mconstructor-aliases -munwind-tables -fuse-init-array -target-cpu x86-64 -dwarf-column-info -debugger-tuning=gdb -momit-leaf-frame-pointer -v -coverage-notes-file /home/sbergman/lo2/core/test.gcno -resource-dir /home/sbergman/llvm/inst/lib/clang/6.0.0 -internal-isystem /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7 -internal-isystem /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/x86_64-redhat-linux -internal-isystem /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/backward -internal-isystem /usr/local/include -internal-isystem /home/sbergman/llvm/inst/lib/clang/6.0.0/include -internal-externc-isystem /include -internal-externc-isystem /usr/include -O2 -fdeprecated-macro -fdebug-compilation-dir /home/sbergman/lo2/core -ferror-limit 19 -fmessage-length 113 -fobjc-runtime=gcc -fcxx-exceptions -fexceptions -fdiagnostics-show-option -vectorize-loops -vectorize-slp -o test.o -x c++ test.cc
> clang -cc1 version 6.0.0 based upon LLVM 6.0.0svn default target x86_64-unknown-linux-gnu
> ignoring nonexistent directory "/include"
> #include "..." search starts here:
> #include <...> search starts here:
>  /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7
>  /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/x86_64-redhat-linux
>  /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/backward
>  /usr/local/include
>  /home/sbergman/llvm/inst/lib/clang/6.0.0/include
>  /usr/include
> End of search list.
> Invalid InsertValueInst operands!
>   %.fca.0.insert = insertvalue { i64, i64 } undef, i32 %9, 0
> Invalid InsertValueInst operands!
>   %.fca.1.insert = insertvalue { i64, i64 } %.fca.0.insert, i32 %10, 1
> fatal error: error in backend: Broken function found, compilation aborted!
> clang-6.0: error: clang frontend command failed with exit code 70 (use -v to see invocation)
> clang version 6.0.0 
> Target: x86_64-unknown-linux-gnu
> Thread model: posix
> InstalledDir: /home/sbergman/llvm/inst/bin
> clang-6.0: 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-6.0: note: diagnostic msg: 
> ********************
> 
> PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
> Preprocessed source(s) and associated run script(s) are located at:
> clang-6.0: note: diagnostic msg: /tmp/test-bd3d95.cpp
> clang-6.0: note: diagnostic msg: /tmp/test-bd3d95.sh
> clang-6.0: note: diagnostic msg: 
> 
> ********************

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20171230/19721914/attachment-0001.html>


More information about the llvm-bugs mailing list