Unit3 - Subjective Questions

CSE316 • Practice Questions with Detailed Answers

1

Define the Critical Section Problem and explain the three necessary conditions that a solution to the critical section problem must satisfy.

2

Explain Semaphores. Distinguish between Counting Semaphores and Binary Semaphores. Write the pseudo-code for wait() and signal() operations.

3

Describe Peterson's Solution for the critical section problem for two processes. Prove how it satisfies Mutual Exclusion.

4

Explain the Producer-Consumer Problem. Provide a solution using Semaphores.

5

What are Monitors in the context of process synchronization? How do they differ from semaphores?

6

Discuss the Dining Philosophers Problem. Explain the issues involved and provide a strategy to avoid deadlock.

7

Compare User-level Threads and Kernel-level Threads. Highlight their advantages and disadvantages.

8

Explain the Readers-Writers Problem. Distinguish between the 'First' and 'Second' variations of this problem.

9

Define Cooperating Processes and explain how they communicate.

10

Discuss Hardware Primitives for synchronization. Explain TestAndSet and Swap instructions.

11

What are Multithreading Models? Explain Many-to-One, One-to-One, and Many-to-Many models.

12

Explain the concept of Scheduler Activations.

13

What is a Race Condition? Give an example.

14

Differentiate between a Process and a Thread.

15

Explain the concept of a Precedence Graph with a diagrammatic representation explanation.

16

Describe the Hierarchy of Processes.

17

Provide an example of a Threaded Program (conceptual or pseudo-code) showing the creation and joining of threads.

18

What is Bounded Waiting in critical section solutions? Why is it important?

19

What are the drawbacks of using Semaphores?

20

Explain the Classical Two-Process Solution (like Dekker's or Peterson's) vs N-Process Solutions (like Bakery Algorithm).