Question

In: Computer Science

What are the major states a process can move between and what the events that cause...

What are the major states a process can move between and what the events that cause process to move in and out of each state ? What are the major types of PSU schedulers? Explain how the context-switch process is performed and when.

Solutions

Expert Solution

There are several states of a process from creation of that process and exit , that are conducted in operating system.

The states are new, Ready, Run, Blocked or Wait, Terminated or Completed , Suspend ready and Suspend wait or suspend blocked .

After a new process is created in the new state , the event Admit helps to get it ready .Then from the ready state , it is dispatched for running or if timeout while running then goes back to the ready state. If the process were swapped out of memory and placed onto external storage , the process goes to the suspend ready state, and when activated ,goes back to the ready state again for running. Whenever the process requests access to any input/output or need access to a memory which is slready acqiured by another process, it goes to the blocked/wait state .Once the opeartion is completed it goes back to the ready state for running. And if there occurs a problem completeing the operation or there is lack of memory then the process goes to suspended block/wait state then to suspended ready state and then goes to ready state again. Lastly The process which are completed executing, the Release event helps them to exit .

     There are different types of schedulers -

    a) Long term - performance

    b) Short term - context switching time

c) Medium term - swapping time

Context - switching process--

    There are different cases when context switching occurs -

    a) When a current process is running and one another process needs to be completed immediately, so the current process save its works and the different process starts running.This usually occurs in a multitasking environment.

   b) When any interruption occurs while executing a process

   c) When a transition is required between user mode and the kernel mode , then a context switching occurs.

    Steps of context switching-

   a) Save all the works and the context of the process that is currently running and then updating the process control block.

b) Then Move to the process control block of that particular process into the appropriate queue.

c) Then it selects a new process

d) Update the process control block for that particular process

e) The memory management data structures also get updated as required.

   f) Using the previous values of the process control block and registers it stores the progress that was in wait state and started execution.


Related Solutions

Major geo-political events such as the Iran-Iraq war, for example can cause sudden disruptions to oil...
Major geo-political events such as the Iran-Iraq war, for example can cause sudden disruptions to oil supplies. What are two strategies that governments or firms can use to reduce the economic risks that these disruptions would otherwise pose to their businesses or societies? Explain in words how each of the strategies you mentioned above accomplish their goal of risk reduction (i.e., how do they reduce the risk from shocks to oil supplies?).
a. Compare the process of mitosis with the process of meiosis. Describe major cell cycle events....
a. Compare the process of mitosis with the process of meiosis. Describe major cell cycle events. (points: 4) What is significance of these two cell division types.
19) what is a temperature inversion and why can theses events cause extreme air pollution?
19) what is a temperature inversion and why can theses events cause extreme air pollution?
What are the major challenges in trade (and national security) between China and United States?; What...
What are the major challenges in trade (and national security) between China and United States?; What are the differences in political economy between US and China that created the above major challenges?; What should be the short term and long term approach in resolving the issue? write as much as possible thanks
Name two major types of ionizing radiation that can cause DNA lesions. What are the two...
Name two major types of ionizing radiation that can cause DNA lesions. What are the two main types of lesion that ionizing radiation cause, and which type is double-strand breaks? What are four possible results of double-strand breaks? What type of damage to DNA does aflatoxin cause? Where does it come from, and what must happen to it for it to become activated to cause DNA damage?
What are the major differences between the consumer buying process discussed in Chapter 6 and the...
What are the major differences between the consumer buying process discussed in Chapter 6 and the B2B buying process discussed in this chapter? Use buying iPads for personal use versus buying more than 100 iPads for a firm to illustrate the key points.
there are some major trade war events between US and China during Trump administration. 1. What...
there are some major trade war events between US and China during Trump administration. 1. What are the institutional and resource-based explanations to these events? 3. How do you evaluate the status quo of trade disputes between the two countries? How can they overcome the present challenges and establish a better trade relations?
What were the major events in the development of the cold war?
What were the major events in the development of the cold war?
1. Describe the major events of the menstrual cycle and what triggers those events? Be specific....
1. Describe the major events of the menstrual cycle and what triggers those events? Be specific. 2. Soon after eating a meal what happens to pancreatic secretions? Include what stimulates these secretions & the affect of those sec secretions. Be sure to discuss the endocrine and exocrine rules.
what are the major groups of genes that when mutated can cause cancer, and include the types of mutations that can change their protein structure.
  what are the major groups of genes that when mutated can cause cancer, and include the types of mutations that can change their protein structure. your assigned gene (C-KIT). Focus on the group of cancer-causing genes that this gene belongs to, its normal function, and why the mutation can lead to the cell cycle becoming out of control. Is your mutated gene inherited, or does it become mutated throughout a person’s lifetime? If you could develop a drug that...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT