solulubeta
Sign in
Cheat Sheets / CS Theory
01.01 · Cheat sheet

Operating Systems

Processes and threads, CPU scheduling, synchronisation, deadlocks, memory, paging and disk scheduling on one page.

3 min Cheat sheet Pro

The OS questions that come up in almost every technical round, in one place.

Process vs thread

ProcessThread
MemoryIts own address spaceShares code, data and heap; own stack and registers
Create / switchSlow (heavy)Fast (light)
CommunicateIPC: pipes, sockets, shared memory, message queuesShared variables (need locks)
If it crashesOthers usually keep runningCan take the whole process down

States: New → Ready → Running → Waiting → Terminated. PCB stores the PID, state, program counter, registers, memory info and open files.

CPU scheduling

AlgorithmKey point
FCFSSimple; a long job blocks short ones (convoy effect)
SJFLowest average waiting time; long jobs can starve
SRTFPreemptive SJF
PriorityStarvation → fix with aging
Round RobinTime quantum; good response time
Multilevel feedback queueJobs move between queues by behaviour
  • Turnaround = Completion − Arrival
  • Waiting = Turnaround − Burst
  • Response = First run − Arrival
solulu Pro

Continue this cheat sheet with Pro

Inside: 8 sections.

  • Process vs thread
  • CPU scheduling
  • Synchronisation
  • Deadlock
  • Memory
  • Page replacement
  • +2 more
Lifetime ₹1,999 ₹999 · Launch offer
Mark this as done when you are finished.

Item 1 of 12 · updated 2026-10-13