In: Computer Science
1. The goal of scalar processing is to produce, on average, the execution of one instruction per clock tick.
• If the clock ticks at a rate of 2 GHz, how many instructions per second can this computer execute?
• How many instructions would a 2 GHz superscalar processor that processes three instructions per clock cycle execute?
2. Suppose we are trying to determine the speed of a
computer that executes the Little Man instruction set. The LOAD and
STORE instructions each make up about 25% of the instructions in a
typical program; ADD, SUBTRACT, IN, and OUT take 10% each. The
various branches each take about 5%. The HALT instruction is almost
never used (a maximum of once each program, of course!). Determine
the average number of instructions executed each second if the
clock ticks at 100 MHz.
3. Now suppose that the CPU is pipelined, so that
each instruction is fetched while another instruction is executing.
(You may also neglect the time required to refill the pipeline
during branches and at the start of program execution.) What is the
average number of instructions that can be executed each second
with the same clock in this case?
1)
It is given that If the clock ticks at a rate of 2 GHz.
In this representation, Giga represents a billion as a
number.
So that 1GHz clock ticks = 1 billion ticks per second.
2 GHz clock ticks = 2 billion ticksper second.
It is given that 2 GHz superscalar processor processes three
instructions per clock cycle.
It means that the processor is three times faster than
regular.
So that in one clock cycle, the processor can execute(3*2 billion)
6 billion instructions.
2) Give types of instruction sets are :
LOAD and STORE each makeup about 25% of the instructions
ADD, SUBTRACT, IN, and OUT take 10% each
various branches each take about 5%
As per Little Man instruction set, below instruction sets required number f cycles as follows:
LOAD = 5 Cycles
STORE= 5 Cycles
ADD = 5 Cycles
Subtract = 5 Cycles
IN = 4 Cycles
OUT = 4 Cycles
BRANCHES types are: SKIP = 4 Cycles and JUMP = 3 cycles.
Now, Number of cycles per instruction = 25/100(5+5) +
10/100(5+5+4+4) + 5/100(4+3)
= 0.25(10) + 0.10(18) + 0.05(7)
= 2.5 + 1.8 + 0.35
= 4.65
Bumber of instructions executed each second = 100*106/
4.65
= 21.5*106