<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Invalid InsertValueInst operands!"
href="https://bugs.llvm.org/show_bug.cgi?id=35777">35777</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Invalid InsertValueInst operands!
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>-New Bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>stephan.bergmann.secondary@googlemail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>At least with recent trunk towards 6.0 built with -DLLVM_ENABLE_ASSERTIONS=ON I
get the following error:
<span class="quote">> $ 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 <a href="http://llvm.org/bugs/">http://llvm.org/bugs/</a> 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:
>
> ********************</span ></pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>