513 views
2 votes
2 votes

A computer can execute 100000 instructions per second. Programs running on this computer performs an average a 1 sector read and a 1 sector write for every 200 instructions that it executes. The disk drive handling 110 transfer requires 0.00010sec. each to perform the read or write operations. Assuming no overlap of there operations the % of CPU time spent in wait state is 

   
   
 

(A) 12%

 

(B)  39%

 

(C) 57%

 

(D) .09%

2 Answers

0 votes
0 votes

In 1 sec ------------------------- 100000 instructions are executed

100000/200 = 500 read and write sectors are required.

for each read or write 100 microsec required.

time for 500 read and write = 500*100*2=100000 micro sec = 0.1 sec

in 1sec only 0.1 sec is useful time

time spend in wait state = 0.9 sec

%of time spend in wait state = 0.9/1 *100 = 90%

0 votes
0 votes

100000 instructions are executed In 1 sec

 read and write in 1 sec = 100000/200 = 500

500 reads and 500 writes total 1000 data transfer operation

1 data operation time =  10^(-4)/110 sec

time for 1000 read and write = 1000 x 10^(-4)/110 sec =0.0009 sec

%of time spend in wait state = (0.0009/1) *100 = 0.09%

Related questions