Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Question 1: Compare and contrast the following types of operating systems. Be sure to include when they are, or are not appropriate to use -Batch

image text in transcribed

Question 1: Compare and contrast the following types of operating systems. Be sure to include when they are, or are not appropriate to use -Batch Interactive Time-slicing (time-sharing) Real-time Distributed Question 2: What are the differences between a program, an executable, and a process? Question 3: Let an OS supports a system call sleep, which puts the program making the call to sleep for the number of seconds indicated in the argument of the sleep call. Explain how this system call may be implemented. [HINT think in terms of timer] Question 4: What happens on a context switch? Should context switches happen frequently or infrequently? Explain your answer Question 5: Consider an interprocess-communication that uses mailboxes: // send msg to Process Id, ToID mailbox:send (ToID, msg) mailbox:receive (FromID, msg) // receive msg from process id, FromID Is it possible for a process to wait to get a message from any one of a number of processes? If your answer is yes, write a program pseudo code that does so Now, consider the case that we add a new mailbox primitive mailbox: empty (FromID) I/ returns false if no msg in mailbox, // return true otherwise Use it to write pseudo code for a program that waits for a message from any one of a number ofprocesses. Assume there are total of n processes, numbered: 0 through (n-1) Question 6: Consider a multiprocessor system and a multithreaded program written using the many-to-many threading model. Let the number of user-level threads in the program be greater than the number of processors in the Discuss the performance implications of the following scenarios a. b. C. The number of kernel threads allocated to the program is less than the number of processors. The number of kernel threads allocated to the program is equal to the number of processors. The number of kernel threads allocated to the program is greater than the number of processors but less than the number of user-level threads Question 1: Compare and contrast the following types of operating systems. Be sure to include when they are, or are not appropriate to use -Batch Interactive Time-slicing (time-sharing) Real-time Distributed Question 2: What are the differences between a program, an executable, and a process? Question 3: Let an OS supports a system call sleep, which puts the program making the call to sleep for the number of seconds indicated in the argument of the sleep call. Explain how this system call may be implemented. [HINT think in terms of timer] Question 4: What happens on a context switch? Should context switches happen frequently or infrequently? Explain your answer Question 5: Consider an interprocess-communication that uses mailboxes: // send msg to Process Id, ToID mailbox:send (ToID, msg) mailbox:receive (FromID, msg) // receive msg from process id, FromID Is it possible for a process to wait to get a message from any one of a number of processes? If your answer is yes, write a program pseudo code that does so Now, consider the case that we add a new mailbox primitive mailbox: empty (FromID) I/ returns false if no msg in mailbox, // return true otherwise Use it to write pseudo code for a program that waits for a message from any one of a number ofprocesses. Assume there are total of n processes, numbered: 0 through (n-1) Question 6: Consider a multiprocessor system and a multithreaded program written using the many-to-many threading model. Let the number of user-level threads in the program be greater than the number of processors in the Discuss the performance implications of the following scenarios a. b. C. The number of kernel threads allocated to the program is less than the number of processors. The number of kernel threads allocated to the program is equal to the number of processors. The number of kernel threads allocated to the program is greater than the number of processors but less than the number of user-level threads

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

Modern Database Management

Authors: Jeffrey A. Hoffer Fred R. McFadden

4th Edition

0805360476, 978-0805360479

More Books

Students also viewed these Databases questions