We give aligned pointers from the `sos_memory' array, so any non-aligned
bytes are only wasted.
---
src/mi/mempool.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/mi/mempool.c b/src/mi/mempool.c
index 3355265..f00e29b 100644
--- a/src/mi/mempool.c
+++ b/src/mi/mempool.c
@@ -1,6 +1,7 @@
/* libunwind - a platform-independent unwind library
Copyright (C) 2002-2003, 2005 Hewlett-Packard Co
Contributed by David Mosberger-Tang <[email protected]>
+ Copyright (C) 2012 Tommi Rantala <[email protected]>
This file is part of libunwind.
@@ -38,7 +39,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE. */
#define MAX_ALIGN MAX_ALIGN_(sizeof (long double))
#endif
-static char sos_memory[SOS_MEMORY_SIZE];
+static char sos_memory[SOS_MEMORY_SIZE] __attribute__((aligned(MAX_ALIGN)));
static char *sos_memp;
static size_t pg_size;
--
1.7.9.5
_______________________________________________
Libunwind-devel mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/libunwind-devel