Parallel processing Pipelining Decomposing a sequential process into

  • Slides: 6
Download presentation
Parallel processing Pipelining: • Decomposing a sequential process into suboperations, with each subprocess being

Parallel processing Pipelining: • Decomposing a sequential process into suboperations, with each subprocess being executed in a special dedicated segment that operates concurrently with all other segments • Each segment performs partial processing • The result obtained from the computations in each segment is transferred to the next segment in the pipeline • The final result is obtained after the data have passed through all segments

An example: • Ai * B i + C i Ai for i= 1,

An example: • Ai * B i + C i Ai for i= 1, 2, 3……. . 7 Bi R 1 Ci R 2 multiplier R 3 R 4 adder R 5

Clock pulse no. 1 2 3 4 5 6 7 segment 1 R 2

Clock pulse no. 1 2 3 4 5 6 7 segment 1 R 2 A 1 B 1 A 2 B 2 A 3 B 3 A 4 B 4 A 5 B 5 A 6 B 6 A 7 B 7 segment 2 R 3 R 4 A 1 * A 2 * A 3 * A 4 * A 5 * A 6 * A 7 * B 1 B 2 B 3 B 4 B 5 B 6 B 7 segment 3 R 5 A 1* B 1 +C 1 A 2* B 2 + C 2 A 3* B 3 + C 3 A 4* B 4 +C 4 A 5* B 5 + C 5 A 6* B 6 + C 6 A 7* B 7 + C 7

General considerations • Any operation that can be decomposed into a sequence of suboperations

General considerations • Any operation that can be decomposed into a sequence of suboperations of about the same complexity can be implemented by a pipeline processor Clock Input S 1 R 1 S 2 R 2 S 3 R 3 S 4 R 4 A task is the total operation performed going through all the segments in the pipeline

Space time diagram clock cycles 1 2 3 4 Segment 1 T 2 T

Space time diagram clock cycles 1 2 3 4 Segment 1 T 2 T 3 T 4 2 T 1 T 2 T 3 3 T 1 T 2 4 T 1 5 T 4 T 3 T 2 6 T 5 T 4 T 3 7 8 9 T 6 T 5 T 4 T 6 T 5 T 6 To complete n tasks using a k segment pipeline it requires k + (n-1) clock cycles

 • Consider a nonpipeline unit that performs the same operation and takes a

• Consider a nonpipeline unit that performs the same operation and takes a time equal to tn to complete each task. So total time for n tasks ntn • Speed up of a pipeline processing over an equivalent non pipeline processing is defined by the ratio ntn S= (k+n-1)tp tn As n increases S= tp tn = k tp then S = k