-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Description
It would be useful if allocators had an associated constant of flags describing their properties, such as
- support for alignment-changing realloc (posix realloc doesn't, jemalloc does)
- does realloc try to avoid memcpy (doing virtual memory schenanigans)
- whether deallocation does anything (vs. an arena that drops all allocations at once)
- support for zero-length allocations
- if alloc_zeroed is any different from
allocate
- do realloc/dealloc care about the layout information being correct
- etc.
Containers can then choose to optimize their behavior based on those properties.
(from #120 (comment))
kornelski
Metadata
Metadata
Assignees
Labels
No labels