https://www.google.com/contributor/welcome/?utm_source=publisher&utm_medium=banner&utm_campaign=2376261057261409

Search This Blog

Search with our Site

Custom Search

Saturday, April 20, 2013

CS501: Advanced Computer Architecture Assignment No. 01 Semester: Spring 2013


Assignment No. 01
Semester: Spring 2013
CS501: Advanced Computer Architecture


Total Marks: 20
Due Date:  24-04-13

Instructions
Please read the following instructions carefully before assignment submission.


It should be clear that your assignment will not get any credit if:

§  The assignment is submitted after due date.
§  The submitted assignment does not open or file is corrupt.
§  The assignment is found to be copied from Internet.
§  The assignment is found to be copied from other student.
§  The assignment submitted is not according to required file format (.doc).


Objective
The objective of this assignment is:

§  To assess your overall understanding of Computer Architecture and Organization
§  To assess your overall understanding of Computer Instructions
§  To assess your overall understanding of Fetch, Decode and Execute Cycle



Note:

  • The assignment should be in .doc format.
  • Assignment .01 covers lectures from 1 to 5. You are required to watch first five cs501 video lectures as well as study them from handouts to attempt this assignment.  You can also consult reference books for help.
  • Students are advised to submit their assignment as early as possible in order to avoid any sort of inconvenience like Load shedding etc.

Assignment


Question:
Dear Student, you are given typical view of selected Memory and Processor registers in Figure 1. In memory, you can see three instruction codes in upper area, while two data values are given in lower part. These instruction codes represent an addition operation.
Addition Operation:  You are required to perform an addition operation in which you have to add the contents of memory word at address 781 to the contents of memory word at 782. After performing this addition, result should be stored at 782. Your task is to perform step-by-step execution of these three instructions and show registers configuration at each step.
For your understanding, Step-1 of this sequence of execution is shown in Figure 1.  In this Figure, you can see PC=200 which indicate that instruction stored at address 200 is in execution and the same instruction (1781) is loaded in IR register.

Memory

CPU register
200
1 7 8 1
200
PC
201
5 7 8 2

AC
202
2 7 8 2
1 7 8 1
IR
203



:

7 8 1
0 0 0 4

7 8 2
0 0 0 2
(STEP 1)






Figure-1
Where,
AC is Accumulator Register.
PC is Program Counter.
IR is Instruction Register.

Submission:
You need to complete execution of the three given instructions and provide step wise registers and memory configuration. Please submit your solution in MS Word format by completing/filling the provided steps on page-4.

Hint Regarding Three Instructions: 
·         First instruction 1781 means Load value stored at address 781 into accumulator register.
·         Second instruction 5782 means perform addition of value stored at address 781 with value in accumulator register and store the result in accumulator register.
·         Third instruction 2782 means store value of accumulator register at address 782.



















Answer:

Memory

CPU register
Memory

CPU register
200
1 7 8 1
PC
200
1 7 8 1

PC
201
5 7 8 2

AC
201
5 7 8 2

AC
202
2 7 8 2
IR
202
2 7 8 2

IR
203


203



:


:

7 8 1
0 0 0 4

7 8 1
0 0 0 4

7 8 2
0 0 0 2
(STEP 2)

7 8 2
0 0 0 2
(STEP 3)












Memory

CPU register
Memory

CPU register
200
1 7 8 1

PC
200
1 7 8 1

PC
201
5 7 8 2

AC
201
5 7 8 2

AC
202
2 7 8 2

IR
202
2 7 8 2

IR
203


203



:


:

7 8 1
0 0 0 4

7 8 1
0 0 0 4

7 8 2
0 0 0 2
(STEP 4)

7 8 2
0 0 0 2
(STEP 5)














Memory

CPU register
200
1 7 8 1
PC
201
5 7 8 2

AC
202
2 7 8 2
IR
203



:

7 8 1
0 0 0 4

7 8 2
0 0 0 2
(STEP 6)








GOOD LUCK!

No comments:

Post a Comment