[libcxx-commits] [PATCH] D88301: [libc++] Clean up logic around aligned/sized allocation and deallocation

Hubert Tong via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Fri Sep 25 11:11:46 PDT 2020


hubert.reinterpretcast added a comment.

In D88301#2295423 <https://reviews.llvm.org/D88301#2295423>, @ldionne wrote:

> I think it does. The issue is that we're not detecting `_LIBCPP_HAS_NO_ALIGNED_ALLOCATION` properly.

Thanks for the quick response. I was checking whether or not Clang reliably has the aligned builtin operator new based on my reading of the patch description:

excerpt:

> By assuming that a compiler that supports the builtin new/delete operators also supports their align_val_t overloads, the code can be simplified quite a bit.

If libc++ still checks `__cpp_aligned_new`, then the patch should be okay.

> What is `__cpp_aligned_new` set to on z/OS?

It's not defined. The detection for `_LIBCPP_HAS_NO_ALIGNED_ALLOCATION` should work okay.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D88301/new/

https://reviews.llvm.org/D88301



More information about the libcxx-commits mailing list