(Are you looking at a stale web page? Try refreshing your browser.)

( Latest Revision -- Thu Apr 18 14:21 PDT 2019 )
[2019/04/18: Added two problems for chapter 9]
[2019/04/08: Added a problem for chapter 8]
[2019/03/10: Added problems for chapters 6 and 7]
[2019/03/05: Added note about chapter 6 problem]
[2019/02/22: Added an assignment for chapter 5]
[2019/02/10: Added an assignment for chapter 4]
[2019/02/03: Corrected error in second problem for chapter 2 ]
[2019/01/04: Initial Updates ]

Homework/Study Problems for CS 3750




If you do a good job on the homework problems, you may do better on tests and get a better course grade.

Directions for Writing up the Problems

When you do a problem, show mastery of the material. Write a complete solution, Leaving no doubt that you 'know what you are talking about'. Give thoughtful and complete answers. Explain your answers so as to demonstrate and prove to a skeptical reader that they are correct.

Put things into your own words. Do not copy, quote, or closely paraphrase the textbook or other people's writings.

Write so as to be understandable to a certain intended readership -- an intelligent person who has completed the prerequisites for CS 3750 but who has not yet taken CS 3750.

Keep all your work on the problems, at least until the end of the semester.

Typically I will go over answers on the class day prior to giving you a quiz on related material. Possibly I'll do it before the quiz, but on the the same day as the quiz. Take advantage of this by revising and correcting your solutions, using the information you get from me about what the solutions should be.

Form and Format


"DUE DATES"

See the class schedule to find out what days I will go over the solutions to each problem set.



WARNING ABOUT PROBLEM NUMBERS

If you have a different edition of the textbook, or even a foreign version of the current edition, then the problem numbers in your book may not correspond exactly to those in the official course text. It is your responsibility to make sure you work the right problems.



Chapter #01 -- Introduction
  1. Write 500 words or more describing the interplay between operating system software and the interrupt mechanism. In your writing show that you understand A) how interrupts "drive" the actions of the operating system, and B) how the interrupt mechanism in a modern computing system actually works (what hardware devices do to cause an interrupt and the sequence of events that take place between the time that the currently running program is interrupted and the time that same program resumes execution).
Chapter #02 -- Operating System Structures
  1. Using information gleaned from chapters one and two, write 500 words or more describing the important functions and responsibilities of a modern multi-user, time-sharing operating system.

  2. Using information from section 2.8 write 250 words or more describing several different approaches to designing the structure of an operating system. Discuss the advantages and disadvantages of each approach.
Chapter #03 -- Processes
  1. Write 500 words on the topic of programs and processes. Define what a program is and what a process is. Explain what the differences and similarities are between the two concepts. Explain and/or speculate on what operating system data structures must be employed in order to maintain and preserve a program. Answer the same question for a process. Give attention to similarities and differences regarding the data structures too. Use information distilled from your readings of chapter 3 to help you answer this question, and add whatever else you know that you think will be helpful. (Keep in mind the "intended readership" described in the directions above.)
Chapter #04 -- Threads & Concurrency
  1. Rewrite the essay you wrote in answer to the question for chapter #03. The directions are the same except that this time you must cover three concepts: program, process, and thread. In addition to adding information about threads, since you know more now you should be able to improve on what you said before about programs and processes. (500 words)
Chapter #05 -- CPU Scheduling
  1. Do the following problem. (It is problem 5.4 on page 251 or page 252 of edition 10, and it is problem 6.16 on page 308 of edition #9.) The electronic version of the text gives you access to the answers to the problem, but don't look until after you have finished working the problem on your own. I will go over the answer in class, as I usually do.
         Consider the following set of processes, with the length of the 
         CPU burst given in milliseconds:
    
                Process    Burst Time    Priority
                  P1            2           2
                  P2            1           1
                  P3            8           4
                  P4            4           2
                  P5            5           3
    
         The processes are assumed to have arrived in the order P1, P2, P3, P4, P5,
         all at time 0.
    
         a. Draw four Gantt charts that illustrate the execution of these 
            processes using the following scheduling algorithms: FCFS, SJF, 
            nonpreemptive priority (a larger priority number implies a higher 
            priority), and RR (quantum = 2).
    
         b. What is the turnaround time of each process for each of the 
            scheduling algorithms in part a?
    
         c. What is the waiting time of each process for each of these 
            scheduling algorithms?
    
         d. Which of the algorithms results in the minimum average waiting 
            time (over all processes)?
Chapter #06 -- Synchronization Tools and
Chapter #07 -- Synchronization Examples
  1. Do problem 6.3 from the printed text: "Explain why spinlocks are not appropriate for single-processor systems, yet are often used in multiprocessor systems."

  2. Do problem 6.4 from the printed text: "Show that, if the wait() and signal() semaphore operations are not executed atomically, then mutual exclusion may be violated."

  3. Do the problem in the file hymanProb.html in this directory. Please take note of the example "scenario" described in the problem statement. Make sure that the solution you construct is the same kind of specific and detailed scenario.
Chapter #08 -- Deadlocks
  1. Do problem #8.3 on page 344 of the textbook (both the e-text and paperback). The problem starts with: "Consider the following snapshot of a system ...." Show all your work (in detail). Use the same kind of format you see here. The e-text provides some "bottom line" types of answers, but no "work." I recommend not looking at those answers until after you have done as much of the work as you can.
To Be Added Later ...

Chapter #09 -- Main Memory
  1. Do problem 9.6 on page 386 of the tenth edition. Here is the statement of the problem:

    Given five memory partitions of 300 KB, 600 KB, 350 KB, 200 KB, 750 KB, and 125KB (in order), how would the first-fit, best-fit, and worst-fit algorithms place processes of size 115 KB, 500 KB, 358 KB, 200 KB, and 375 KB (in order)? Rank the algorithms in terms of how efficiently they use memory.


  2. Do problem 9.7 on page 386 (It goes like this: "Assuming a 1-KB page size, what are the page numbers and offsets for the following address references (provided as decimal numbers):
    a.     3085
    b.    42095
    c.   215201
    d.   650000
    e.  2000001
Chapter #10 -- Virtual Memory
Chapter #11 -- Mass-Storage Structure
Chapter #13 -- File-System Interface
Chapter #15 -- File-System Internals