Вы находитесь на странице: 1из 6

Student name: Ali Aburas Homework #1

Student Id: 800 CS474

Problem 1.1
Fetch Execut
Memory CPU Registers e
30 1005 300 PC Memory CPU Registers
0 30 1005 301 PC
30 5940 AC 0
1 30 5940 0003 AC
30 2006 1005 IR 1
2 30 2006 1005 IR
…. 2
… ….
94 0002 …
0 94 0002
0
I/O
devices I/O
5 0003 devices
6 5 0003
6

Fetch Execut
Memory CPU Registers e
30 1005 301 PC Memory CPU Registers
0 30 1005 302 PC
30 5940 0003 AC 0
1 30 5940 0005 AC
30 2006 5940 IR 1
2 30 2006 5940 IR
…. 2
… ….
94 0002 …
0 94 0002
0
I/O
devices I/O
5 0003 devices
6 5 0003
6

1
Student name: Ali Aburas Homework #1
Student Id: 800 CS474

Fetch Execut
Memory CPU Registers e
30 1005 302 PC Memory CPU Registers
0 30 1005 303 PC
30 5940 0003 AC 0
1 30 5940 0005 AC
30 2006 2006 IR 1
2 30 2006 2006 IR
…. 2
… ….
94 0002 …
0 94 0002
0
I/O
devices I/O
5 0003 devices
6 5 0003
6 0005

2
Student name: Ali Aburas Homework #1
Student Id: 800 CS474

Problem 1.8
The execution of instruction can be limited by memory cycle time,
therefore the processor will be slowed down, due to the DMA activity by
9600/8=1200 characters per scond, which is the time that DMA needs to
transfer a block of data into memory (word by word) before it sends as
interupt signal to the processor.

3
Student name: Ali Aburas Homework #1
Student Id: 800 CS474

Problem 1.9
a) As we assume that CPU executing “back ground” programs that requires
95% of its instructions execution rate. Therefore, I/O execution rate will be
5%.
If the 10^6 instructions which can the CPU executed, then the I/O
execution rate= 10^6 * 5 /100= 50,000 instructions ps.
For each one word I/O transfer, the CPU needs to execute two instructions.
Therefore,
The maximum I/O data transfer rate= 50,000/2=25,000 w/s.
b) Whenever, DMA starts to transfer data, it needs to take control of the bus,
and the CPU must wait for the DMA to complete its transfer.
Therefore, the rate for DMA transfer= 10^6 (5% *5+95% *2 )
= 10^6 (0.05 * 5+ 0.95 * 2)
= 10^6( 0.25 + 1.9)
= 10^6( 2.15)
= 2,150,000

4
Student name: Ali Aburas Homework #1
Student Id: 800 CS474

Problem 1.12
a) The cost of 1 Mbyte of main memory = Cm * word * 1 Mbyte
= 0.001 * 8 * 1048576

= 8388.608 cent

= $83.886

b) The cost of 1 Mbyte of main memory using cache technology

Cost = Cc * 8 * 1Mb

= 0.01 * 8 * 1048576

= $838.86
c) If the effective access time is 10% gt=rater than the cache access time.
1.1x Tc =Tc + (1-H) Tm

110 =100 + ( 1-H) x 1200

110 = 100 +1200 – 1200 H

1200 H= 1300 -110

H=1290/1200

H=99.2%

5
Student name: Ali Aburas Homework #1
Student Id: 800 CS474

Problem 1.13
As the computer has a cache, main memory and a disk used for virtual
memory, therefore, we have three cases that it might occurs whenever the
CPU fetches.

1. If the data in cache, the hit ratio is 0.9 , that lead to total time of
access= 20 ns.
2. If the data not in the cache but in the main memory. The hit ratio is
( 0.1) (0.6) =).)6, and the total time for access data is total time of
access memory + load it into cache= 60 + 20 = 80.
3. If the word is not in main memory or in the cache.
The hit ratio of each word in each fetch = 0.1 x 0.4 =0.04
And the total time =12 ms +80=12 x 10000 +80
= 1200080
Avg=(0.9) (20) + (0.06) 80 +(0.04)(12000080) =480,026 ns

Вам также может понравиться