This is an archive of the discontinued LLVM Phabricator instance.

[ADT] Align unique_function::CallImpl when using clang on Windows
AbandonedPublic

Authored by chandlerc on Jul 3 2018, 5:06 AM.

Details

Reviewers
hans
Summary

This is a follow-up to r336178.

This would be one way of working around the alignment problem.

Actually, it would be enough to just check for clang here, because even at -Os we will not emit functions with less than 4-byte alignment.

It's not very pretty though. Is this class performance sensitive enough that it's worth the complexity of packing flags into the function pointer, or could we trade size for simplicity and just store the flags in another byte?

Diff Detail

Event Timeline

hans created this revision.Jul 3 2018, 5:06 AM
hans updated this revision to Diff 153897.Jul 3 2018, 5:11 AM

Trying not to get the #ifdefs backwards..

chandlerc commandeered this revision.Jul 6 2018, 6:51 PM
chandlerc edited reviewers, added: hans; removed: chandlerc.

Sorry I didn't update this, but went with just completely nuking this as it didn't seem that reliable even with Clang.

chandlerc abandoned this revision.Jul 6 2018, 6:51 PM