1

switch logger + unfinished hack

This commit is contained in:
2022-07-16 03:31:12 +02:00
parent c0a74bb81d
commit de7a7c1636
2 changed files with 41 additions and 34 deletions

View File

@ -2,6 +2,7 @@
#define __TreeAllocator_include__
#include "kernel/Allocator.h"
#include "user/lib/Logger.h"
// NOTE: I added this file
// NOTE: I can't imagine that this is very fast with all the tree logic?
@ -32,11 +33,12 @@ typedef struct tree_block {
} tree_block_t;
class TreeAllocator : Allocator {
private:
// Root of the rbt
tree_block_t* free_start;
Logger log;
TreeAllocator(Allocator& copy) = delete; // Verhindere Kopieren
// Returns the size of the usable memory of a block
@ -66,7 +68,7 @@ private:
void dll_remove(list_block_t* node);
public:
TreeAllocator() {};
TreeAllocator() : log("RBT-Alloc") {};
void init() override;
void dump_free_memory() override;