W27: a little big project for fun

My last post was concerned with a regex crate I was writing, which does perform quite well. Now I have revived a side project of mine, namely creating a custom operating system. This is a long-term project that I'll come back to every now and then.

Before this week-long coding spree, I had only written a few primitives like a lock-free queue and object pool, a basic interface to interact with the Limine bootloader, as well as a bare-bones bootable image that prints some text on serial post and displays a yellow line on the screen.

During the week, I have made a lot of progress, specifically: – A lot of designing is now done. Heaps of notes regarding general process and task architecture, the syscall interface, memory subsystem... – A build and macro system that splits the system into components that can be configured in many different ways. – A basic memory management system for the pre-kernel stage, which is tested upon boot. – The larger part of a small message-passing dynamic memory manager. – More primitives, like interface and process-safety traits, thread-local storage, physical addresses, page tables...

I don't intend to move fast with this one yet. An operating system is a big piece of software but the first stages of creating one are especially delicate, since one has to make a lot of decisions that will later impact how the project will unfurl. Right now I have about 4500 lines of Rust code and a general idea of what I want to do with them.

My first goal is to make a kernel that can be booted and do some serious memory management. I would like it to be configurable as either a microkernel or monolithic kernel, which may sound like a bizarre design decision but it's something I had wanted to explore. I'll keep posting about this project in the future.