Page MenuHomePhabricator

Limit COFF 'common' emission to <=32 alignment types.

Authored by erichkeane on Jan 7 2019, 7:44 AM.



As reported in PR33035, LLVM crashes if given a common object with an
alignment of greater than 32 bits. This is because the COFF file format
does not support these alignments, so emitting them is broken anyway.

This patch changes any global definitions greater than 32 bit alignment
to no longer be in 'common'.

Diff Detail

rC Clang

Event Timeline

erichkeane created this revision.Jan 7 2019, 7:44 AM
majnemer added inline comments.Jan 7 2019, 12:41 PM

I think this should be isKnownWindowsMSVCEnvironment

erichkeane updated this revision to Diff 180650.Jan 8 2019, 6:16 AM
erichkeane marked an inline comment as done.
pengfei accepted this revision.Jan 8 2019, 6:19 AM

LGTM, thanks Erich.

This revision is now accepted and ready to land.Jan 8 2019, 6:19 AM
This revision was automatically updated to reflect the committed changes.