Operating System Slides 📂 Introduction · 2 of 22 56 min read

Computer System Organization & Types of Operating Systems

A visual guide to how a computer is built — the shared system bus, the memory hierarchy, device controllers and DMA — and the eight operating-system families layered on top, from batch and time-sharing to real-time, distributed, clustered, embedded and mobile, with animated diagrams throughout.

🖧

Computer System Organization & Types of Operating Systems

How the CPU, memory, buses and devices fit together — and the eight families of operating systems built on top, from overnight batch jobs to airbags that must fire in 15 milliseconds.
System Bus Storage Hierarchy I/O & DMA OS Types

Press Next → or use ← → arrow keys

Section 01

Computer System Organization — The Big Picture

The Kitchen Brigade
In a busy kitchen the head chef (the CPU) keeps ingredients on the counter (registers), a spice rack within arm's reach (cache), a walk-in fridge a few steps away (RAM) and a freezer down the hall (SSD/HDD). Waiters (I/O controllers) ferry plates in and out.

Everyone shares one narrow corridor — the system bus. The closer a resource sits to the chef, the faster, smaller and pricier it is.
🚦
Everything Shares One Bus

The CPU and every device controller can work at the same time, but they all compete for the memory bus. A memory controller arbitrates access so no two talkers corrupt each other. Often it is bus bandwidth — not raw clock speed — that limits a system.

Section 01 · Diagram

A Modern Computer at Work

SHARED SYSTEM BUS · one talker at a time 🧠 CPU 📦 Main Memory DRAM · ~100 ns 💽 Disk Ctrl SSD · HDD ⌨️ USB Ctrl keyboard · mouse 🌐 Network Card Ethernet · WiFi 🖥️ GPU HDMI · DisplayPort
📦
Follow the Packets

The coloured dots are data moving across the shared bus. Because only one device can drive the bus at a time, high-throughput devices use DMA (coming up) to move whole blocks without making the CPU babysit every byte.

Section 02

The Memory Hierarchy — Data Flows Up and Down

Registers0.3 ns L1 Cache1 ns L2 Cache3 ns L3 Cache10 ns Main Memory (RAM)100 ns SSD (flash)50 µs HDD (magnetic)5 ms Tape / Cloud archiveseconds ▲ faster smaller ▼ bigger cheaper ↑ read ↓ evict
🧊
Why a Hierarchy at All?

No single technology is fast, huge, cheap and non-volatile at once. So we stack many: tiny-fast at the top, vast-slow at the bottom. Hot data bubbles up toward the CPU; cold data is evicted down.

Section 02 · Details

The Hierarchy in Numbers

LayerAccessSizeVolatile?Managed by
Registers~0.3 ns<1 KBYesCompiler
L1 Cache~1 ns32–64 KBYesHardware
L2 / L3 Cache3–10 ns256 KB–64 MBYesHardware
Main Memory~100 ns8–128 GBYesOperating System
SSD50–100 µs256 GB–4 TBNoOperating System
HDD3–10 ms1–20 TBNoOperating System
Optical / TapeSecondsUnlimitedNoOperator / Software
🔁
Caching Is Everywhere

The same trick repeats at every scale — CPU cache, OS disk cache, DNS, browser cache, CDN. It works because of locality: data used recently is likely used again (temporal), and its neighbours are likely next (spatial).

Section 03

The Middleman — How the CPU Talks to Devices

🧠 CPU Device Controller Registers Buffer a dedicated processor 💽 Device disk · NIC · printer ① command → ③ ← interrupt "done!" ② handles device →
🔌
The CPU Never Touches Raw Hardware

It writes a command into the controller's registers, the controller drives the physical device, and when the work is finished it raises an interrupt to say "done." Clean, safe, and it frees the CPU to do other things meanwhile.

Section 03 · I/O Techniques

Polling vs Interrupts vs DMA

CPU load over one transfer → Polling 100% busy CPU spins: "ready? ready? ready?" Interrupt 1 IRQ / byte CPU free · amber = interrupt handling DMA 1 IRQ / block ◄ whole block moves without the CPU ►
DMA Is Why Modern Machines Feel Fast

