Libc++ commit r339431 moved the _LIBCPP_HAS_NO_ALIGNED_ALLOCATION logic from <new> to <__config>. As a result, it was defined when building libc++abi's fallback_malloc.cpp, which made libc++abi think posix_memalign was unavailable. This meant that libc++abi was silently falling back to using malloc. In 32 bit builds, malloc does not return correctly aligned memory for the exception header. This is a regression in the 7.0 release. The issues was fixed in libc++abi commit r342815. This change should be merged into the 7.1 release. @Marshall, Louis, can you sign off on this?
Signed off. How did you discover the bug? We should have testers for this, no?
> How did you discover the bug? We should have testers for this, no? We do. The libc++abi 32 bit buildbot has been failing for months due to this bug [1]. I suspect it's also the cause of PR38473. [1] http://lab.llvm.org:8011/builders/libcxx-libcxxabi-x86_64-linux-ubuntu-32bit/builds/424
> > How did you discover the bug? We should have testers for this, no? > We do. The libc++abi 32 bit buildbot has been failing for months due to this bug [1]. How embarrassing -- that one's on me. > I suspect it's also the cause of PR38473. I don't think so: my reproduction for PR38473 still fails after applying your patch.
>> I suspect it's also the cause of PR38473. > > I don't think so: my reproduction for PR38473 still fails after applying your patch. Yeah, looking further, I think the analysis about the separate unwind headers on that bug seems correct.
Marshall, is this OK to merge?
(In reply to Tom Stellard from comment #5) > Marshall, is this OK to merge? Yes; this is OK to merge for 7.1
Is there any reason that this bug should not be closed?
Have we merged the commit? That would be the reason to keep this open.
I don't think the commit has been merged to the release branch for LLVM 7.1
Merged: r344917