Blog

Pintos- Getting to know OS

January 17, 2024 | 1 Minute Read

To understand operating system , pintos provides an interactive test environment to understand fundamentals in an amicable manner. There are 4 projects and as we progress , we’ll build intuition for the practicality of thread , semaphore, scheduling , process management

What is PINTOS

To test out our fundamentals, PINTOS assigment provides test cases that gets us compfortable with concepts. You can read official Pintos documentation

Setup:

Use VScode extension dev containers, it will facilitate debugging the gdb server remotely from local machine

Project 1:

Stage 1:

alarm-single alarm-multiple alarm-simultaneous alarm-zero alarm-negative

TODO: Replace busy wait with more effient approach.

LEARN: Concepts of busy wait, semaphore, lock, thread structure

Stage 2:

priority-change priority-preempt priority-fifo priority-sema priority-condvar priority-donate-one priority-donate-multiple priority-donate-multiple2 priority-donate-nest priority-donate-chain priority-donate-sema priority-donate-lower alarm-priority

TODO: Implement priority scheduling

LEARN:

  • How threads are maintained in different list based on their current state
  • How the status is supposed to changed and relegation happens

Stage 3:

TODO: Multilevel Feedback Queue

LEARN:

  • How to achieve fairness in Roundrobin scheduling ny utilising parameters


Project 2:

  1. Parse Argument and push to INTR frame stack pointer
  2. Extract argument from interupt frame in syscall
  3. Parametrize the arguments with respective types and call specific system calls. responsibilty is delegated to system calls that runs at kernel level
  4. Once you are in syshandler, we have to concentrate on test cases and sync the flow to get required output.

Project 3:

Project 4: