Deck 6: Concurrent Processes
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/40
Play
Full screen (f)
Deck 6: Concurrent Processes
1
Test-and-set is a single indivisible machine instruction.In a single machine cycle,it tests to see if a key is available and,if it is,sets it to unavailable.
True
2
Parallel processing is a situation in which two or more processors operate in one system at the same time and may or may not work on related activities.
True
3
The success of process synchronization hinges on the capability of the operating system to make a resource available to other processes while it is being used by one of them.
False
4
In parallel computations,mutual exclusion is achieved automatically because each operation is handled in order,one at a time.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
5
The two operations that can be performed on a semaphore variable are select and increment (P and V).
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
6
The master/slave configuration is a symmetric multiprocessing system.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
7
Java uses both a compiler and an interpreter.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
8
The classic problem of producers and consumers is one in which one or more processes produce some data that one or more processes consume later.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
9
The only tangible benefit of parallel processing systems is faster processing.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
10
Java technology is used for many Web and Internet applications,and it integrates well with browsers that can run Java applets with audio,video,and animation directly in a Web page.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
11
In a loosely coupled system,a job may move from one processor to another during execution.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
12
The primary disadvantage of the WAIT and SIGNAL operation set is that it does not address busy waiting.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
13
The common element in all synchronization schemes is to allow a process to finish work on a critical region of the program before other processes have access to it.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
14
The loosely coupled multiprocessing configuration features several complete computer systems,each with its own memory,I/O devices,CPU,and operating system.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
15
When a programmer indicates in the code which instructions can be executed in parallel in a program (for example,using COBEGIN and COEND),it is called implicit parallelism.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
16
In a master/slave system,the master processor is responsible for managing the entire system-all files,devices,memory,and processors.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
17
Each active thread in a process has its own processor registers,data area,and resources.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
18
Multiprocessing can refer to one job using several processors to execute sets of instructions in parallel.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
19
Early programming languages did not support the creation of threads or the existence of concurrent processes.The Ada programming language was one of the first to do so.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
20
When multiprocessing takes place at the thread level,a high degree of synchronization is required to disassemble each process.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
21
The ____ multiprocessing configuration is the most difficult to implement because the processes must be well synchronized to avoid races and deadlocks.
A) master/slave
B) loosely coupled
C) symmetric
D) shared load
A) master/slave
B) loosely coupled
C) symmetric
D) shared load
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
22
A computer system that can support jobs that use multiple processors to execute sets of instructions in parallel is referred to as a ____ system.
A) concurrent processing
B) process synchronization
C) parallel extraction
D) processing optimization
A) concurrent processing
B) process synchronization
C) parallel extraction
D) processing optimization
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
23
In its simplest form,Amdahl's Law maintains that if a given program would take one hour to run to completion with one processor,but 80 percent of the program had to run sequentially (and therefore could not be sped up by applying additional processors to it),then a resulting parallel program would run only a maximum of ____ percent faster.
A) 5
B) 10
C) 20
D) 25
A) 5
B) 10
C) 20
D) 25
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
24
Most current operating systems support the implementation of threads,or ____,which have become part of numerous application packages.
A) parallel processes
B) lightweight processes
C) heavyweight processes
D) semaphores
A) parallel processes
B) lightweight processes
C) heavyweight processes
D) semaphores
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
25
A ____ of processing must be handled as a single unit.
A) line
B) segment
C) critical region
D) semaphore
A) line
B) segment
C) critical region
D) semaphore
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
26
In general,parallel systems can be put into two broad categories: ____ level parallelism and instruction level parallelism.
A) resource
B) register
C) data
D) task
A) resource
B) register
C) data
D) task
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
27
The ____ multiprocessing configuration is an asymmetric system.
A) loosely coupled
B) master processors
C) start/end
D) master/slave
A) loosely coupled
B) master processors
C) start/end
D) master/slave
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
28
What is the name traditionally given to a semaphore that enforces the concept of mutual exclusion?
A) synch
B) flag
C) mutex
D) signal
A) synch
B) flag
C) mutex
D) signal
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
29
The source code of a Java program is first compiled into an intermediate language called Java ____,which are platform-independent.
A) beans
B) nibs
C) bits
D) bytecodes
A) beans
B) nibs
C) bits
D) bytecodes
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
30
When using the WAIT and SIGNAL operations,____ sets the process's process control block to the blocked state and links it to the queue of processes waiting to enter this particular critical region.
A) TS
B) SIGNAL
C) WAIT
D) BLOCK
A) TS
B) SIGNAL
C) WAIT
D) BLOCK
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
31
The operation P in a semaphore scheme requires a(n)____ sequence to be performed as an indivisible action in a single machine cycle.
A) test, fetch, increment, and store
B) test, fetch, decrement, and store
C) increment and store
D) decrement and store
A) test, fetch, increment, and store
B) test, fetch, decrement, and store
C) increment and store
D) decrement and store
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
32
A problem with test-and-set is that when many processes are waiting to enter a critical region,____ can occur because the processes gain access in an arbitrary fashion.
A) starvation
B) synchronization
C) deadlock
D) an error
A) starvation
B) synchronization
C) deadlock
D) an error
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
33
____ semaphores are used in the solution to the readers and writers problem that does not involve starvation.
A) Zero
B) One
C) Two
D) Three
A) Zero
B) One
C) Two
D) Three
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
34
When a compiler automatically detects instructions that can be performed in parallel,____ is in place.
A) automatic parallelism
B) array parallelism
C) explicit parallelism
D) implicit parallelism
A) automatic parallelism
B) array parallelism
C) explicit parallelism
D) implicit parallelism
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
35
The Java ____ class is a collection of methods used to start,run,stop,and check the status of a thread.
A) Thread
B) Multiprocessing
C) Distributed
D) Concurrency
A) Thread
B) Multiprocessing
C) Distributed
D) Concurrency
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
36
The ____ multiprocessing configuration features several complete computer systems,each with its own memory,I/O devices,CPU,and operating system.
A) loosely coupled
B) master/slave
C) symmetric
D) synchronized
A) loosely coupled
B) master/slave
C) symmetric
D) synchronized
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
37
The two operations defined by Dijkstra to be performed on a semaphore are ____.
A) P and V
B) WAIT and SIGNAL
C) test and set
D) check and update
A) P and V
B) WAIT and SIGNAL
C) test and set
D) check and update
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
38
Lock and key synchronization must take place within a single ____.
A) instruction
B) computer
C) processor
D) machine cycle
A) instruction
B) computer
C) processor
D) machine cycle
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
39
____ proposed a solution to the readers and writers problem that did not result in starvation for readers or writers.
A) Hoare
B) Courtois
C) Heymans
D) Parnas
A) Hoare
B) Courtois
C) Heymans
D) Parnas
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
40
____ semaphores are used in the producer and consumer problem.
A) One
B) Two
C) Three
D) Four
A) One
B) Two
C) Three
D) Four
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck