<html>
<head>
<base href="http://llvm.org/bugs/" />
</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 --- - llc handles comparissons incorrectly, Linux, trunk, regression from version 3.4"
href="http://llvm.org/bugs/show_bug.cgi?id=20088">20088</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>llc handles comparissons incorrectly, Linux, trunk, regression from version 3.4
</td>
</tr>
<tr>
<th>Product</th>
<td>tools
</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>llc
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>ili.filippov@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvmbugs@cs.uiuc.edu
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=12684" name="attach_12684" title="Reproducer">attachment 12684</a> <a href="attachment.cgi?id=12684&action=edit" title="Reproducer">[details]</a></span>
Reproducer
In this test we assign a small values to an array and then compare them to
"100". All of them are less then 100, so we would like to have an array of "1"
as a result. But in trunk we have answer zeros.
To reproduce:
bin-3.4/bin/llc r1.ll -mattr=+avx
clang t.cpp r1.s
./a.out
1.000000
...
bin-trunk/bin/llc r1.ll -mattr=+avx
clang t.cpp r1.s
./a.out
0.000000
...
t.cpp:
#include <stdio.h>
extern "C" {
extern void f_f(float *result, float *a);
}
int main(int argc, char *argv[]) {
float returned_result[64];
float vfloat[64];
for (int i = 0; i < 64; ++i) {
vfloat[i] = i+1;
}
f_f(returned_result, vfloat);
for (int i = 0; i < 16; ++i) {
printf("%f\n", returned_result[i]);
}
return 0;
}
r1.ll is attached.
llc from trunk and 3.4 version generates very different asm files, trunk asm
file is very small and without mention of value "100".</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>