https://bugs.kde.org/show_bug.cgi?id=466104

--- Comment #4 from Paul Floyd <pjfl...@wanadoo.fr> ---
musl memalign seems to behave like jemalloc / FreeBSD

Illumos is different

https://github.com/illumos/illumos-gate/blob/master/usr/src/lib/libc/port/gen/memalign.c

It doesn't accept a size of 0. Min alignment is 8. What are MAX_ALIGN
MAX_MALLOC MINSIZE ?

#define MINSIZE         (sizeof (TREE) - sizeof (WORD))
#define MAX_MALLOC (size_t)(SIZE_MAX - CORESIZE - 3 * ALIGN) /* overflow chk */
#define MAX_ALIGN       (1 + (size_t)SSIZE_MAX)

nbytes gets clamped to MINSIZE
align gets bumped up to be the next power of 2 above MINSIZE + WORDSIZE

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to