Login
Register
Dark Mode
Brightness
Profile
Edit Profile
Messages
My favorites
My Updates
Logout
Process Synchronization
Recent questions tagged process-synchronization
6
votes
1
answer
331
deadlock
If ‘m’ processes share ‘n’ resources of the same type, the maximum need of each process does not exceed ‘n’ and the sum of all their maximum needs is always less than ‘m+n’. In this case: (a) Deadlock can never occur (b) Deadlock may occur (c) Deadlock has to occur (d) None
If ‘m’ processes share ‘n’ resources of the same type, the maximum need of each process doesnot exceed ‘n’ and the sum of all their maximum needs is always le...
harshit agarwal
2.1k
views
harshit agarwal
asked
Dec 17, 2016
Operating System
deadlock-prevention-avoidance-detection
operating-system
process-synchronization
+
–
0
votes
1
answer
332
Made easy booklet- Synchronisation: What are possible outcomes?
Please help in part b) What are the potential outcomes? Answer:
Please help in part b) What are the potential outcomes?Answer:
agoh
381
views
agoh
asked
Dec 11, 2016
Operating System
operating-system
process-synchronization
+
–
3
votes
4
answers
333
If there is deadlock possible, is it correct to conclude that progress and bounded wait will be violated?
My doubt is as follows: If deadlock is there, processes will be busy waiting in wait loop. So, decision on which process enters C.S. is not made in finite time. Hence, is...
agoh
1.1k
views
agoh
asked
Dec 11, 2016
Operating System
deadlock-prevention-avoidance-detection
process-synchronization
+
–
6
votes
1
answer
334
GATE CSE 1989 | Question: 11b
Consider the following precedence graph $(\text{Fig}.6)$ of processes where a node denotes a process and a directed edge from node $P_{i}$ to node $P_{j}$ implies; that $P_{i}$ must complete before $P_{j}$ commences. Implement the graph using FORK and JOIN constructs. The actual computation done by a process may be indicated by a comment line.
Consider the following precedence graph $(\text{Fig}.6)$ of processes where a node denotes a process and a directed edge from node $P_{i}$ to node $P_{j}$ implies; that $...
makhdoom ghaya
2.5k
views
makhdoom ghaya
asked
Dec 9, 2016
Operating System
gate1989
descriptive
operating-system
precedence-graph
process-synchronization
+
–
4
votes
1
answer
335
MadeEasy Test Series: Operating System - Process Synchronization
question :
question :
dd
1.4k
views
dd
asked
Dec 5, 2016
Operating System
made-easy-test-series
operating-system
process-synchronization
+
–
0
votes
1
answer
336
[Strong/Weak Semaphore] Operating system Chapter -5 William Stallings 7th Edition
How the processes are removed from the Semaphore suspended queue?Is it implementation dependent or is it FIFO always?If not FIFO then how starvation will be handled.I got this doubt while reading following ... Priority based/SJf..etc ,then it will neither be strong semaphore nor weak semaphore?# Please clarify
How the processes are removed from the Semaphore suspended queue?Is it implementation dependent or is it FIFO always?If not FIFO then how starvation will be handled.I got...
rahul sharma 5
3.4k
views
rahul sharma 5
asked
Dec 4, 2016
Operating System
operating-system
process-synchronization
algorithms
semaphore
+
–
1
votes
4
answers
337
Suppose that an operating system provides two functions
Suppose that an operating system provides two functions, block_queue() which puts the calling process on the blocked queue, and wakeup_queue(P)which moves process P to the runnable queue if it is currently on the ... the Following statement is true? it prints P0P1 alternatively always. It prints P1P0 alternatively always Deadlock possible None
Suppose that an operating system provides two functions, block_queue() which puts the calling process on the blocked queue, and wakeup_queue(P)which moves process P to th...
Akriti sood
832
views
Akriti sood
asked
Dec 4, 2016
Operating System
operating-system
deadlock-prevention-avoidance-detection
process-synchronization
+
–
1
votes
1
answer
338
MadeEasy Test Series: Operating System - Process Synchronization
#plz check???
#plz check???
Hradesh patel
691
views
Hradesh patel
asked
Nov 29, 2016
Operating System
made-easy-test-series
operating-system
process-synchronization
+
–
12
votes
1
answer
339
progress and deadlock
Is is true that...If there is deadlock then system can not progress?
Is is true that...If there is deadlock then system can not progress?
vaishali jhalani
4.9k
views
vaishali jhalani
asked
Nov 26, 2016
Operating System
deadlock-prevention-avoidance-detection
operating-system
process-synchronization
progress
+
–
2
votes
0
answers
340
GATE CSE 1990 | Question: 9a
Assume that an instruction test-and-set (TS) has been provided in a machine whose function is as follows: 'the left most bit of the one byte operand is checked and accordingly the condition code (CC) is set to $1$ or $0$. After checking and setting the condition code, implement a critical region using this instruction.
Assume that an instruction test-and-set (TS) has been provided in a machine whose function is as follows: 'the left most bit of the one byte operand is checked and accord...
makhdoom ghaya
894
views
makhdoom ghaya
asked
Nov 24, 2016
Operating System
descriptive
gate1990
operating-system
process-synchronization
critical-section
unsolved
+
–
7
votes
2
answers
341
OS Synchronization
Consider the following program: Const int n= 10 int Count= 0 Void A( ) { int i; for(i= 1 to n) Count= Count + 1; } Main ( ) { Par begin A( ); A( ); A( ); A( ); Par end } 5 What is the minimum and maximum possible value of count after the completion of the program? (a) 1, 40 (b) 2, 40 (c) 3, 40 (d) 4, 40
Consider the following program: Const int n= 10 int Count= 0 Void A( ) { int i; for(i= 1 to n) Count= Count + 1; } Main ( ) { Par begin A( ); A( ); A( ); A( ); Par end }5...
target2017
4.3k
views
target2017
asked
Nov 23, 2016
Operating System
process-synchronization
operating-system
+
–
30
votes
2
answers
342
GATE CSE 1990 | Question: 2-iii
Match the pairs:$\begin{array}{|ll|ll|}\hline (a) & \text{Critical region} & (p) & \text{Hoare's monitor} \\ (b) & \text{Wait/Signal} & (q) & \text{Mutual exclusion} \\ (c) & \text{Working Set} & (r) & \text{Principle of locality} \\ (d) & \text{Deadlock} & (s) & \text{Circular Wait} \\\hline \end{array}$
Match the pairs:$$\begin{array}{|ll|ll|}\hline (a) & \text{Critical region} & (p) & \text{Hoare's monitor} \\ (b) & \text{Wait/Signal} & (q) & \text{Mutual exclusion} \\ ...
makhdoom ghaya
6.1k
views
makhdoom ghaya
asked
Nov 18, 2016
Operating System
match-the-following
gate1990
operating-system
process-synchronization
+
–
22
votes
1
answer
343
GATE CSE 1990 | Question: 1-vii
Semaphore operations are atomic because they are implemented within the OS _________.
Semaphore operations are atomic because they are implemented within the OS _________.
makhdoom ghaya
7.8k
views
makhdoom ghaya
asked
Nov 18, 2016
Operating System
gate1990
operating-system
semaphore
process-synchronization
fill-in-the-blanks
+
–
13
votes
1
answer
344
GATE CSE 1987 | Question: 8a
Consider the following proposal to the "readers and writers problem." Shared variables and semaphores: aw, ar, rw, rr : interger; mutex, reading, writing: semaphore: initial values of variables and states of semaphores: ar=rr=aw ... group of readers make waiting writers starve? Can writers starve readers? Explain in two sentences why the solution is incorrect.
Consider the following proposal to the "readers and writers problem."Shared variables and semaphores:aw, ar, rw, rr : interger; mutex, reading, writing: semaphore: initia...
makhdoom ghaya
3.1k
views
makhdoom ghaya
asked
Nov 14, 2016
Operating System
gate1987
operating-system
process-synchronization
descriptive
+
–
24
votes
1
answer
345
GATE CSE 1987 | Question: 1-xvi
A critical region is One which is enclosed by a pair of $P$ and $V$ operations on semaphores. A program segment that has not been proved bug-free. A program segment that often causes unexpected system crashes. A program segment where shared resources are accessed.
A critical region isOne which is enclosed by a pair of $P$ and $V$ operations on semaphores.A program segment that has not been proved bug-free.A program segment that oft...
makhdoom ghaya
5.2k
views
makhdoom ghaya
asked
Nov 8, 2016
Operating System
gate1987
operating-system
process-synchronization
+
–
2
votes
1
answer
346
difference among Critical Section ,Mutual Exclusion and Semaphore
difference in following: [i] mutual exclusion [ii] critical section [iii] semaphore
difference in following: [i] mutual exclusion [ii] critical section [iii] semaphore
LavTheRawkstar
1.7k
views
LavTheRawkstar
asked
Nov 4, 2016
CO and Architecture
operating-system
process-synchronization
critical-section
deadlock-prevention-avoidance-detection
semaphore
co-and-architecture
+
–
0
votes
0
answers
347
process synchoronozation and semaphores
The Semaphore variable full, empty and mutex are initialized to 0, n and 1 respectively. Process P1 repeatedly adds one item at a time to a buffer of size n, and process P2 repeatedly removes one item at a time from the same buffer using the programs given below. In the ... (c) P(empty), V(full), P(empty), V(full) (d) P(empty), V(full), P(full), V(empty)
The Semaphore variable full, empty and mutex are initialized to 0, n and 1 respectively. Process P1 repeatedly adds one item at a time to a buffer of size n, and process ...
Lone Wolf
382
views
Lone Wolf
asked
Oct 27, 2016
Operating System
semaphore
and
process-synchronization
+
–
5
votes
2
answers
348
operating system process synchronization
var occupied var blocked Enter Region: { If (occupied) { blocked= blocked +1 sleep ( ); } else occupied= 1; } // (critical section) Exit Region: { occupied= 0 If (blocked) { wakeup (process); blocked= blocked - 1; } } Now consider the following statements ... of the above statements are False? (a) Only 1 (b) 1 & 2 (c) 1 & 3 (d) none of the above
var occupied var blocked Enter Region: { If (occupied) { blocked= blocked +1 sleep ( ); } else occupied= 1; } // (critical section) Exit Region: { occupied= 0 If (block...
Lone Wolf
1.0k
views
Lone Wolf
asked
Oct 27, 2016
Operating System
process-synchronization
+
–
0
votes
1
answer
349
Which of the following statements is/are true?
The Operations P(S) & V(S) needs to be atomic. A process exiting the CS will call V(S) Busy-Wait' solutions to the Critical Section are typically implemented using machine instructions that execute in the Kernel mode All of ... the above process to enter the critical section) will never be able to run. Are my points incorrect? Please advice.
The Operations P(S) & V(S) needs to be atomic.A process exiting the CS will call V(S)‘Busy-Wait’ solutions to the Critical Section are typically implemented using mac...
rickeshjohn
3.3k
views
rickeshjohn
asked
Oct 22, 2016
Operating System
process-synchronization
operating-system
test-series
+
–
0
votes
1
answer
350
#self made
In lock variable mechanism of the following modified code , if we execute the code then can mutul exclusion be satisfied.?? 1. Load Ri , M[lock] 2. cmp Ri, # 0 3. store # 1,M[lock] 4. JZ to step 1 CS 5. store # 0, M[lock]
In lock variable mechanism of the following modified code , if we execute the code then can mutul exclusion be satisfied.??1. Load Ri , M[lock]2. cmp Ri, # 03. store # ...
Aman Jha
348
views
Aman Jha
asked
Oct 21, 2016
Operating System
process-synchronization
lock-variable
+
–
3
votes
2
answers
351
Self Doubt
Q : Each process Pi , i = 1 to 9 executes the following code : while (TRUE) { P(mutex); Critical section ; V(mutex); } The process P10 executes the following code : while(TRUE) { V(mutex); critical section ; P(mutex); } Initial value of binary semaphore "mutex" = ... at any instant of time? a) 2 b) 3 c) 9 d) 10 e) 1 Plz explain in details which one is true out of these options.
Q : Each process Pi , i = 1 to 9 executes the following code : while (TRUE) { P(mutex); Critical section ; V(mutex);}The process P10 executes the foll...
Habibkhan
2.9k
views
Habibkhan
asked
Oct 16, 2016
Operating System
operating-system
process-synchronization
binary-semaphore
+
–
5
votes
3
answers
352
Two process critical section software solution
// a software solution for critical section problem bool flag[2]; int turn; void process(int id) { while(true) { flag[id] = true; while(turn != id) { while(flag[1-id]); turn = id; } < Critical Section > ... return 0; } Which of the following is false ? Mutual exclusion is satisfied. Progress is satisfied. Bounded waiting is satisfied. None.
// a software solution for critical section problem bool flag ; int turn; void process(int id) { while(true) { flag[id] = true; while(turn != id) { while(flag[1-id]); tur...
dd
2.6k
views
dd
asked
Oct 14, 2016
Operating System
operating-system
process-synchronization
critical-section
+
–
3
votes
1
answer
353
OS Synchronization
In process synchronozation , when we can say progress is satisfied and when progress not satisfied? Explain with example. (Donot give just definition, need clear difference when progress is satisfied and when not satisfied)
In process synchronozation , when we can say progress is satisfied and when progress not satisfied?Explain with example.(Donot give just definition, need clear difference...
srestha
1.3k
views
srestha
asked
Oct 14, 2016
Operating System
process-synchronization
+
–
0
votes
2
answers
354
Doubt in some basic things synchronisation
I have some fundamental doubts regarding the conditions which need to be followed for a correct synchronisation solution i.e. about mutual exclusion , progress and bounded wait. I m asking these. Plz address to these doubts but give a ... for the fact whether the bounded wait condition is satisfied or not? Also plz support your answer with proper reason..
I have some fundamental doubts regarding the conditions which need to be followed for a correct synchronisation solution i.e. about mutual exclusion , progress and bounde...
Habibkhan
1.3k
views
Habibkhan
asked
Oct 14, 2016
Operating System
operating-system
process-synchronization
+
–
1
votes
2
answers
355
synchronization reader's writer's problem.
int readers_count = 0; semaphore mutex = 1; // binary semaphore semaphore db = 1; // binary semaphore void reader() { while(TRUE) { x. down(mutex); //or wait(mutex) or P(mutex) readers_count = readers_count + 1; y. if(readers_count ... and writers are allowed in the database at the same time. c. There is possibility of deadlock. d. None of the above.
int readers_count = 0; semaphore mutex = 1; // binary semaphore semaphore db = 1; // binary semaphore void reader() { while(TRUE) { x. down(mutex); //or wait(mutex) or P(...
dd
2.3k
views
dd
asked
Oct 11, 2016
Operating System
process-synchronization
deadlock-prevention-avoidance-detection
operating-system
+
–
1
votes
1
answer
356
pthreads
Suppose you have an array A of 4 numbers and you have 2 threads. how will you perform a cumulative sum of numbers and store it in array B using parallel computation and synchronization. (B[1]=A[1], B[2]=A[1] + A[2],.. so on
Suppose you have an array A of 4 numbers and you have 2 threads. how will you perform a cumulative sum of numbers and store it in array B using parallel computation and ...
.
457
views
.
asked
Oct 10, 2016
Operating System
threads
process-synchronization
+
–
0
votes
1
answer
357
process sychronization
What is spinlock? What are the advantages of having spinlock?
What is spinlock?What are the advantages of having spinlock?
vaishali jhalani
588
views
vaishali jhalani
asked
Oct 7, 2016
Operating System
operating-system
process-synchronization
+
–
0
votes
0
answers
358
process synchronisation
What is the difference between MUTEX and Binary Semaphores.
What is the difference between MUTEX and Binary Semaphores.
vaishali jhalani
580
views
vaishali jhalani
asked
Oct 7, 2016
Operating System
operating-system
process-synchronization
+
–
11
votes
1
answer
359
Difference between Dekkers and Peterson solutions to Critical Section Problem
Dekkers Algorithm flag[0]=true; while(flag[1]==true) { if(turn!=0) { flag[0]=false; while(turn!=0); flag[0]=true; } } // CS turn=1; flag[0]=false; Peterson Algorithm flag[0]=true; turn=1; ... [1]==true&&turn==1); // CS flag[0]=false Account on the Mutual Exclusion Bound Waiting Deadlock and Starvation Progress
Dekkers Algorithmflag[0]=true; while(flag ==true) { if(turn!=0) { flag[0]=false; while(turn!=0); flag[0]=true; } } // CS turn=1; flag[0]=false;Peterson Algorithm flag[0]=...
pC
11.8k
views
pC
asked
Oct 6, 2016
Operating System
operating-system
process-synchronization
critical-section
+
–
2
votes
2
answers
360
critical section
vaishali jhalani
1.1k
views
vaishali jhalani
asked
Oct 5, 2016
Operating System
operating-system
process-synchronization
+
–
Page:
« prev
1
...
7
8
9
10
11
12
13
14
15
16
next »
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register