<html>
    <head>
      <base href="https://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 --- - Non-affine region scalar store generation dominance problem"
   href="https://llvm.org/bugs/show_bug.cgi?id=25388">25388</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Non-affine region scalar store generation dominance problem
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>Projects
          </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>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Polly
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>polly-dev@googlegroups.com
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>doerfert@cs.uni-saarland.de
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=15206" name="attach_15206" title="Testcase">attachment 15206</a> <a href="attachment.cgi?id=15206&action=edit" title="Testcase">[details]</a></span>
Testcase

I think this bug is caused by the recent change in the scalar code generation,
namely the reload/store of scalar at the beginning/end of statements (r250625).
In non-affine regions it can happen that the scalar accesses are traversed (in
order to store them) in a way that conflicts with the dominance relation inside
the non-affine region. As we only use one BBMap for the whole statement this
will cause us to reuse values that do not dominate the current position. I
tried using multiple BBMaps for the scalar codegeneration in non-affine regions
but that does not work as we loose the mappings from the region that are
actually valid. It might work to (1) use the initial mappings but no new ones
for the scalar writes or (2) to go back to the old way of scalar code
generation.</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>