[libc-commits] [PATCH] D149863: [libc] Maintain proper alignment for the hermetic tests malloc

Siva Chandra via Phabricator via libc-commits libc-commits at lists.llvm.org
Thu May 4 09:55:46 PDT 2023


sivachandra added inline comments.


================
Comment at: libc/test/UnitTest/HermeticTestUtils.cpp:66
+  // Keep the bump pointer aligned on an eight byte boundary.
+  s = ((s + 8 - 1) / 8) * 8;
   void *mem = ptr;
----------------
Is it 8 that we want or is it `alignof(uintptr_t)`?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D149863



More information about the libc-commits mailing list