[PATCH] D33030: [libcxxabi] Align unwindHeader on a double-word boundary

2017-06-20 Thread Stephan Bergmann via Phabricator via cfe-commits
sberg added a comment. In LibreOffice we unfortunately have some dirty code that synthesizes exception throwing, calling `__cxa_allocate_exception`, `__cxa_throw` (passing in our own exception destructor function), and then, when the exception destructor function gets called, assumes we can map

[PATCH] D33030: [libcxxabi] Align unwindHeader on a double-word boundary

2017-05-10 Thread Akira Hatanaka via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL302763: [libcxxabi] Align unwindHeader on a double-word boundary. (authored by ahatanak). Changed prior to commit: https://reviews.llvm.org/D33030?vs=98401&id=98583#toc Repository: rL LLVM https://r

[PATCH] D33030: [libcxxabi] Align unwindHeader on a double-word boundary

2017-05-10 Thread Mehdi AMINI via Phabricator via cfe-commits
mehdi_amini accepted this revision. mehdi_amini added a comment. This revision is now accepted and ready to land. In https://reviews.llvm.org/D33030#751723, @ahatanak wrote: > If field unwindHeader is annotated with the aligned attribute, both the field > and struct __cxa_exception are aligned.

[PATCH] D33030: [libcxxabi] Align unwindHeader on a double-word boundary

2017-05-10 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. In https://reviews.llvm.org/D33030#751187, @mehdi_amini wrote: > Something still isn't clear to me: the issue IIUC is not with the > `unwindHeader` itself, but with the misaligned thrown object that is > allocated right after the __cxa_exception itself. Isn't it? > > T

[PATCH] D33030: [libcxxabi] Align unwindHeader on a double-word boundary

2017-05-10 Thread Mehdi AMINI via Phabricator via cfe-commits
mehdi_amini added a comment. Something still isn't clear to me: the issue IIUC is not with the `unwindHeader` itself, but with the misaligned thrown object that is allocated right after the __cxa_exception itself. Isn't it? Then are you aligning the `unwindHeader` field and by side-effect the s

[PATCH] D33030: [libcxxabi] Align unwindHeader on a double-word boundary

2017-05-09 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak created this revision. r276215 made a change to annotate _Unwind_Exception with "__attribute__((__aligned__))" so that exception objects are double-word aligned. This fix hasn't been incorporated to unwind.h on Darwin yet and, since it is an ABI breaking change, I'm not sure it will e