CS 347 : Operating Systems Principles

Course Time Table:

Classes in Slot 6: Wed and Friday 11.00 -- 12.30 hrs. Place: IC-3

Office Hours: Thursdays 4.00 pm to 5.00 pm Place: Room F-3, first floor, old CSE building
(Students can also meet me on Wed and Friday, 12.30 hrs. outside IC-3.)

Associated lab CS 377: Friday 2.00 - 5.00 in New Software Lab (Ground floor, Math+CSE bldg)

Teaching Assistants: Sandip Ghoshal, Pallab Sahu, Pratibha Gaund, Abhishek Gupta, Aamod Kore, Rohan Das, Rohan Prinja, Ankit
(emails: {sandipg, pallab, pratibha, abhishekgupta, aamod, rohandas, rohanp, ankit}@cse)

Text book:
D. M. Dhamdhere : Operating Systems---A concept-based approach, Third Edition,
Tata McrGraw Hill, 2012.


Syllabus of the course

Introduction to Operating Systems. Interaction between the OS, computer system and user programs.

Process management---Creation and scheduling of processes, Process synchronization, Message Passing, Deadlocks.

Memory management---relocation and execution of programs, sharing of programs, Virtual memory management.

File systems---file organization, directory structures, file system reliability.Disk scheduling.

Security and Protection.



Typical credit distribution:
Quizzes (10%), Home Assignment (10%), Mid-sem (30%), End-sem (50%).
(Minor redistribution may be made depending on nature of home assignment.)


Honesty policy:
Highest standards of academic honesty would be enforced.
Students must not discuss or copy in any evaluation unit---home assignment, quiz, exams, lab assignment, etc.
Even looking in the direction of someone's answerpaper during a written quiz or exam would be
considered dishonest and would be dealt with accordingly.

Plan/log of lectures:

Lecture 1 (7 Jan 2015):
Introduction to the course---motivation, honesty policy, tips for learning effectiveness.
Feedback on architecture prerequisites. Feedback form
Introduction to critical thinking skills. Slides (This topic will not be done explicitly, students to study from slides.)

Lecture 2 (9 Jan 2015):
Concept hierarchies and Abstract views of an OS, and their benefits for managing complexity.
Goals of an OS---effective utilization of a computer, user convenience, ensuring non-interference.
Fundamental tasks of an OS: 1. Program management and scheduling.
2. Resource management policies---partitioning of resources and pool-based allocation. Virtual resources.

Lecture 3 (14 Jan 2015):
Overhead of OS operation. Interrupt-driven operation of an OS. Notions of performance.
Fundamental tasks of an OS: (Contd.) 2. Resource Management---Virtual resources.
Overview of the course: Event processing. Process Management. Advanced topics---process synchronization and deadlocks, file system efficiency and reliability, structure of an OS.

Lecture 4 (16 Jan 2015):
Fundamentals of computer architecture. User accessible registers and the PSW. Privileged mode of the CPU. State of the CPU.
The interrupt action. Interrupt servicing. System calls.
Complete view of OS operation.

Lecture 5 (21 Jan 2015):
Interrupt servicing and system calls (contd.). Masking of interrupts.
The program table---saving of CPU state. Event handling and scheduling.

Lecture 6 (23 Jan 2015):
Computational environments and Classes of operating systems. Batching, Multiprogramming, Time sharing OS. System performance, user service, and protection and security in these operating systems.
Notions of system performance and user service.

Lecture 7 (28 Jan 2015):
Multiprogramming OS---program classification, program mix and assignment of program priorities.
Time Sharing systems---swapping of programs. Real time operating systems---hard and soft real time applications.
Introduction to processes. Benefits of child processes.

Lecture 8 (30 Jan 2015):
Process definition.
Process management---process control block (PCB), process context, process state.
Processes---parallelism and concurrency.
Information in the PCB. Process state transitions.
Event handling. Swapping states.

Lecture 9 (4 February 2015):
Swapping states of processes. Role of Event Control Blocks.
Scheduling---terminology (request-related, service-related, performance-related)
The scheduling schematic---Long-term scheduler, Medium-term scheduler, and Short-term scheduler (process scheduler)
Non-preemptive scheduling.

Lecture 10 (6 February 2015):
Fundamental techniques of scheduling---priority, reordering, variation of time slice.
Pre-emptive scheduling.
Preemptive scheduling --- Priority-based, RR, Multi-level, LCN, STG. Quiz 2.

Lecture 11 (11 February 2015):
Preemptive scheduling (contd.)
Fair-share scheduling.
Real-time scheduling.
Threads and thread models---kernel-level threads and user-level threads.
Introduction to deadlocks.

Lecture 12 (13 February 2015):
Deadlocks --- definition, kinds of deadlocks
Resource state modelling --- WFG, RRAG, Matrix model
Paths and cycles in WFG/RRAG. Ideas of deadlock detection.
Use of Vee diagram in systematically constructing answers/thinking. Slides

Lecture 13 (18 February 2015):
Resource class models, Resource state models and characterization of deadlocks
Deadlock prevention and deadlock detection

Lecture 14 (27 February 2015):
Deadlock avoidance---Banker's algorithm.
Preliminaries of memory management---allocation to a process, relocation, linking, and loading of programs.

Lecture 15 (11 March 2015):
Heap allocation. Merging of free areas using boundary tags.
Buddy system and powers of 2 allocators.
Fragmentation. Non-contiguous memory allocation preliminaries.

Lecture 16 (13 March 2015):
Demand paging schematic. Page table format.
TLB and Superpages.

Lecture 17 (18 March 2015):
TLB fault handling and protection issues. Multi-level and inverted page tables.
Memory allocation issues - Page replacement algorithms, stack property, working set.

Lecture 18 (18 March 2015):
Two-handed clock algorithm. Working set. page sharing. copy-on-write.

Lecture 19 (23 March 2015):
File systems and the IOCS.
Directory hierarchy --- file protection and disk space allocation.
Efficiency issues in file system operation.

Lecture 20 (18 March 2015):
Operation of the file system--- actions at file open and read/write.
The File control block (FCB). Caching of data. File sharing semantics.