aboutsummaryrefslogtreecommitdiff
path: root/src/mem/alloc.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/mem/alloc.rs')
-rw-r--r--src/mem/alloc.rs26
1 files changed, 13 insertions, 13 deletions
diff --git a/src/mem/alloc.rs b/src/mem/alloc.rs
index e104293..f3a8c8d 100644
--- a/src/mem/alloc.rs
+++ b/src/mem/alloc.rs
@@ -127,7 +127,7 @@ impl<'a, T: Sized,const COUNT: usize> QueueAllocator<'a, T, COUNT> {
}
_ => {}
}
- vprintln!("QA: Allocating {:x}", unsafe{(*entry).ptr() as usize});
+ vprintln!("QA: \x1b[92mAllocated {:x}\x1b[0m", unsafe{(*entry).ptr() as usize});
return Some(unsafe{&mut *entry as &mut QueueItem<'a,T>});
} else {
vprintln!("QA: No chunks available!");
@@ -156,7 +156,7 @@ impl<'a, T: Sized,const COUNT: usize> QueueAllocator<'a, T, COUNT> {
}
}
pool[1].next = Some(freed_item as *mut QueueItem<'a,T>);
- vprintln!("QA: Deallocated {:x}", freed_item.ptr() as usize);
+ vprintln!("QA: \x1b[91mDeallocated {:x}\x1b[0m", freed_item.ptr() as usize);
});
}
}
@@ -257,27 +257,27 @@ init_queue!(U4096_GRAND_ALLOC, GRAND_ALLOC_SIZE, {U4096::new()}, U4096);
impl GrandAllocator {
pub fn init(&self) -> Result<(), &'static str> {
- vprintln!("GA: Init U8 Pool");
+ vprintln!("GA: \x1b[93mInit U8 Pool\x1b[0m");
U8_GRAND_ALLOC.init();
- vprintln!("GA: Init U16 Pool");
+ vprintln!("GA: \x1b[93mInit U16 Pool\x1b[0m");
U16_GRAND_ALLOC.init();
- vprintln!("GA: Init U32 Pool");
+ vprintln!("GA: \x1b[93mInit U32 Pool\x1b[0m");
U32_GRAND_ALLOC.init();
- vprintln!("GA: Init U64 Pool");
+ vprintln!("GA: \x1b[93mInit U64 Pool\x1b[0m");
U64_GRAND_ALLOC.init();
- vprintln!("GA: Init U128 Pool");
+ vprintln!("GA: \x1b[93mInit U128 Pool\x1b[0m");
U128_GRAND_ALLOC.init();
- vprintln!("GA: Init U256 Pool");
+ vprintln!("GA: \x1b[93mInit U256 Pool\x1b[0m");
U256_GRAND_ALLOC.init();
- vprintln!("GA: Init U512 Pool");
+ vprintln!("GA: \x1b[93mInit U512 Pool\x1b[0m");
U512_GRAND_ALLOC.init();
- vprintln!("GA: Init U1024 Pool");
+ vprintln!("GA: \x1b[93mInit U1024 Pool\x1b[0m");
U1024_GRAND_ALLOC.init();
- vprintln!("GA: Init U2048 Pool");
+ vprintln!("GA: \x1b[93mInit U2048 Pool\x1b[0m");
U2048_GRAND_ALLOC.init();
- vprintln!("GA: Init U4096 Pool");
+ vprintln!("GA: \x1b[93mInit U4096 Pool\x1b[0m");
U4096_GRAND_ALLOC.init();
- vprintln!("GA: Pools Initialized!");
+ vprintln!("GA: \x1b[94mPools Initialized!\x1b[0m");
Ok(())
}
}