<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Fri, Sep 9, 2016 at 10:45 AM, Friedman, Eli via cfe-commits <span dir="ltr"><<a href="mailto:cfe-commits@lists.llvm.org" target="_blank">cfe-commits@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
  
  <div bgcolor="#FFFFFF" text="#000000">
    <div>It probably makes sense to say that
      alloca should have the same alignment as the default stack
      alignment, simply because it's hard to do anything useful with
      completely unaligned memory.  That said, the default stack
      alignment is 4 bytes on 32-bit Windows, not 16.<br></div></div></blockquote><div><br></div><div>Well, if the allocated size is dynamic, it would seem preferable to provide a pointer that's suitably-aligned for anything that can fit within it, and even on 32-bit x86 that means 16 byte alignment if we want to support SSE. But if the size is known, there doesn't seem to be any need to provide an alignment greater than the allocated size.</div></div></div></div>