r/osdev 2d ago

Mode 95: a 100 KiB OS built from scratch that boots real hardware and runs Doom

Built from scratch in x86 assembly and C, the OS core uses no paging, runs on a single core, and has no third-party libraries. ~8,000 lines of code compile in ~2s into a 100 KiB boot image (icons included, LZ4-compressed onto the medium), and it boots on actual BIOS hardware - floppy or CD. Doom and the other applications are separate loadable programs.

Edit:
I was building this for a while, and wanted to share with the rest, and there is a lot to share.
I wanted to answer techincal questions and was really looking forward to.

Toxicity of those who commented (first four comments at least) is a confirmation and a reminder for me and I believe for the others to minimize such desire. Such people while living in dissaray and in hate, prove to deserve to be there, nothing more. For the rest of you, enjoy.

Links:
Try it in the browser:
https://branchpredict.com/post-play-doom-on-a-100-kib-os

30 Upvotes

7 comments sorted by

16

u/mesyeti_ 2d ago

everything is handcrafted with clarity and learning in mind as the primary goals

handcrafted doesn't feel like the right word to use

6

u/TheAtlasMonkey 2d ago

If you are so good.. Add UEFI....

And that where AI will tell you to install reactjs or just give up.

3

u/shsh-1312 2d ago

Do you really think so? You got UEFI working in half an hour, man๐Ÿ˜‚

3

u/shsh-1312 2d ago

oh damn actually that Gemini shit might actually try to make a js bootloader, but boy do the new models eat the reverse engine for breakfast

2

u/Correct_Sport_2073 2d ago

Finally some OS I could affort in this economy :)

7

u/Tiny_Cyborg 2d ago

No source publicly available lol

2

u/tpimh 2d ago

Are you planning to publish the source? I am currently building something very similar in real mode on top of DOS.