back to home

phil-opp / blog_os

Writing an OS in Rust

17,356 stars
1,196 forks
94 issues
HTMLSCSSCSS

AI Architecture Analysis

This repository is indexed by RepoMind. By analyzing phil-opp/blog_os in our AI interface, you can instantly generate complete architecture diagrams, visualize control flows, and perform automated security audits across the entire codebase.

Our Agentic Context Augmented Generation (Agentic CAG) engine loads full source files into context on-demand, avoiding the fragmentation of traditional RAG systems. Ask questions about the architecture, dependencies, or specific features to see it in action.

Source files are only loaded when you start an analysis to optimize performance.

Embed this Badge

Showcase RepoMind's analysis directly in your repository's README.

[![Analyzed by RepoMind](https://img.shields.io/badge/Analyzed%20by-RepoMind-4F46E5?style=for-the-badge)](https://repomind.in/repo/phil-opp/blog_os)
Preview:Analyzed by RepoMind

Repository Overview (README excerpt)

Crawler view

Blog OS This repository contains the source code for the _Writing an OS in Rust_ series at os.phil-opp.com. If you have questions, open an issue or chat with us on Gitter. Where is the code? The code for each post lives in a separate git branch. This makes it possible to see the intermediate state after each post. **The code for the latest post is available [here][latest-post].** [latest-post]: https://github.com/phil-opp/blog_os/tree/post-12 You can find the branch for each post by following the link in the post list below. The branches are named where is the post number, for example for the _VGA Text Mode_ post or for the _Hardware Interrupts_ post. For build instructions, see the Readme of the respective branch. You can check out a branch in a subdirectory using [git worktree]: [git worktree]: https://git-scm.com/docs/git-worktree The above command creates a subdirectory named that contains the code for the 10th post ("Heap Allocation"). Posts The goal of this project is to provide step-by-step tutorials in individual blog posts. We currently have the following set of posts: **Bare Bones:** • A Freestanding Rust Binary (source code) • A Minimal Rust Kernel (source code) • VGA Text Mode (source code) • Testing (source code) **Interrupts:** • CPU Exceptions (source code) • Double Faults (source code) • Hardware Interrupts (source code) **Memory Management:** • Introduction to Paging (source code) • Paging Implementation (source code) • Heap Allocation (source code) • Allocator Designs (source code) **Multitasking**: • Async/Await (source code) First Edition Posts The current version of the blog is already the second edition. The first edition is outdated and no longer maintained, but might still be useful. The posts of the first edition are: Click to expand **Bare Bones:** • A Minimal x86 Kernel (source code) • Entering Long Mode (source code) • Set Up Rust (source code) • Printing to Screen (source code) **Memory Management:** • Allocating Frames (source code) • Page Tables (source code) • Remap the Kernel (source code) • Kernel Heap (source code) **Exceptions:** • Handling Exceptions (source code) • Double Faults (source code) **Additional Resources:** • Cross Compile Binutils • Cross Compile libcore • Set Up GDB • Handling Exceptions using Naked Functions • Catching Exceptions (source code) • Better Exception Messages (source code) • Returning from Exceptions (source code) License This project, with exception of the folder, is licensed under either of • Apache License, Version 2.0 (LICENSE-APACHE or https://www.apache.org/licenses/LICENSE-2.0) • MIT license (LICENSE-MIT or https://opensource.org/licenses/MIT) at your option. For licensing of the folder, see the . Contribution Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.