Question

In: Computer Science

Are there any limitations on the number of CPU instructions inside a critical section? Why (or...

Are there any limitations on the number of CPU instructions inside a critical section? Why (or why not)?

Solutions

Expert Solution

-There are no limitations on the number of CPU instructions inside a critical section, apart, it satisfies the critical section conditions:
A critical section is basically a segment of code that can be accessed by one process at a time.

do

{

entry;

critical section;

exit section;

Remainder Section

}

while (True);

In Entry Section, process requests for entry in the critical section. Once a process enters into the critical section, it has to go through/satisfies the three steps:

Mutual Exclusion: In mutual exclusion, no process can enter into the critical section, if one process has already entered.

Progress: If no process is executing in the critical section, and other processes are waiting outside the critical section, then processes tahr in the remainder section can participate and decide which process will enter into the critical section next.

Bounded Waiting: In this step, bound prohibits the number of processes to enter into the critical section, after a process has requested to enter into the critical section and before it is granted.


Related Solutions

Find the critical depth, critical slope and Froude Number at section y=0.9 m in a 0.55...
Find the critical depth, critical slope and Froude Number at section y=0.9 m in a 0.55 m wide, m=1 trapezoidal channel carrying water at the rate of 0.95 m3/s. n=0.016.
Is there any electric field inside a perfect conductor? Is there any conduction current inside a...
Is there any electric field inside a perfect conductor? Is there any conduction current inside a perfect conductor? Can static magnetic fields exist in a perfect conductor?
2 – The CPU design team is designing an instruction set with three classes of instructions....
2 – The CPU design team is designing an instruction set with three classes of instructions. Parameters are given in the following table. Consider a program with 65% ALU instructions, 20% memory access instructions, and 15% control instructions. What is the average CPI for this CPU? Clock Rate: 4GHz CPI for ALU Inst.: 4 CPI for Memory Inst.: 8 CPI for Control Inst.: 2
What are the limitations of forward-bias, if any, on a semiconductor diode? What are the limitations...
What are the limitations of forward-bias, if any, on a semiconductor diode? What are the limitations of reverse-bias, if any, on a semiconductor diode? What portion, if any of the volt-ampere characteristic of the diode (when it is forward-biased) is linear? What can you say about the d-c resistance of the diode over this linear portion?
Why is the cash flow position the most critical aspect of any company?
Why is the cash flow position the most critical aspect of any company?
Instructions: Answer the questions below, NO PLAGIARISM. *What are the strengths and limitations of the range?...
Instructions: Answer the questions below, NO PLAGIARISM. *What are the strengths and limitations of the range? *Can the measure central tendency and the measures of spread be used together to describe a set of scores? Of so, how? *How are the standard deviation and the variance similar? how are they different? *Create a question using standard deviation, including the answer.
Discuss any limitations of the management approaches to motivation
Discuss any limitations of the management approaches to motivation
Assume you have a superscalar CPU with in-order issue and in-order instructions that uses 8 registers...
Assume you have a superscalar CPU with in-order issue and in-order instructions that uses 8 registers (R0-R7). The usual rules include: up to two instructions can be issued in one cycle; instructions have to complete in the order they are issued; an instruction attempting to write to a register that is being read by any incomplete instruction cannot be issued until the incomplete instruction completes; any instruction attempting to read a register that is being written to by any incomplete...
I need to complete this C++ program. The instructions are in the comments inside the code...
I need to complete this C++ program. The instructions are in the comments inside the code below: ------------------------------------------------------------------------- Original string is: this is a secret! Encypted string is: uijt!jt!b!tfdsfu" Decrypted string is: this is a secret! //Encoding program //Pre-_____? //other necessary stuff here int main() { //create a string to encrypt using a char array cout<< "Original string is: "<<string<<endl; encrypt(string); cout<< "Encrypted string is: "<<string<<endl; decrypt(string); cout<<"Decrypted string is: "<<string<<endl; return 0; } void encrypt(char e[]) { //Write implementation...
What is Internal Revenue Code Section 243 and what are the limitations and purposes?
What is Internal Revenue Code Section 243 and what are the limitations and purposes?
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT