1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 16:17:45 +00:00

Kernel: Add kfree_sized(), kfree() with a known allocation size

C++14 gave us sized operator delete, but we haven't been taking
advantage of it. Let's get to a point where it can help us by
adding kfree_sized(void*, size_t).
This commit is contained in:
Andreas Kling 2021-07-11 13:19:33 +02:00
parent 98080497d2
commit d38b4e4665
2 changed files with 11 additions and 4 deletions

View file

@ -42,6 +42,7 @@ void kmalloc_init();
void* krealloc(void*, size_t);
void kfree(void*);
void kfree_sized(void*, size_t);
struct kmalloc_stats {
size_t bytes_allocated;