[cfe-dev] Rewrite of codegen-level struct/union layout

Chris Lattner clattner at apple.com
Wed May 21 22:17:47 PDT 2008

On May 21, 2008, at 7:37 AM, Eli Friedman wrote:

> Per subject, attached patch almost completely rewrites the
> struct/union algorithm.  The new version is a lot simpler; some of
> that was refactoring code, and some of that was depending a lot more
> on the information already calculated by the ASTContext.
> Depending on the ASTContext to do struct layout should make it easier
> to add support for constructs like packed and aligned, because this
> will pick up any changes in the way the ASTContext does struct layout
> for free.
> On a side note, after I finished this patch, PHP compiled with clang
> started working.  I'm not sure if I fixed a struct layout bug, or some
> other change in my tree helped, but it was crashing on startup before
> this patch, and now it passes most of its testsuite (although this is
> with most of the extensions disabled).

Very nice!


More information about the cfe-dev mailing list