[libc-commits] [libc] [libc] Fix internal alignment in allcoator	(PR #146738)
    Shilei Tian via libc-commits 
    libc-commits at lists.llvm.org
       
    Wed Jul  2 09:56:04 PDT 2025
    
    
  
================
@@ -10,7 +10,7 @@ TEST_MAIN(int, char **, char **) {
   // aligned_alloc with valid alignment and size
   void *ptr = LIBC_NAMESPACE::aligned_alloc(32, 16);
   EXPECT_NE(ptr, nullptr);
-  EXPECT_EQ(__builtin_is_aligned(ptr, 32), 0U);
+  EXPECT_TRUE(__builtin_is_aligned(ptr, 32));
----------------
shiltian wrote:
So it is not aligned to alignment before even we call `aligned_alloc`?
https://github.com/llvm/llvm-project/pull/146738
    
    
More information about the libc-commits
mailing list