Q1. Virtually all contemporary computers are based on concepts developed by John
von Neumann who designed the von Neumann architecture, briefly describe this
architecture indicating the following:
a. Its basic hardware subsystems
b. Its characteristics
c. The functions of the major subsystems within the CPU
Ans:
Its characteristics
Both programs and data are stored in the single memory system.
Instructions are executed in a sequential fashion unless the flow of control is explicitly altered by
a branch type instruction.
There is a single path between the main memory and the control unit of the CPU.
The functions of the major subsystems within the CPU
To clarify the difference between implementation and architecture, the following examples can
be considered:
The architecture of a piano is defined by the user visible interface which is the layout of
the keyboard. The keyboard consists of 88 keys, 36 black and 52 white keys. Each key
corresponds to a specified note. Once a player learns this correspondence, then the player
can use any piano that adheres to this architecture. The implementation, on the other
hand, could employ the striking of strings or the electrical stimulation of oscillators to
generate the sounds produced by the piano. The implementation could be in the form of a
grand piano or an upright; it could employ plastic or ivory keys.
The architecture of an analog clock specifies that there are at least two hands, a minute
hand (the larger hand) and an hour hand (the smaller hand). The relative positions of
these hands on the face of the clock indicate the time of day. Once the correspondence
between the positions of the hands and the indicated time are understood (i.e. once the
architecture is known) any analog clock may be used to tell the time. The implementation
of the clock on the other hand, may specify that Arabic or roman numerals or some other
type of marks be used on the face of the clock. The implementation would also determine
whether a spring or a battery powered oscillator is used to power the clock.
(b).
Suppose that a program runs in 10 seconds on computer A, which has a 100 MHz clock. If a
technique is employed to increase the clock rate of the computer, but the technique causes the
modified computer to require 1.2 times as many clock cycles as the original machine, what new
clock rate would be needed to yield an execution time on the modified machine of 6 seconds?
Ans:
Solution:
The number of clock cycles required on the original machine is given by:
CPU Clock Cycles = CPU Time x Clock Rate
- 10 seconds x 100 x 106 Cycles / Second
CPU clock cycles = 109 cycles
The clock rate required for a 6 second CPU time is given by:
Clock Rate =
CPU Cycles
CPU Time
1.210 9
6 seconds
= 200 MHz
The modified machine would therefore require twice the clock rate to run the
program in 6 seconds.
Q3.
Suppose that a program runs in 10 seconds on computer A, which has a 100 MHz clock. If a
technique is employed to increase the clock rate of the computer, but the technique causes the
modified computer to require 1.2 times as many clock cycles as the original machine, what new
clock rate would be needed to yield an execution time on the modified machine of 6 seconds?
Ans:
Solution:
The number of clock cycles required on the original machine is given by:
CPU Clock Cycles = CPU Time x Clock Rate
- 10 seconds x 100 x 106 Cycles / Second
CPU clock cycles = 109 cycles
The clock rate required for a 6 second CPU time is given by:
Clock Rate =
CPU Cycles
CPU Time
1.210
6 seconds
= 200 MHz
The modified machine would therefore require twice the clock rate to run the
program in 6 seconds.
Q4. Outline EIGHT (8) characteristic differences between RISC and CISC.
Table 1: Characteristics of RISC and CISC
RISC
Simple instructions taking 1 cycle
Only LOADS/STORES reference Memory
Highly Pipeline
Instructions executed by hardware
Fixed format instructions
Few instructions and addressing modes
Complexity is in the compiler
CISC
Complex instructions taking multiple cycle
Any instruction may reference memory
Less pipelined (some are not pipelined at all)
Instructions are interpreted by microcode
Variable format used for instructions
Numerous instructions and addressing modes
Complexity is in the microcode
Q5(a). What is the single precision IEEE floating point representation of the decimal value 0.1?
Q5(b).
Suppose that a program runs in 10 seconds on computer A, which has a 100 MHz clock. If a
technique is employed to increase the clock rate of the computer, but the technique causes the
modified computer to require 1.2 times as many clock cycles as the original machine, what new
clock rate would be needed to yield an execution time on the modified machine of 6 seconds?
Ans:
Solution:
The number of clock cycles required on the original machine is given by:
CPU Clock Cycles = CPU Time x Clock Rate
- 10 seconds x 100 x 106 Cycles / Second
CPU clock cycles = 109 cycles
The clock rate required for a 6 second CPU time is given by:
CPU Cycles
CPU Time
Clock Rate =
1.210
6 seconds
= 200 MHz
The modified machine would therefore require twice the clock rate to run the
program in 6 seconds.
Q6.(a) In communicating with the memory system, the CPU must supply three types of
information, state them.
34
56
78
03
Big-endian ordering of hex value 12345678
With Little-Endian byte ordering the least significant byte of the data item would be stored at the
lowest address and the most significant byte would be stored at the highest address:
78
1
56
34
12
03