ITC544: Assignment 2 - Memory, Instruction Sets, and Addressing Modes

Verified

Added on  2020/04/07

|3
|347
|43
Homework Assignment
AI Summary
This assignment solution for ITC544 delves into several key computer architecture concepts. Task 1 focuses on calculating the number of RAM chips required, demonstrating an understanding of memory organization and addressing. Task 2 addresses instruction set design, determining the number of bits needed for opcodes based on the number of operations. Task 3 explores different addressing modes (Immediate, Direct, Indirect, Indexed), explaining how the accumulator value changes in each mode. Finally, Task 4 compares instruction sequences for 2-address, 1-address, and 0-address machines, illustrating how different architectures handle arithmetic operations. The solution provides detailed calculations and explanations for each task, offering a comprehensive understanding of the underlying principles.
Document Page
Page 1 of 3
Assignment 2: MARIE & ISA
Student ID
Student Name
ITC544
tabler-icon-diamond-filled.svg

Paraphrase This Document

Need a fresh take? Get an instant paraphrase of this document with our AI Paraphraser
Document Page
Page 2 of 3
Task 1
a. RAM Chips required = (256M * 128) / (1024K * 32)
256M *128 = 28 * 220 * 27
= 28 + 20 +7 = 235
1024K * 32 = 210 * 210 * 25
= 210 + 10 + 5 = 225
Hence, RAM Chips required = 235 / 225 = 210 = 1024
b. RAM Chips per memory word = 256M / 1024K
= 228 / 220 = 28 = 256
c. Address bits required for each RAM Chip = 1024K
= 220 = 20 bits
d. Number of Banks = 256 = 28 = 8
e. Address bits required for all Memory = 256M = 228 = 28
Task 2
a. Instruction Set = 240 operations
Binary of 240 = 11110000
No. of bits required for the opcode = 8 bits
b. Since in the question registers are not mentioned therefore 0 bits are required to specify the
register.
Bits for Address = 48 – 8 = 40
Document Page
Page 3 of 3
c. Word = 48 bits
= 248 - 1
Task 3
Mode Actual value in AC (Accumulator) Explanation
Immediate 1500 Directly Loaded (1000 + 500)
Direct 1900 Value at Location address 1000 is 1400 &
AC is 500 so value = 1400 + 500
Indirect 1800
Value at Location address 1000 is 1400 &
Value at Location 1400 is 1300 plus
Value of AC (500) i.e. 1300 + 500
Indexed 1500
1000 + Value in R1 = 1000 + 200 = 1200
So value at 1200 = 1000 plus Value of
AC (500) i.e. 1000 + 500
Task 4
2-Address Machine 1-Address Machine 0-Address Machine
LOAD A, B LOAD D PUSH D
ADD A, C SUBTRACT E PUSH E
LOAD TEMP, D STORE TEMP SUBTRACT
SUBTRACT TEMP, E LOAD B PUSH C
MULTIPLY A,TEMP ADD C PUSH B
MULTIPLY TEMP ADD
STORE A MULTIPLY
STORE A
TEMP is temporary (memory location)
chevron_up_icon
1 out of 3
circle_padding
hide_on_mobile
zoom_out_icon
[object Object]