System Programming MCQs with Answers
Practice important System Programming MCQs with answers and explanations.
Multiple Choice Questions
Q3421: If a thread terminates while inside a critical section without releasing it, other threads will ________.
- A: Be blocked
- B: Proceed normally
- C: Skip the critical section
- D: Be terminated
View Answer
A
Q3422: Mutex abandonment occurs when a thread or process owning the mutex ________.
- A: Terminates without releasing it
- B: Releases it properly
- C: Locks another mutex
- D: Deadlocks
View Answer
A
Q3423: Abandoned mutex handles are ________ by the operating system.
- A: Signaled
- B: Blocked
- C: Destroyed
- D: Delayed
View Answer
A
Q3424: The feature of mutex abandonment is ________ available with Critical Sections.
- A: Not
- B: Always
- C: Sometimes
- D: Usually
View Answer
A
Q3425: When using WaitForSingleObject() with a timeout, if the wait ends due to timeout, the program must ________.
- A: Release the resource
- B: Ignore it
- C: Retry indefinitely
- D: Log the event
View Answer
A
Q3426: Only ________ waiting thread at a time is given ownership of a mutex.
- A: One
- B: Two
- C: Multiple
- D: All
View Answer
A
Q3427: Which system component decides which thread gets mutex ownership based on priority?
- A: OS Scheduler
- B: Programmer
- C: User
- D: Input device
View Answer
A
Q3428: A single mutex can protect ________ critical regions accessed by competing threads.
- A: Multiple
- B: Only one
- C: No
- D: None
View Answer
A
Q3429: To optimize performance, the size of the critical region should be ________.
- A: Minimum
- B: Maximum
- C: Irrelevant
- D: Unbounded
View Answer
A
Q3430: Performance decreases due to excessive use of ________ inside critical regions.
- A: Locks
- B: Threads
- C: Variables
- D: Functions
View Answer
A