<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 --- - backend crash with large structure variables"
   href="http://llvm.org/bugs/show_bug.cgi?id=21671">21671</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>backend crash with large structure variables
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>3.5
          </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>LLVM Codegen
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedclangbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>Dale.Martin@mathworks.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=13395" name="attach_13395" title="An example that crashes when process with llc">attachment 13395</a> <a href="attachment.cgi?id=13395&action=edit" title="An example that crashes when process with llc">[details]</a></span>
An example that crashes when process with llc

The X86 backend crashes when compiling the attached example that has load/store
of large structures "alloca"ed on the stack. It looks like a merge_values
instruction with more than 16k children gets generated, despite the fact that
the number is stored in an unsigned short.

Note that if you slight reduce the number of nested fields, the example will
generate code it takes many minutes and generates thousands of discrete movb
instructions.

The workaround is to directly call memcpy instead of using load/store but this
seems like it is intended to work as is and that an optimization should be
responsible for generating the memcpy and that it should not have to come from
a front-end directly.</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>