CSCI 463
Math - Clock speeds and cpu pipes.
Due in class, Monday, 14 Oct. 2013.
50 points

The following are a series of math problems common to computer systems. Work out each problem. Do the work on a separate piece of paper with a pencil and show your work. Typed/computer printed assignments not accepted. Include units of measurement in the conversion.

Base 10 - Clock speeds

Ex. 1 MHz = 1 * 10^6 cycles/sec.
One clock cycle is 1 / ( 1 * 10^6 cycles/sec. ) or 1/1 * 1/(10^6 cycles/sec).
1 over a power flips the units and the sign is inverted, so 1/10^6 cycles/sec becomes 10^-6 secs/cycle.
or 1 * 10^-6 secs/cycle * 1 uSec/10^-6 sec = 1 uSec/cycle

1 Hertz = 1 Hz = 1 cycle/sec.

Calculating the length of a clock cycle by dividing clock speed into 1 :

1/(1 THz) * 1 THz/1*10^12 cycles/sec = 1/(1*10^12 cycles/sec) 2 points each

1/(1*10^12 cycles/sec) = 1 * 10^-12 sec/cycle

1 * 10 ^-12 sec/cycle * 1psec / 1 10^-12 sec = 1psec

Clock speedLength of clock cycle
1 THz 1 psec picosecond 1 * 10^12 sec.
1 GHz GigaHertz 10^9 1 ns nanosecond 10^-9 sec.
1 MHz MegaHertz 10^6 1 us microsecond 10^-6 sec. Note u is actually greek mu. μ
1 KHz KiloHertz 10^3 1 ms millisecond 10^-3 sec.

Use 6 digits precision for answers.

1. Given the following clock speeds, give the time of a single clock cycle in the units specified in the third column. (2 points each, 10 points total)

.
Clock speed Cycle Time
A.   25 MHz  in ns. (nanoseconds)
B.   300 baud (300 Hertz)  in ms. (milliseconds)
C.   500 MHz in ns. (nanoseconds)
D.   2 GHz in ps. (picoseconds)
E.   4 KHz in us. (microseconds)

2. Given the following time for a single clock cycle, give the speed of the clock in cycles/sec. (2 points each, 10 points total )

Cycle Time
A.   1 ns. (nanoseconds)
B.   10 ms. (milliseconds)
C.   8 us. (microsecond)
D.   25 us. (microseconds)
E.   40 ps. (picoseconds)


3.,4.,5. Pipelines and Parallel architecture.

Working with units :
1 cycle/sec. * 1 inst./cycle = 1 inst./sec.
1 inst./sec. * 1 sec/cycle. = 1 inst./cycle.

Example :
Instruction takes 1 uS (microsecond) to complete : If 1 inst. / 10-6 sec.,
then 1 inst./usec. * 10^6 usec./sec. = 10^6 inst./sec.

Given a datapath with a fetch (fi), decode (de), fetch operand (fo) execute(ex), and a writeback(wb) stage.

Given a 1 GHz cpu, the cycle time is 1 ns per clock cycle.

This table presents 3 instruction types with their timing signature for each step of a fetch/execute pipeline.

Carry the number out to 6 significant digits if needed. (2 points each step, each instruction type, 30 points total )

Type Fetch
opcode
Decode Fetch
operands
Execute Write back
A 1 clock   1 clocks   1 clocks   1 clocks   1 clock  
B 1 clock   1 clocks   4 clocks   10 clocks   4 clock  
C 1 clock   1 clock   4 clocks   4 clock   0 clock  

For each instruction type, find the following. Work all parts for one type at a time.

A. Give the time it takes to process one instruction.

B. If pipelining not supported, calculate number of instructions per second.

C. If pipeline supported and full, how often is an instruction completed.

D. Calculate number of instructions per second.

E. If the execution step is paralleled, calculate the number of instructions per second.