kernel/util: Introduce BumpAllocator.

A basic bump allocator that can handle arbitrary amounts of allocations,
so long as all are allocated and freed in a "stack"-like manner.

(Actually it could be extended to support non-stack-like operation,
but that would require more logic that isn't needed at the moment.)

Change-Id: I47077146ea282600130778d312f7d86bd8c032e0
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8238
Tested-by: Commit checker robot <[email protected]>
Reviewed-by: waddlesplash <[email protected]>
Reviewed-by: Michael Lotz <[email protected]>
This commit is contained in:
Augustin Cavalier
2024-09-06 19:15:42 +00:00
committed by waddlesplash
parent ace43da6f9
commit 3be79a33b0
2 changed files with 113 additions and 0 deletions
@@ -0,0 +1 @@
#include <../private/kernel/util/BumpAllocator.h>