Parallel Processor Organization: Memory, Coordination, and Speedup

Parallel Processor Organization concerns how multiple processing units cooperate on a computation: where their data reside, how they exchange results, and what limits their combined performance. You encounter these questions when choosing between a multicore server and a cluster, or when explaining why doubling the number of cores does not halve a program's running time. The organization matters alongside the amount of work that can run simultaneously.

Organizing access to memory

In a shared-memory organization, processors can access a common memory address space. They exchange data through shared locations, although individual workers can also maintain private data. A multicore chip contains several processing cores on one chip; a multiprocessor server can also contain several processor packages. Either arrangement can support shared memory.


In a distributed-memory organization, processing nodes have separate local address spaces. Data needed elsewhere are exchanged explicitly, commonly through messages. A cluster can combine both arrangements: cores share memory within each node, while nodes exchange messages across a network.


Two processors access shared memory on the left, while two processors have separate local memories connected by a network on the right.


Shared memory need not occupy one physical bank. With NUMA, processors can access a shared address space even though some memory is physically closer to particular processors. UMA describes the contrasting arrangement.


Organization

Memory visible to processors

Typical communication concern

Shared memory with UMA

Common address space with approximately uniform access time

Contention for shared memory bandwidth

Shared memory with NUMA

Common address space with location-dependent access time

Placement of data near the processors using them

Distributed memory

Separate local address spaces

Message transfer and coordination between nodes


Physical distribution of memory does not, by itself, establish separate address spaces. Also distinguish hardware organization from programming interfaces: message-passing software can run on a shared-memory machine.

Coordinating cooperating processors

Parallel workers need both the right data and permission to use those data at the right time. Cache coherence addresses agreement between cached copies. Synchronization controls interactions between workers, such as protecting a shared update or waiting for required results.


A counter increment illustrates the distinction. Reading the counter, adding one, and writing the result are separate operations unless an appropriate mechanism combines or protects them. Two workers can read the same old value and overwrite each other's increments even with coherent caches. A correctly used lock can protect the complete update.



Performance also depends on how work is divided. If one worker receives substantially more work, others may wait at a barrier. More processors can also increase traffic on shared communication and memory paths.

Predicting fixed-workload performance

For a useful baseline, assume identical cores, a fixed workload, and perfectly balanced division of its parallelizable work. Let T1T_1 be the one-core time, ss its serial fraction, NN the number of cores, and HNH_N the additional, non-overlapping elapsed-time overhead at NN cores. Then


TN=T1(s+1−sN)+HN.T_N=T_1\left(s+\frac{1-s}{N}\right)+H_N.


The serial work retains its original duration. Only the parallelizable portion is divided by NN. Overhead can include additional communication, startup, and synchronization costs; it is elapsed time, not the sum of all workers' waiting times.


The speedup and parallel efficiency are


SN=T1TN,EN=SNN.S_N=\frac{T_1}{T_N},\qquad E_N=\frac{S_N}{N}.


Efficiency is normalized speedup, rather than a direct measurement of processor utilization. Multiply it by 100%100\% to report a percentage.


With HN=0H_N=0, this is Amdahl's law. For s>0s>0, its ideal limiting speedup is 1/s1/s. This bound assumes the same fixed workload and unchanged serial work. Positive overhead reduces speedup within the model; overhead that grows with core count can even make an added core configuration slower.



What to remember

  • Classify memory by addressability as well as physical placement.
  • Separate cache coherence from synchronization.
  • Divide parallel work, retain serial work, and add stated overhead.
  • Compare configurations using elapsed time, speedup, and efficiency.

Example: Choosing cores for a scan-processing job

A laboratory's scan-processing job takes 160 s on one core. Preparing the input takes 20 s and remains serial. The remaining processing can be divided evenly among identical cores, each working at the original one-core rate. Additional parallel overhead, meaning elapsed time added by startup and coordination, is 5 s on four cores and 8 s on eight cores. These costs do not overlap the useful computation. Compare configurations for the same fixed job.


