Exam 5: Exploring Thread Synchronization and Mutual Exclusion in Java

arrow
  • Select Tags
search iconSearch Question
  • Select Tags

Which property of mutual exclusion primitives is inappropriate for multiprocessor systems?

Free
(Multiple Choice)
4.8/5
(40)
Correct Answer:
Verified

A

Semaphores can be used for each of the following purposes except:

Free
(Multiple Choice)
4.9/5
(23)
Correct Answer:
Verified

B

Which of the following statements about critical sections is false?

Free
(Multiple Choice)
5.0/5
(30)
Correct Answer:
Verified

D

________ occurs when an infinite loop prevents progress in a multithreaded application.

(Multiple Choice)
4.9/5
(46)

A ________ is a variable that governs access to critical sections.

(Multiple Choice)
4.9/5
(29)

The test-and-set instruction ________.

(Multiple Choice)
4.8/5
(26)

If a thread attempts a P operation when a counting semaphore has been decremented to zero, ________.

(Multiple Choice)
4.8/5
(32)

________ restricts access to a shared variable to only one thread at any given time.

(Multiple Choice)
4.8/5
(39)

A thread that uses processor cycles to continually test a condition before entering its critical section is said to be ________.

(Multiple Choice)
4.8/5
(36)

Disabling interrupts ________.

(Multiple Choice)
4.8/5
(30)

Threads that operate independently of one another but must occasionally interact to perform cooperative tasks are said to execute ________.

(Multiple Choice)
4.8/5
(25)

An example of a producer/consumer relationship is ________.

(Multiple Choice)
4.8/5
(28)

Which of the following statements about semaphores is true?

(Multiple Choice)
4.8/5
(31)

What happens when a thread calls P( S ) when it wants to enter its critical section, where S is a binary semaphore set to 1?

(Multiple Choice)
4.9/5
(42)

Lamport's Bakery Algorithm does not require ________.

(Multiple Choice)
4.9/5
(36)

Which of the following mutual exclusion algorithms require instructions to be executed atomically?

(Multiple Choice)
4.9/5
(38)

Semaphore operations can be implemented in the kernel of a multiprocessor system by:

(Multiple Choice)
4.9/5
(41)

In Java, the sleep method call must appear in part of a ________ statement because it might throw an exception indicating that the thread was interrupted before its sleep time expired.

(Multiple Choice)
4.8/5
(34)

In Java, Object method notify transitions a thread from the ________ state to the ________ state.

(Multiple Choice)
4.7/5
(29)

Code inside a critical section should ________.

(Multiple Choice)
4.9/5
(38)
Showing 1 - 20 of 26
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)