Polling burns 100% of the CPU. Interrupts free it but cost one interrupt per byte. DMA hands a whole block to a dedicated engine and fires a single interrupt when finished — roughly 4000× fewer interrupts for a 4 KB transfer.

Section 04

The Operating-System Family Tree

OS 8 families 🗃️Batch 🔀Multiprog 🖱️Multitask Time-share ⏱️Real-Time 🌐Distributed 🖥️Clustered 📱Embed/Mobile
🌳
Eight Families, One Job

Each family is a response to a specific workload — throughput, interactivity, deadlines, scale, or tiny footprints. They are not mutually exclusive: your phone blends mobile, soft-real-time and embedded ideas at once.

Section 05

Batch OS — One Job at a Time

time → (jobs never overlap) Job 1 CPU I/O idle ✗ Job 2 CPU I/O idle ✗ Job 3 CPU idle ✗
Letters pile up in a bin all day. After hours, one worker picks them one by one — sorts, seals, moves to the next — never pausing for a customer. That is a batch OS: a queue of jobs run back-to-back with no human interaction, and the CPU sitting idle during every I/O wait. Great throughput for payroll, ETL and CI/CD; poor CPU utilisation and long turnaround.
Section 06

Multiprogramming — Keep the CPU Busy

time → (overlap CPU with others' I/O) Job 1 CPU I/O wait Job 2 wait CPU Job 3 CPU CPU
🎯
The Trick That Built Modern OSes

Hold several jobs in memory. The moment one blocks on I/O, run another — so something is always on the CPU. Making this safe requires memory management, CPU scheduling and I/O management — the three pillars every OS still rests on.

Section 07

Multitasking & Time-Sharing — The Quantum Cycle

CPU 1 core 📝P1 Editor 🌐P2 Browser 🎵P3 Music 💬P4 Chat 10 ms → 10 ms → 10 ms → 10 ms →
PropertyMultiprogrammingTime-Sharing
Switch triggerI/O waitTimer interrupt (preemptive)
GoalMaximise CPU useMinimise user response time
InteractionLittle / noneHigh (terminals / GUI)
Era & examples1960s · IBM OS/3601970s→today · UNIX, Windows, macOS
Section 08

Real-Time OS — Meeting the Deadline Every Time

deadline · 15 ms General OS sometimes late RTOS always on time
In a crash, the airbag controller has about 15 ms to fire before your head reaches the wheel. A general-purpose OS that "usually" responds in 20 ms is worse than useless. A hard RTOS guarantees the deadline every single time — because real-time is about predictability, not raw speed. A slow RTOS that always meets 15 ms beats a fast Linux that occasionally takes 50.
Section 08 · Details

Three Flavours of Real-Time

🔴
Hard
miss = catastrophe
A missed deadline is a failure. Airbags, pacemakers, avionics, industrial robots. VxWorks, QNX, INTEGRITY. Latency bounded <10 µs.
🟠
Soft
miss = degraded
A miss hurts quality but isn't fatal. Video, VoIP, streaming, games. Linux with PREEMPT_RT, Windows CE.
🟢
Firm
miss = useless result
An occasional miss is tolerable, but a late result has no value. Stock trading, telemetry, live sensors.
CharacteristicGeneral-Purpose OSReal-Time OS
Primary goalFairness & throughputPredictable deadlines
SchedulerPriority + fairness (CFS)Priority-based, deterministic
Kernel sizeMillions of linesTens of thousands
Interrupt latency~100 µs (variable)<10 µs (bounded)
Memory modelVirtual memory, pagingOften no paging (avoids jitter)
Section 09

Distributed & Clustered Systems

NETWORK Ethernet · IB 🖥️Node ACPU·RAM·Disk 🖥️Node BCPU·RAM·Disk 🖥️Node CCPU·RAM·Disk 🖥️Node DCPU·RAM·Disk Single System Image — users see one giant computer
TypeCouplingIllusionExamples
Network OSLooseYou address each remote machine (ssh, ftp)Any networked Linux/Windows
Distributed OSTighterSingle system imageAmoeba, Plan 9, LOCUS
Clustered OSVery tight (LAN)High availability or HPCBeowulf, Oracle RAC, Failover
Section 10

Embedded, Mobile & Cloud

🔌
Embedded OS
Dedicated to one purpose — router, thermostat, ATM, smart bulb. Tiny footprint (KB–MB), often no UI at all. Contiki, TinyOS, FreeRTOS.
IoT · appliances · sensors
📱
Mobile OS
A full OS tuned for touch, sensors, radios and battery life. Sandboxed apps distributed through stores. iOS, Android, HarmonyOS.
phones · tablets · wearables
🌐
Cloud OS
A hypervisor plus a management layer that turns a data centre into elastic VMs and containers. AWS, Azure, GCP, OpenStack.
elastic · virtualised
🧬
Types Blend in Practice

Real devices mix families: a phone is mobile + soft-RTOS + embedded; a cloud server is multitasking + time-sharing + clustered. The categories are lenses, not silos.

Section 11

All OS Types, Side by Side

TypePrimary GoalInteractionResponseExample
🗃️ BatchThroughputNoneHoursNightly payroll
🔀 MultiprogrammingCPU utilisationMinimalMinutesMainframe + I/O overlap
🖱️ MultitaskingConcurrent programsHighSecondsWindows, macOS, Linux
⏳ Time-SharingFair CPU per userHigh (multi-user)MillisecondsUNIX / SSH servers
⏱️ Real-Time (Hard)Deadline guaranteeMachine-onlyµs (bounded)Airbags, VxWorks
🌐 DistributedResource sharingTransparentNetwork-dependentPlan 9, Amoeba
🖥️ ClusteredAvailability / HPCTransparentLow failoverBeowulf, Oracle RAC
📱 Embedded / MobileDevice functionTouch / voice / noneReal-time-ishiOS, Android, FreeRTOS
Section 12

Which OS Type Fits Which Problem?

📊
Throughput, latency irrelevant
Bulk data, payroll, ETL, ML training → Batch. Run it overnight; nobody's waiting.
💻
Personal / interactive
Laptops and workstations → Multitasking. Many apps, snappy response.
👥
Many users, one machine
Shared dev boxes, SSH, university labs → Time-Sharing. Fair slices for everyone.
🚨
Safety-critical deadlines
Avionics, medical, automotive ECUs → Real-Time. Predictability above all.
🌍
Massive scale & uptime
Search, social, big data, cloud → Distributed / Clustered. Scale out, survive failures.
🔋
Constrained devices
IoT, wearables, appliances, phones → Embedded / Mobile. Tiny memory, tight power budget.
Section 13

Eight Ideas Worth Remembering

🖧 SYSTEM ORGANIZATION & OS TYPES · THE ESSENTIALS
1
The storage hierarchy exists because no single technology is fast, huge, cheap and non-volatile.
2
Caching is universal — CPU, RAM, browser, CDN all exploit temporal and spatial locality.
3
The CPU never touches raw devices; it talks to controllers through bus registers and memory-mapped I/O.
4
DMA is the single biggest reason modern machines feel fast — blocks flow while the CPU works.
5
Batch → multiprogramming → multitasking → time-sharing is a progression, each fixing the last one's limits.
6
Real-time prioritises predictability over speed — a slow RTOS that meets the deadline beats a fast one that sometimes misses.
7
Distributed ideas — transparency, replication, consensus, fault tolerance — are the foundation of everything cloud-native.
8
Real systems mix types: a phone is mobile + soft-RTOS + embedded; a cloud server is multitasking + time-sharing + clustered.
FINAL

From Silicon to System Design

7Storage layers
3I/O techniques
~4000×DMA interrupt saving
8OS families
15msThe airbag deadline
<10µsHard-RTOS latency
🎯
You Can Now Read a Whole Machine

From the shared bus and the memory pyramid, through controllers and DMA, up to the eight OS families — you can now explain why a computer is built the way it is, and which operating system any given job demands.

📚
Where To Go Next

Explore CPU scheduling algorithms, memory management and paging, then concurrency. On Linux, try lscpu, free -h, lsblk and vmstat 1 to watch these ideas live.

🖧 End of tutorial · Press to review, or click Restart