Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Operating Systems Questions (Please help if you can) 1. A computer has cache, main memory, and a disk used for virtual memory. If a referenced

Operating Systems Questions (Please help if you can)

1. A computer has cache, main memory, and a disk used for virtual memory. If a

referenced word is in the cache, 20ns are required to access it. If it is in main memory but not

in the cache, 60ns are required to load it into the cache (this includes the time to originally

check the cache), and then, the reference is started again. If the word is not in main memory,

12ms are required to fetch the word from disk, followed by 60ns to copy it to the cache, and

then, the reference is started again. The cache hit ratio is 0.9 and the main memory hit ratio

is 0.6. What is the average time in ns required to access a referenced word on this system?

2. [6 pt] An i/o-bound process is one that, if run alone, would spend more time waiting for i/o

than using the cpu. A cpu-bound process is the opposite. Suppose a short-term scheduling

algorithm favors those processes that have used little cpu time in the recent past. Explain

why this algorithm favors i/o-bound processes yet does not permanently deny cpu time to

cpu-bound processes.

3. What is an instruction trace? What is an interleaved instruction trace?

4. You have executed the following C program:

#include

#include

#include

int main()

{

pid_t pid = fork();

printf ( "%d ", pid );

return ( 0 );

}

What are the possible outputs, assuming the fork succeeded?

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Pro PowerShell For Database Developers

Authors: Bryan P Cafferky

1st Edition

1484205413, 9781484205419

More Books

Students also viewed these Databases questions

Question

Know how to use reservations systems to inventory demand.

Answered: 1 week ago