in CO and Architecture edited by
3,717 views
3 votes
3 votes
consider an instruction of indirect addressing mode. what are the number of memory references by the processor when an instruction is a computation that requires a single operand and when it is a branch instruction respectively??

According to me, the answer should be 3,3 because in both of them one memory reference will be for instruction and two memory references for operand fetch as it is indirect.

But the solution says 3,2.

can someone check??
in CO and Architecture edited by
3.7k views

1 comment

Not getting it? Need a better explanation if anyone could?
0
0

1 Answer

4 votes
4 votes
Best answer
When computation instruction-

1 memory reference for instruction

1 memory reference for operand address

1 memory reference for operand fetch

so total 3

when branch instruction

1 memory reference for instruction

1 memory reference for operand address and this address will be given to PC

so total 2

Here we do not require 1 more reference because it will be the intsruction fetch which will be refered by the PC only we just need the address of Instruction so that we can update PC  and then PC will go to that location for Instruction fetch
selected by

3 Comments

Thanx. Understood the answer. I was thinking in a silly manner. thanx again :-)
0
0
edited by
1 memory reference for operand address and this address will be given to PC

What is this reference for?To  get the target address?If yes,then can target adress be fetched directly in indirect addressing mode?
0
0
@ sushmita i  cannot understand it what you wanted to say  JMP A  suppose it is an indirect mode  so first  go  to  A den from A go to address inside it suppose B from B go to address inside it suppose C which the address we have to jump SO PC is update to  C . HERE ADDRESS WILL ACT  AS OPERAND AND @Sanket u want to say that operand or instruction is at ADDRESS B
0
0