COMP 310 / ECSE 427 -- Operating Systems

Fall 2012


20120904: WebCT is being set up. Please log in ( to check latest course materials and updates.

General Information


Instructor:            Xue Liu

Tel:                       514-398-6600

Email:                   Please check my website and figure out :-)

Office:                  Room 326, McConnell Engineering Building

Office hours:        Tuesdays 9:55-11:00.

Class:                    TuTh 8:35-9:55, ARTS W-215

Tutorial:               See WebCT

Prerequisites:      COMP-273 / ECSE 322

Class web page:   We will use WebCT primarily for this course. You are responsible to check WebCT for latest updates. While WebCT is being setup, initial information and course materials will be available on .

TAs:                      Mingyuan Xia (,
Arash Nourian (,
Nan Zhu (

TA office hours:  TA office hours will be held at Trottier 3130.

Schedule will be poste don WebCT.



Course Description and Learning Outcomes


Description: This is an important course in computer operating systems. In this course we will study the theoretical and practical concepts behind modern operating systems. In particular, we will study the basic structure of an operating system, its components, design strategies, algorithms and schemes used to design and implement different components of an operating system. Major components to be studied include: processes, inter-process communication, scheduling, memory management, virtual memory, storage management and network management.


Primary learning goals: To get a clear understanding of the major principles/algorithms that underlie an operating system and how they interplay within it.


Secondary learning goals: After taking this course, you should be able to: (i) identify the core functions of operating systems and how they are architected to support these functions, (ii) explain the algorithms and principles on which the core functions are built on, (iii) explain the major performance issues with regard to each core function, and (iv) discuss the operating system features required for a particular target applications.


In order to help you achieve the above goals, we will give RANDOM IN-CLASS QUIZZES throughout the course (See below for grading policy). You are expected to participate every class, and spend a SIGNIFICANT QUALITY TIME on this course.


McGill University values academic integrity. Therefore, all students must understand the meaning and consequences of cheating, plagiarism, and other academic offences under the Code of Student Conduct and Disciplinary Procedures (see for more information).  We enforce zero tolerance policy for any form of cheating,  plagiarism, and other academic offences.   



Course Schedule


The table below shows a tentative course schedule (subject to change)







Sep 6


Chapter 1


Sep 11

Operating-System Structures

Chapter 2


Sep 13

Operating-System Structures (Cont.)

Chapter 2


Sep 18


Chapter 3


Sep 20

Processes (Cont.)

Chapter 3


Sep 25


Chapter 4


Sep 27

Threads (Cont.)

Chapter 4


Oct 2

File-System Interface

Chapter 10

Assignment #1 assigned

Oct 4

File-System Interface (Cont.)

Chapter 10


Oct 9

File-System Implementation

Chapter 11


Oct 11

File-System Implementation (Cont.)

Chapter 11


Oct 16

CPU Scheduling

Chapter 5

Assignment #2 assigned

Oct 18

CPU Scheduling (Cont.)

Chapter 5


Oct 23

In-class midterm (Subject to change)



Oct 25

Main Memory

Chapter 8


Oct 30

Main Memory (Cont.)

Chapter 8


Nov 1

Virtual Memory

Chapter 9


Nov 6

Virtual Memory (Cont.)

Chapter 9


Nov 8

Process Synchronization

Chapter 6

Assignment #3 assigned

Nov 13

Process Synchronization (Cont.)

Chapter 6


Nov 15


Chapter 7


Nov 20

Deadlocks (Cont.)

Chapter 7


Nov 22

Mass-Storage Structure

Chapter 12


Nov 27

Mass-Storage Structure (Cont.)

Chapter 12


Nov 29

I/O Systems

Chapter 13


Dec 4

I/O Systems (Cont)

Chapter 13


Dec 7-Dec 22

No class (Monday class  will be held on Thursday, December 4)




Final Exam Period (TBA of the exact exam date)




Instructional Method


The course will consist of three hours of instructor led classes per week together with several tutorials taken by the TAs through the whole semester. The class time will be devoted to the presentation and development of new concepts and the application of these concepts to examples and problems, while the tutorials will help you prepare for the background needed and discuss solutions to the assignments. The primary focus of the tutorials is to provide sufficient how-to knowledge through the discussion of the assignments.


Students are strongly encouraged to use the WebCT discussion groups to talk about the programming and written assignments. These discussion groups will be monitored by the TAs and by the instructor for providing the necessary answers.


Course Materials




Required textbook:   A. Silberschatz, P. B. Galvin, and G. Gagne, Operating System Concepts, Latest edition (8th) , John Wiley & Sons, Hoboken, New Jersey.


Recommended book:  

Abraham Silberschatz, Peter B. Galvin, Operating System Concepts Essentials,  Greg Gagne (Latest edition)




The following table shows the learning outcomes that should have been met at the different learning milestones. These learning outcomes reflect the knowledge you should have acquired through the learning process at that given point in the semester.


I have posed the learning outcomes as questions so that you can test your knowledge with this aspect of the operating system. The idea is that you should be able to comfortably answer different flavors of the question posed as part of the learning outcome.



Learning milestone

Outcomes to be met (should be able answer AT LEAST the following questions)


Why do we need an OS?

What are the core functions of an OS?

In putting the core functions together, what architectural choices can we make?

What trade-offs exist between the different architectural choices?

What are the performance measures relevant in evaluating some OS functions?

What are the key operations performed by a storage manager?

What are the key issues in storage management?

What is an important realization of storage management?

Describe the anatomy of a simplified file system?

Can you implement a simplified file system using this knowledge?

Why do we need to disk scheduling?

What are the possible approaches for disk scheduling?


What is process management?

How is process management done in UNIX?

What are the possible approaches to process scheduling?

What is process synchronization?

Explain why process synchronization is key consideration in an OS?

What is a deadlock?

What are the approaches for managing deadlock?

Can you build operating systems that do not specifically deal with deadlocks?

What can happen with such operating systems?

What are the approaches for inter-process communication?


What support is provided by OS for networking?

What are the mechanisms provided by the socket API of UNIX?

What are the processes taking place in linking and loading object files?

Why is memory management important?

How does memory management support multiprogramming?

Do we need memory management in simple uniprogramming machines?

Why is virtual memory necessary?

Describe important issues with regard to virtual memory?

Does virtual memory always improve the performance?



Evaluation Components:



Written Assignment 1: CPU Scheduling (Not Graded)


Written Assignment 2: Synchronization & deadlocks (Not Graded)


Random in-class quizzes


Programming Assignment 1: Disk simulation


Programming Assignment 2: Simple file system


Programming Assignment 3: Simple networked file system




Final (comprehensive)





NOTE: The official programming language of this course is C. This means all support for programming assignments will only be provided in C. However, you can handover programming assignments in Java as well C you are responsible for solving Java issues.

Programming Assignments: Will be released after class begins.


Double Grading Policy: This course has a significant portion of the grade allocated for the programming component. You are expected to submit only your work in these assignments. You can receive advise or tips from others (instructor, teaching assistants, or peers), but the final submission should be yours. You are expected to know all the design decisions in the program and explain all aspects of the program handed in as part of the assignment. To test this condition, we will randomly select some students and ask them to explain their programming assignments. The eventual marks for an assignment will be the minimum of the two marks. For example, if 85 is the marks obtained in the first (normal) evaluation of the programming assignment and 50 is the marks obtained in the second evaluation, then effectively you have 50.


Cumulative Grading Policy: In this course, we will use a cumulative grading policy for the programming assignments. In the programming assignments, PA #3 can replace PA#1 and PA#2 if they are less (ratio-wise). You need to submit the programming assignments and get partial credit for the cumulative policy to work (i.e., submitting one assignment at the end of the semester is not acceptable).


Late Assignment Policy: There will be two deadlines for each assignment: proper deadline and cut-off date. After the proper deadline, there will be a penalty of 15% for each day the assignment is late until the end of the 3rd day after, which is the cut-off date. After the cut-off date, the assignment cannot be handed in, hence you receive 0 grade for that assignment. No individual requests for extensions will be granted unless they are for medical reasons. The penalty is calculated by rounding-up of each day.


The deadlines will be set for 23:59pm. Please observe the time and date very carefully. It is your responsibility to make sure that the assignment is properly submitted to the WebCT.


Re-grading Policy: If you find your assignments or exams are not marked according to the marking scheme, you are encouraged to consult me or the TAs. When you resubmit your assignment or exam for regarding, we reserve the right to re-grade the full exam or assignment without restricting the attention to the disputed portion. So your re-graded mark may be lower than the original mark.