a) Calculate the elapsed time on four cores.


First separate the unchanged preparation from the work that can be divided. The parallelizable portion of the one-core execution is ________, since


Tparallel,1=160 s−20 s=140 s.T_{\text{parallel},1}=160\ \text{s}-20\ \text{s}=140\ \text{s}.


With balanced work on four cores, the parallel phase lasts ________:


Tparallel,4=140 s4=35 s.T_{\text{parallel},4}=\frac{140\ \text{s}}{4}=35\ \text{s}.


The preparation, parallel processing, and additional overhead occur without overlap, so add their durations:


T4=20 s+35 s+5 s=60 s.T_4=20\ \text{s}+35\ \text{s}+5\ \text{s}=60\ \text{s}.


The four-core elapsed time is 60.0 s. Dividing the full 160 s by four would incorrectly accelerate the serial preparation and omit overhead.


b) Calculate four-core speedup and efficiency. Report speedup to two decimal places and efficiency to one decimal place.


The speedup compares the original one-core elapsed time with the new elapsed time:


S4=T1T4=160 s60 s=2.666666….S_4=\frac{T_1}{T_4}=\frac{160\ \text{s}}{60\ \text{s}}=2.666666\ldots.


For efficiency, divide this unrounded speedup by four. Equivalently, the denominator 4T44T_4 is ________, giving


E4=1604(60)×100%=66.666666…%.E_4=\frac{160}{4(60)}\times100\%=66.666666\ldots\%.


The four-core configuration gives 2.67 speedup and 66.7% efficiency. These values describe performance relative to the baseline; the efficiency percentage is not a direct measurement of core utilization.


c) Calculate the eight-core elapsed time, speedup, and efficiency using the same reporting precision. Is it faster than the four-core configuration?


The serial preparation still takes 20 s. The evenly divided parallel phase now lasts ________, since


Tparallel,8=140 s8=17.5 s.T_{\text{parallel},8}=\frac{140\ \text{s}}{8}=17.5\ \text{s}.


Include the eight-core overhead rather than reusing the four-core value:


T8=20 s+17.5 s+8 s=45.5 s.T_8=20\ \text{s}+17.5\ \text{s}+8\ \text{s}=45.5\ \text{s}.


Calculate speedup and efficiency without rounding intermediate values:


S8=16045.5=3.516483…,S_8=\frac{160}{45.5}=3.516483\ldots,


E8=1608(45.5)×100%=43.956043…%.E_8=\frac{160}{8(45.5)}\times100\%=43.956043\ldots\%.


The elapsed-time reduction relative to four cores is


60.0 s−45.5 s=14.5 s.60.0\ \text{s}-45.5\ \text{s}=14.5\ \text{s}.


The eight-core configuration takes 45.5 s, gives 3.52 speedup and 44.0% efficiency, and finishes 14.5 s sooner. It is faster, but its normalized efficiency is lower: more cores reduce the parallel phase while serial preparation remains unchanged and overhead increases.

A two-processor server exposes both memory banks in one shared address space. Under comparable conditions, each processor accesses its nearby bank in 80 ns and the other bank in 140 ns. Which classification follows from these facts?


Two processors are connected to their nearby memory banks and to an interconnect between them.


Choose an answer

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

A shared-memory multiprocessor runs software threads across several cores while processing image batches. Match each term to its description. Each description is used once.

Match each term
A.

Different cores concurrently perform distinct functions, such as filtering images and encoding completed results.

B.

Several cores apply the same filter to different images from one batch.

C.

Work is assigned or redistributed to reduce differences in the workloads carried by different cores.

D.

A scheduling preference or restriction assigns a thread to a particular core or set of cores.

Data parallelism

Load balancing

Processor affinity

Task parallelism

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

A fixed data-analysis job takes 200 s on one core and 80 s on four identical cores. Assume no additional parallel overhead, unchanged serial work, and perfectly balanced parallel work that runs four times faster on four cores. What percentage of the one-core execution time is serial? Answer as a percentage, to one decimal place.

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

Extra Practice