From c90d4af8750bef77ce9abe91df80d5d98ba297d7 Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Tue, 29 Oct 2024 14:37:19 -0400 Subject: alloc: Don't require size % align == 0 Allowing unaligned sizes will allow us to allocate aligned slabs with additional metadata in the tail without ballooning the allocation size for large alignments. Link: https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2244.htm#dr_460 Link: https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2072.htm --- build/has/aligned-alloc.c | 8 -------- 1 file changed, 8 deletions(-) delete mode 100644 build/has/aligned-alloc.c (limited to 'build/has') diff --git a/build/has/aligned-alloc.c b/build/has/aligned-alloc.c deleted file mode 100644 index 4460038..0000000 --- a/build/has/aligned-alloc.c +++ /dev/null @@ -1,8 +0,0 @@ -// Copyright © Tavian Barnes -// SPDX-License-Identifier: 0BSD - -#include - -int main(void) { - return !aligned_alloc(_Alignof(void *), sizeof(void *)); -} -- cgit v1.2.3