[libcxx-commits] [PATCH] D129842: [libcxxabi] Fix alignment of pointers returned by fallback_malloc

Mikhail Maltsev via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Thu Jul 28 10:18:10 PDT 2022


miyuki added inline comments.


================
Comment at: libcxxabi/src/fallback_malloc.cpp:105
+// used to represent a heap_node. 'A' must be aligned so that
+// 'A + sizeof(heap_node) % RequiredAlignment == 0'. On 64 bit systems this
+// address should be 12 bytes after the first 16 byte boundary.
----------------
(A + sizeof(heap_node)) % RequiredAlignment


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D129842



More information about the libcxx-commits mailing list