ECE421 T, Operating Systems, Spring 2025
Tue & Thurs from 5:05 to 6:20 p.m. in MM 202

The Book

Documentation

Potentially useful source code

Assistance

Assignments

1 due: Fri 7th February. Finish the primitive single-block file system.
2 due: Mon 24th February. Integrate your disc file system with the iosb system.
Additional reminders, already said in class, but brought together in one place.
3 due: Sun 6th April. Improve the disc file system so that file size is only limited by disc size.
4 due: Wed 16th April. Free block management and subdirectories.
5 due: Wed 23rd April. First and second steps of the final big thing.
6 due: Tues 29th April. Third step of the final big thing.
5 due: Tues 6th May. The final big thing.

Read the Important Rules link above.
Submit assignments (code + sample run(s)) through blackboard (under Assignments) - THIS SHOULD CHANGE SOON.
Submissions must be clearly readable word documents.
Capture your code as text, not an image: cat, copy, paste.

PC log in - use Putty or your own preferred SSH app.
OR mac users: start the terminal app, windows users: start powershell, then type the command
ssh username@rabbit.eng.miami.edu and type your password when prompted.
Windows users beware: you can't use ctrl-V in pico, but page up and page down will do the job.

Class History

Class 1 - Tue 14-1-2025    Quick introductions.
Learning BCPL, looked at these: functions, local array and floating point, binary tree.
Class 2 - Thur 16-1-2025 Hadn't finished this: extracting words from a string.
Tapes and discs:
        tape drive 1950'scomputer room 1970's,
        important probability fact,
        A mostly forgotten intermediary 1950's-60's onetwothree,
        A disc drive, 1963, access 50-205 mS, 15MB, 440V, 20KW.
Class 3 - Tue 21-1-2025 Beginning the almost trivial first file system,
Every file exactly one block long, file "name" is block number.
Class 4 - Thur 23-1-2025 The primitive file system is now usable, and here it is.
Class 5 - Tue 28-1-2025 How to use the virtual machine's debugging assistance.
Improved systems for making disc blocks into files:
        Contiguous allocation, simple but slow;
        level-1 index: header block with pointers to data blocks, limited;
        header block with "runs" of consecutive blocks, as in NTFS;
        Maybe extend level-1 index to a tree-like structure?
All of this applies almost equally to the new solid state devices.
Class 6 - Thur 30-1-2025 Other file formats: multi (variable) level indexes, header block has ptrs to (ptr blocks with ptrs to)* data blocks.
level 0 index good trick for efficient small files.
Max and min file size, access times for sequential and random access.
Directory entries, the sorts of things they need to contain.
Hard links and reference counts (no good for possibly cyclic structures).
Class 7 - Tue 4-2-2025 I-nodes, recovery after disc failure.
Learning from mistakes: FAT-16.
Clusters and partitions still survive.
Class 8 - Thur 6-2-2025 ReiserFS, a file system for murderers.
RAID systems.
Journalling file systems.
Class 9 - Tue 11-2-2025 Solid state "discs".
Managing free blocks.
Class 10 - Thur 13-2-2025 Some thoughts on the second and third assignments.
IOSB: a generalised and improved IO system, same handling for anything like a file.
Class 11 - Tue 18-2-2025 The virtual machine's instruction set.
The regions of memory available to a running program.
How functions use the stack (pre-call and pre-function instruction sequences)
Class 12 - Thur 20-2-2025 Post-call and post-function instruction sequences and the extra word.
Memory technology: M1, M2, N1, C1, C2, C3, C4, C5, C6, C7.
Class 13 - Tue 25-2-2025 Virtual memory, virtual address, physical address, address translation.
A primitive but viable hardware solution: multiple segments, base and limit registers.
The modern way: paged memory, page tables, TLB in cache for speed.
Class 14 - Thur 27-2-2025 Intel's 32-bit scheme, (CR3; 10, 10, 12), now (CR3; 9, 9, 9, 9, 9, 12).
Page protection, how a unix process is created, how interrupts are handled.
The big picture, VM is use with two processes.
Class 15 - Tue 4-3-2025 Doing something real but basic with virtual memory.
tiny notes from today.
Organising the free page list in four steps: one, two, three, four.
Class 16 - Thur 6-3-2025 Setting up virtual memory, almost ready to go.
Break 10th to 14th
Class 17 - Tue 18-3-2025 Getting complicated with the VM memory map (see next class for link to diagram).
Class 18 - Thur 20-3-2025 The (almost) completed memory map. Nearly handled a page fault correctly!
In fact there was nothing wrong, just the output being hard to read:
This is the code as we had it at the end, just with the $debug call removed,
This is the output up to the point where the repeated page faults happened,
See if you can work out what it is really saying.
Class 19 - Tue 25-3-2025 Virtual memory fully working.
Class 20 - Thur 27-3-2025 Race conditions, critical sections, read-modify-write on shared resource, mutexes,
semaphores, atomic operations, atomic test and set instruction.
Starting on the five philosophers.
Class 21 - Tue 1-4-2025 Communicating Sequential Processes (CSP) gives a formal description of the college of philosophers.
Deadlock. Can be avoided if it can be predicted, but in general it can't.
Avoidance of and dealing with deadlock for the philosophers.
Some shared single user devices: card punch, card reader, (codes), line printer, graph plotter.
Class 22 - Thur 3-4-2025 Intel's LOCK, XCHG, BTS, Vax REMQHI, SOBGEQ, Dec-10 SOSL.
P and V by software: 0, a, b, c, d, e, f.
Monitors, Java's synchronized.
How worms always used to break in and still do occasionally.
Class 23 - Tue 8-4-2025 (no class for centennial)
Class 24 - Thur 10-4-2025 Interprocess communication through shared memory with a mutex.
Putting everything together for the last big thing, multiprocessing.
Class 25 - Tue 15-4-2025 More about assignment 5.
Creating a heap.
Class 26 - Thur 17-4-2025 The Buddy system for heaps illustrated.
Garbage collection.
The very beginning of networking.
Class 27 - Tue 22-4-2025 More on networking.
A bit about the mysterious aspects of security.
Class 28 - Thur 24-4-2025 Filling in the cryptography details.
Diagrams to possibly help correct final file system.
words.