The Gateway to Computer Science Excellence
+5 votes
664 views
A two- word instruction is stored in a location A. The operand part of instruction holds B. If the addressing mode is relative , the operand is available in location :

A. A+B+2

B.A+B+1

C.B+1

D.A+B

 

Explain with diagram.
in CO and Architecture by Active (1.7k points) | 664 views
0
A???
+3

Here we use concept of effective address.

EA = PC + operand part

after fetching instruction PC will be incremented by 2

Hence PC = A+2

operand part = B.

Hence effective address = A+B+2.

0
why we are adding operand???since when did this started to happen?? can you please make a diagram of this
0

@ashwina can you plzz verify the ans for this question?

1 Answer

+1 vote
Best answer
Since the addressing mode is relative therefore EA=A+PC where A is the address of current instruction being executed therefore during  execution of instruction A the pc contains A+2 as it is a 2 word instruction as soon as it gets location B then operand will available at A+B+2
by (145 points)
selected by

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
50,650 questions
56,242 answers
194,289 comments
95,941 users