[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Libunwind-devel] [PATCH 10/57] Apply UNW_ALIGN more in src/mi/mempool.c
From: |
Tommi Rantala |
Subject: |
[Libunwind-devel] [PATCH 10/57] Apply UNW_ALIGN more in src/mi/mempool.c |
Date: |
Fri, 21 Sep 2012 14:11:11 +0300 |
Apply UNW_ALIGN in a few places in src/mi/mempool.c that I missed in
commit c2f757418 ("Rename and share `ALIGN' macro from
_UCD_internal.h").
---
src/mi/mempool.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/mi/mempool.c b/src/mi/mempool.c
index 5e42219..e567904 100644
--- a/src/mi/mempool.c
+++ b/src/mi/mempool.c
@@ -115,7 +115,7 @@ expand (struct mempool *pool)
GET_MEMORY (mem, size);
if (!mem)
{
- size = (pool->obj_size + pg_size - 1) & -pg_size;
+ size = UNW_ALIGN(pool->obj_size, pg_size);
GET_MEMORY (mem, size);
if (!mem)
{
@@ -149,7 +149,7 @@ mempool_init (struct mempool *pool, size_t obj_size, size_t
reserve)
pool->obj_size = obj_size;
pool->reserve = reserve;
- pool->chunk_size = (2*reserve*obj_size + pg_size - 1) & -pg_size;
+ pool->chunk_size = UNW_ALIGN(2*reserve*obj_size, pg_size);
expand (pool);
}
--
1.7.9.5
- [Libunwind-devel] [PATCH 08/57] Use __sync builtin atomics on all architectures if available, (continued)
- [Libunwind-devel] [PATCH 08/57] Use __sync builtin atomics on all architectures if available, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 01/57] Pull attribute macros from `libunwind_i.h' to new header `compiler.h', Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 07/57] Remove unneeded `cmpxchg_ptr()' from include/libunwind_i.h, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 06/57] Simplify `sos_alloc()' implementation, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 04/57] Workaround non-power-of-two i386 sizeof(long double) in src/mi/mempool.c, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 15/57] HPPA: kludge out unused variable in unw_get_save_loc() stub, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 05/57] Align `sos_memory' to MAX_ALIGN, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 10/57] Apply UNW_ALIGN more in src/mi/mempool.c,
Tommi Rantala <=
- [Libunwind-devel] [PATCH 13/57] PPC: remove unused `PAGE_START' macro from Ginit.c, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 09/57] Invert tdep_init() flag logic, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 14/57] HPPA: properly check dwarf_get() return value in unw_step(), Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 17/57] Clear out `ip' to avoid -Wuninitialized warning in tests/test-coredump-unwind.c, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 20/57] Annotate potentially unused variable in tests/Gtest-bt.c, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 12/57] Remove unused src/x86_64/Lis_signal_frame.c, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 16/57] Default to non-verbose mode in Ltest-cxx-exceptions, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 11/57] IA64: avoid -Wunused-but-set-variable in src/ia64/init.h, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 18/57] Avoid -Wunused-value warning in tests/Gia64-test-stack.c, Tommi Rantala, 2012/09/21
- [Libunwind-devel] [PATCH 26/57] Cleanup dynamically allocated memory before exit in tests, Tommi Rantala, 2012/09/21