ECE 350: Real-Time Operating Systems

Jeff Zarnett

Estimated study time: 4 minutes

Table of contents

Sources and References

Equivalent UW courses — CS 350 (Operating Systems), CS 452 (Real-Time Programming), CS 354 (legacy Operating Systems) Primary textbook — Abraham Silberschatz, Peter B. Galvin, and Greg Gagne, Operating System Concepts, 10th ed., Wiley, 2018. Supplementary references — William Stallings, Operating Systems: Internals and Design Principles, 9th ed., Pearson, 2018; Andrew S. Tanenbaum and Herbert Bos, Modern Operating Systems, 4th ed., Pearson, 2014; Jane W. S. Liu, Real-Time Systems, Prentice Hall, 2000.

Equivalent UW Courses

ECE 350 is the Computer Engineering department’s combined OS-plus-real-time course, and it overlaps substantially with two separate CS courses. The OS fundamentals half (processes, scheduling, memory, virtual memory, file systems, I/O) corresponds to CS 350, which Computer Science students take in third year using essentially the same Silberschatz/Tanenbaum material. The real-time half (periodic tasks, rate-monotonic and earliest-deadline-first scheduling, priority inversion, kernel design for embedded targets) maps to CS 452, a fourth-year CS course that builds a real-time microkernel on an ARM dev board. CS 354 is a retired version of CS 350. In short, ECE 350 ≈ CS 350 + a compressed slice of CS 452, delivered in one term.

What This Course Adds Beyond the Equivalents

The real-time-systems emphasis is the main differentiator from CS 350. ECE 350 treats deadlines as first-class correctness criteria, covers schedulability analysis, and develops enough kernel internals to let students implement scheduling and IPC primitives on bare-metal hardware in the labs. The course is pitched at Computer Engineering students who will write firmware, drivers, and embedded control software, so it leans toward the hardware side — cache effects, interrupts, context switching, and memory hierarchy — more than CS 350 does.

Compared to CS 452, ECE 350 does less kernel-building: CS 452 has students write a full preemptive microkernel on physical trains, whereas ECE 350 labs are more limited in scope. Compared to CS 350, ECE 350 spends less time on classic file-system internals (journaling, FFS/ext layouts) and distributed/security topics in OS, and it omits the formal security module that CS 350 sometimes includes.

Topic Summary

Processes, Threads, and Context Switching

Process and thread abstractions, PCB/TCB layouts, user vs. kernel mode, and the mechanics of saving and restoring state on context switch. Cooperative vs. preemptive multitasking. Corresponds to early Silberschatz chapters.

Synchronization and Concurrency

Race conditions, mutual exclusion, semaphores, monitors, condition variables, and common bugs (deadlock, livelock, starvation). The four necessary conditions for deadlock plus detection, avoidance (banker’s algorithm), and prevention strategies. Priority inversion and priority inheritance are covered as a bridge to the real-time material.

CPU Scheduling

FCFS, SJF, round-robin, priority, and multilevel feedback queues for general-purpose scheduling. Metrics: turnaround, waiting, response time, throughput, fairness. Multi-core scheduling issues including affinity, load balancing, and cache warmth.

Real-Time Scheduling

Periodic and sporadic task models, \( \tau_i = (C_i, T_i, D_i) \) with worst-case execution time, period, and deadline. Rate-monotonic scheduling and the Liu-Layland utilization bound

\[ U \le n\,(2^{1/n} - 1). \]

Earliest-deadline-first and schedulability up to \( U \le 1 \). Priority ceiling and priority inheritance protocols to bound blocking times.

Memory Management and Virtual Memory

Contiguous allocation, paging, segmentation, TLBs, multi-level page tables, and inverted page tables. Demand paging, page-replacement algorithms (FIFO, LRU, clock), working-set model, and thrashing. Cache effects and their impact on worst-case execution time are flagged as a real-time concern.

I/O, Device Drivers, and Storage

Device classes, interrupts vs. polling, DMA, and the driver interface. Disk scheduling (SSTF, SCAN, C-SCAN) and a brief treatment of file-system layout, directories, and journaling. The coverage is lighter here than in CS 350.

Kernel Structure and Multi-Core OS

Monolithic vs. microkernel organization, system call mechanics, and the specifics of a small real-time kernel. Multi-core concerns: spinlocks vs. blocking locks, cache coherence implications for synchronization primitives, and per-CPU run queues.

Labs

Progressive lab assignments implement portions of a real-time kernel or OS subsystem, reinforcing scheduling, IPC, and synchronization in C on an embedded target.

Back to top