<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><span class="vcard"><a class="email" href="mailto:trass3r@gmail.com" title="Trass3r <trass3r@gmail.com>"> <span class="fn">Trass3r</span></a>
</span> changed
<a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED DUPLICATE - Good codegen for bitwise rotate requires code that is technically undefined behavior"
href="https://bugs.llvm.org/show_bug.cgi?id=20750">bug 20750</a>
<br>
<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>What</th>
<th>Removed</th>
<th>Added</th>
</tr>
<tr>
<td style="text-align:right;">Status</td>
<td>NEW
</td>
<td>RESOLVED
</td>
</tr>
<tr>
<td style="text-align:right;">CC</td>
<td>
</td>
<td>trass3r@gmail.com
</td>
</tr>
<tr>
<td style="text-align:right;">Resolution</td>
<td>---
</td>
<td>DUPLICATE
</td>
</tr></table>
<p>
<div>
<b><a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED DUPLICATE - Good codegen for bitwise rotate requires code that is technically undefined behavior"
href="https://bugs.llvm.org/show_bug.cgi?id=20750#c11">Comment # 11</a>
on <a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED DUPLICATE - Good codegen for bitwise rotate requires code that is technically undefined behavior"
href="https://bugs.llvm.org/show_bug.cgi?id=20750">bug 20750</a>
from <span class="vcard"><a class="email" href="mailto:trass3r@gmail.com" title="Trass3r <trass3r@gmail.com>"> <span class="fn">Trass3r</span></a>
</span></b>
<pre>Your code is still UB if rot is >= 32.
Fix it to v >> (rot & 31) | v << (-rot & 31) and you also get a rot
instruction.
For more complex cases when the code gets inlined see:
<a class="bz_bug_link
bz_status_NEW "
title="NEW - [CGP] move a sub that's part of a rotate into the block with shifts+or"
href="show_bug.cgi?id=37417">https://bugs.llvm.org/show_bug.cgi?id=37417</a>
*** This bug has been marked as a duplicate of <a class="bz_bug_link
bz_status_NEW "
title="NEW - [CGP] move a sub that's part of a rotate into the block with shifts+or"
href="show_bug.cgi?id=37417">bug 37417</a> ***</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>