edited by
3,308 views
1 votes
1 votes
Q. Consider an instruction of indirect addressing mode. what is the number of memory refrence  by the processor  when instruction is a computation  that require a single operand and when it is a branch Instruction respectivily ?/

Option A) 2 ,2

           B) 3,3

           C)3,2

          D) 2,3
edited by

2 Answers

Best answer
3 votes
3 votes

The options given are wrong actually ..Let us see why :

We know that one memory access is required to bring the instruction given that the instruction is a one word instruction and the memory is word addressable..

So in case of indirect addressing mode , we require one memory accesses to fetch instruction and 2 memory accesses to fetch the operand..So no of accesses required in indirect mode = 3

But in case of branch instruction , 

we need to fetch the instruction and after that the branch address is computed from the addition of PC content and address field of the instruction if it is a PC relative mode or else by adding the contents of base..But this is a direct addressing scheme..

In indirect (memory indirect) , one more memory access

Hence the correct answer should be 3 , 2 (3 for indirect mode and operand fetch case and 2 for branch indirect instruction case)..

Hence C) is the correct option..

selected by

Related questions

5 votes
5 votes
1 answer
3