Buffer cache | CS 162 Project 3
The functions inode_read_at and inode_write_at currently access the file system’s underlying block device directly each time you call them. Your task is to add a buffer cache for the file system, to improve the performance of reads and writes. Your buffer cache will cache individual disk blocks, so that (1) you can respond to reads with cached data and (2) you can coalesce multiple writes into a single disk operation. The buffer cache should have a maximum capacity of 64 disk blocks. You may choose the block replacement policy, but it should be an approximation of MIN based on locality assumptions. For example, using LRU, NRU (clock), n-th chance clock, or second-chance lists would be acceptable, but using FIFO, RANDOM, or MRU would not be. Choosing a replacement policy of your own design would require serious justification. The buffer cache must be a write back cache, not a write-through cache. You must make sure that all disk operations use your buffer cache, not just the two inode f
Buffer cache | CS 162 Project 3 Skip to main content Menu Expand (external link) Document Search Copy Copied CS 162 Project 3 Buffer cache The functions inode_read_at and inode_write_at currently access the file system’s underlying block device directly each time you call them. Your task is to add a buffer cache for the file system, to improve the performance of reads and writes. Your buffer cache will cache individual disk blocks, so that (1) you can respond to reads with cached data and (2) you can coalesce multiple writes into a single disk operation. The buffer cache should have a maximum
Explore this link on the map →saved by
related reading
- Dropboxdropbox.com
- Assessment 1 Practiceweb.stanford.edu
- Disk Cachechromium.org
- Circular buffer - Wikipediaen.wikipedia.org
- abseil / Performance Hintsabseil.io
- Analyzing the codebase of Caffeine: a high performance caching library | Adri’s Blogadriacabeza.github.io
- Cache Memory in Computer Organization - GeeksforGeeksgeeksforgeeks.org
- What Every Programmer Should Know About Memorypeople.freebsd.org
- Build Your Own Databasenan.fyi
- Log Structured Merge Trees | Ben Stopfordbenstopford.com
- Disks and Files - Database Systemscs186berkeley.net
- IO devices and latency — PlanetScaleplanetscale.com