<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 - Consider lowering the i686-windows DataLayout alignment of i64 to 32 bits"
   href="https://bugs.llvm.org/show_bug.cgi?id=35215">35215</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Consider lowering the i686-windows DataLayout alignment of i64 to 32 bits
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>libraries
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Windows NT
          </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>Backend: X86
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>rnk@google.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>This is my current triple and datalayout for x86 Windows:

target datalayout = "e-m:x-p:32:32-i64:64-f80:32-n8:16:32-a:0:32-S32"
target triple = "i386-pc-windows-msvc19.11.25508"

We should reconsider the i64:64 part and consider adding f64:32:64.

My argument for doing this is that "ABI" alignment in LLVM is a little too
overloaded. It is used for the alignment used in LLVM struct layout in addition
to some other things like va_arg lowering.

The reality is that i64 arguments and stack allocations are generally not
aligned, and you can't assume that any unadorned i64 load is really 8 byte
aligned. However, in structs, 64-bit integers and doubles are naturally
aligned. Since struct layout is mainly a frontend responsibility at this point,
we should be able to lower LLVM's alignment without affecting clang.

This is similar to how we implemented -malign-double in clang without changing
LLVM.</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>