1,208 views
2 votes
2 votes
Adding a constant to the content of register

Is it

a)Immediate mode or b) Indexed mode?

1 Answer

Best answer
3 votes
3 votes
The question is very much incomplete. Informally, I would say it depends. If this addition (Adding a Reg content to a constant) leads to computation of "effective address or address", then that means the instruction uses Indexed AM . But if the addition(Adding a Reg content to a constant) is done to fetch/manipulate the Data then that would mean the instruction uses Immediate AM (for Constant).

Say, $ADD \,\,R \,\,30 \,\,\,\,|\,\,\, R\leftarrow R+30$  // Immidiate AM

$ADD \,\,R_0,R_1, \,\,3000 \,\,\,\,|\,\,\, R_0\leftarrow M\left [R_1+3000 \right ]$  // Indexed AM

So, these things are very much Context Dependent. Unless each required information is given, the answer can't be given precisely.

There are Questions in Previous GATE papers where Different learned people give different answers because the question isn't self-contained and thus, the answer depends on what interpretation GATE professors take outta it.
edited by

Related questions

0 votes
0 votes
1 answer
4
twin_123 asked Dec 12, 2018
608 views
Solution please