<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 - LICM cannot sink stores out of loops when address calculation is a bit complicated"
href="https://bugs.llvm.org/show_bug.cgi?id=48141">48141</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>LICM cannot sink stores out of loops when address calculation is a bit complicated
</td>
</tr>
<tr>
<th>Product</th>
<td>libraries
</td>
</tr>
<tr>
<th>Version</th>
<td>11.0
</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>Scalar Optimizations
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>roy.yan.luo@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=24145" name="attach_24145" title="testcase">attachment 24145</a> <a href="attachment.cgi?id=24145&action=edit" title="testcase">[details]</a></span>
testcase
For the stores *(float *restrict)(&c_Re[(i+n)*(608)+j+m]) = ..., the compiler
should be able to sink these stores out of the loop indexed by k. Since the
loop indexed by m and n are completely unrolled, the address calculation is
reduced to i*608+j+CONSTANT. If we add #pragma unroll(3) to the loop indexed by
i, these stores are sunk, my guess here is that i becomes a constant, thus now
the address is j+CONSTANT', which is easy to be analyzed in alias analysis.</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>