From b3e7ac276ed5a7b6dff5f8381ecf8a374a694a1e Mon Sep 17 00:00:00 2001 From: Tim Janik Date: Tue, 28 Aug 2007 17:05:13 +0000 Subject: [PATCH] clarified alignment expectations for g_slice_alloc(). Tue Aug 28 19:04:12 2007 Tim Janik * glib/tmpl/memory_slices.sgml: clarified alignment expectations for g_slice_alloc(). svn path=/trunk/; revision=5724 --- docs/reference/ChangeLog | 5 +++++ docs/reference/glib/tmpl/memory_slices.sgml | 7 +++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/docs/reference/ChangeLog b/docs/reference/ChangeLog index 21afbc0f..6a003d37 100644 --- a/docs/reference/ChangeLog +++ b/docs/reference/ChangeLog @@ -1,3 +1,8 @@ +Tue Aug 28 19:04:12 2007 Tim Janik + + * glib/tmpl/memory_slices.sgml: clarified alignment + expectations for g_slice_alloc(). + 2007-08-20 Behdad Esfahbod * glib/tmpl/unicode.sgml: Document that GUnicodeScript is diff --git a/docs/reference/glib/tmpl/memory_slices.sgml b/docs/reference/glib/tmpl/memory_slices.sgml index 41f8114a..2538fa16 100644 --- a/docs/reference/glib/tmpl/memory_slices.sgml +++ b/docs/reference/glib/tmpl/memory_slices.sgml @@ -95,8 +95,11 @@ object size used at allocation time is still available when freeing. Allocates a block of memory from the slice allocator. -The block adress handed out is guaranteed to be aligned -to at least 2 * sizeof (void*). +The block adress handed out can be expected to be aligned +to at least 1 * sizeof (void*), +though in general slices are 2 * sizeof (void*) bytes aligned, +if a malloc() fallback implementation is used instead, +the alignment may be reduced in a libc dependent fashion. Note that the underlying slice allocation mechanism can be changed with the G_SLICE=always-malloc environment variable. -- 2.34.1