1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-02-01 05:01:59 +01:00
John McCall 51d7b85305 Use optimal layout and preserve alloca alignment in coroutine frames.
Previously, we would ignore alloca alignment when building the frame
and just use the natural alignment of the allocated type.  If an alloca
is over-aligned for its IR type, this could lead to a frame entry with
inadequate alignment for the downstream uses of the alloca.

Since highly-aligned fields also tend to produce poor layouts under a
naive layout algorithm, I've also switched coroutine frames to use the
new optimal struct layout algorithm.

In order to communicate the frame size and alignment to later passes,
I needed to set align+dereferenceable attributes on the frame-pointer
parameter of the resume function.  This is clearly the right thing to
do, but the align attribute currently seems to result in assumptions
being added during inlining that the optimizer cannot easily remove.
2020-03-26 00:51:09 -04:00
..
2020-03-18 13:53:17 -07:00
2020-03-18 13:53:17 -07:00
2020-02-18 10:49:13 +08:00
2020-02-18 10:49:13 +08:00
2020-02-12 15:57:25 +00:00
2020-01-31 14:02:33 +01:00
2020-03-18 13:53:17 -07:00
2020-02-04 17:43:59 -08:00
2020-03-18 13:53:17 -07:00