Multiprocessing Architecture Quiz Form
Test your knowledge of processes, concurrency, communication, and performance.
What is a key distinction between a process and a thread?
*
Processes have separate address spaces; threads within a process share its address space.
Threads always run on separate computers, while processes do not.
Processes cannot execute concurrently, but threads can.
A process is a unit of scheduling, while a thread is a stored file.
When does parallelism occur?
*
When multiple tasks execute at the same time on separate processing resources.
Whenever one task switches rapidly between several states.
When tasks are queued but never executed concurrently.
Only when a program uses shared memory.
In a Unix-like system, what does a successful fork-style process creation typically produce?
*
A child process that begins as a copy of the calling process.
A new thread that shares the caller's stack and execution state.
A new processor core dedicated to the caller.
A message queue that automatically launches a program.
Which is an example of inter-process communication (IPC)?
*
Two processes exchange data through a message queue.
A process changes a local variable that no other process can access.
A processor executes an instruction from its cache.
A thread updates its private register.
What is the primary purpose of a mutex in concurrent programming?
*
To provide exclusive access to a shared resource while it is in use.
To create additional processor cores for a process.
To copy all process memory into a separate address space.
To guarantee that every task finishes in a fixed order.
What is a common benefit of shared memory for communication between processes?
*
Processes can exchange data efficiently by accessing a common memory region.
It removes the need to coordinate concurrent access.
It prevents any process from reading another process's data.
It guarantees that data is automatically distributed evenly across processors.
What can cause a race condition?
*
Concurrent operations access shared state, and the result depends on their timing.
A process uses more than one memory page.
A scheduler assigns a task to a processor.
Two processes exchange messages in a defined sequence.
Which situation describes a deadlock?
*
Processes wait indefinitely for resources held by one another.
A process finishes its work and releases all resources.
A scheduler temporarily pauses a process to run another.
A worker completes its task before the next task is assigned.
How does load balancing help a multiprocessing system?
*
It distributes work across available processors or workers to reduce uneven utilization.
It ensures every task uses the same amount of memory.
It eliminates the need for synchronization.
It forces all tasks to run sequentially on one processor.
Why might adding more processes fail to improve a program's performance?
*
Coordination, communication, and process-management overhead can outweigh the parallel work.
Processes cannot execute on more than one processor.
Parallel programs never spend time waiting for data.
Each additional process automatically reduces the amount of available memory.
Submit Quiz
Should be Empty: