Bhuvan M. Acharya
The Archive
All work
Case study/Apr 2026/shipped

PTFS — Priority Tag File System

A priority-tag file system built on MIT's xv6 — touching a real kernel to learn what 'a file' actually is.

Role

Systems experiment — with madhav-kartikeya (25 commits)

Stack

C · xv6 · Filesystems · Operating systems

Source

GitHub

Problem

You don't understand a filesystem by using one. You understand it by writing one — by meeting the block layer, inodes and path resolution face to face, on an operating system small enough to hold in your head.

Motivation

MIT's xv6 is the direct way in: a real, running Unix-like kernel with nothing hidden. The project modifies its filesystem in a way that is genuinely its own, not a tutorial's.

Architecture

open, read, write — the usual xv6 interfacesUSER PROGRAMS (SYSCALLS)The MIT educational kernel PTFS modifiesXV6 KERNEL — FILESYSTEM LAYERFiles carry priority tags; retrieval respects importancePTFS — PRIORITY-TAG FILE SYSTEMFile metadata, now including the priority tagINODE TABLEBlocks on disk, grouped by priorityTAGGED DATA BLOCKSA real, bootable modified xv6 imageDISK IMAGE — BOOTS
Architecture — ptfs

Technical decisions

  • Built on xv6 rather than a toy simulation — a real boot, a real disk image, a real constraint: if it corrupts the superblock, nothing boots.
  • Priority tags as first-class file metadata, so retrieval can respect importance rather than only directory position.

Engineering challenges

Reading a C kernel codebase with no safety net; understanding the on-disk layout well enough to extend it without breaking the boot path; debugging with print statements in a world without a debugger worth the name.

Personal contribution

Collaborator: madhav-kartikeya (25 commits). My part: .

Outcome

Complete — PTFS runs on a bootable, modified xv6 image.

Lessons learned

Systems programming is mostly reading. The abstraction "file" is a treaty between eleven layers of code — you only see the treaty when you renegotiate it.

Outcome

Status: complete — PTFS runs on a bootable, modified xv6 image.