User Tools

Site Tools


faq

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
faq [2021/03/17 03:42] jxufaq [2021/03/17 03:48] jxu
Line 179: Line 179:
      
   - (1) Each process only executes once on the CPU before terminating;   - (1) Each process only executes once on the CPU before terminating;
-(2) Each process never does any I/O on any I/O device; +  - (2) Each process never does any I/O on any I/O device; 
-(3) All processes have the same single CPU Computation Time; +  (3) All processes have the same single CPU Computation Time; 
-(4) Only the simplest C1. Nonpreemptive First-Come, First-Served (FCFS) CPU Scheduling Algorithm is used.+  (4) Only the simplest C1. Nonpreemptive First-Come, First-Served (FCFS) CPU Scheduling Algorithm is used.
  
  
  
 Note that in this very basic and simple system: Note that in this very basic and simple system:
-(a) There is only one single process queue – the ready queue, which is a FCFS queue;  +  - There is only one single process queue – the ready queue, which is a FCFS queue;  
-(b) Whenever a process arrives, it is entered at the end of the ready queue; +  - Whenever a process arrives, it is entered at the end of the ready queue; 
-(c) Whenever the CPU becomes available, the Nonpremptive FCFS CPU Scheduler always removes from the ready queue the process which is at the front of the ready queue, and allows that process to start executing on the CPU; +  - Whenever the CPU becomes available, the Nonpremptive FCFS CPU Scheduler always removes from the ready queue the process which is at the front of the ready queue, and allows that process to start executing on the CPU; 
-(d) Once a process starts executing on the CPU, it is never preempted, and always executes for the full duration of its CPU Computation Time before terminating. +  - Once a process starts executing on the CPU, it is never preempted, and always executes for the full duration of its CPU Computation Time before terminating. 
-(e) Whenever a process terminates, the CPU becomes available again.+  - Whenever a process terminates, the CPU becomes available again.
    
 Write the code so that the program allows the user to enter as input parameters the following: Write the code so that the program allows the user to enter as input parameters the following:
-- the number of processes;  +  - the number of processes;  
-- the Arrival Time of each process; +  (the Arrival Time of each process; 
-- the CPU Computation Time for each process;+  (the CPU Computation Time for each process; 
 Then try to write code which computes the Average Waiting Times and Average Turnaround Times for any set of input parameters above. Then try to write code which computes the Average Waiting Times and Average Turnaround Times for any set of input parameters above.
  
faq.txt · Last modified: 2021/04/26 22:20 by jxu