<html>
<head>
<base href="http://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 - missed optimization during overflow computation (seto/xor)"
href="http://bugs.llvm.org/show_bug.cgi?id=32327">32327</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>missed optimization during overflow computation (seto/xor)
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</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>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>LLVM Codegen
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>dvyukov@google.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>clang version 5.0.0 (trunk 294296)
Target: x86_64-unknown-linux-gnu
#include <inttypes.h>
bool foo(uint32_t x, uint32_t y) {
return !(((uint64_t)(x) * (uint64_t)(y)) >> 32);
}
$ clang++ overflow.cc -O3 -S -o -
# BB#0:
movl %edi, %eax
mull %esi
seto %al
xorb $1, %al
retq
.Lfunc_end0:
This should be:
movl %edi, %eax
mull %esi
setno %al
retq</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>