GATE / CS ARCHIVE

GATE CSE 2026 SET 1 / QUESTION 14

Matching addressing modes to data

Computer Organization & Architecture · Instructions & Addressing Modes · Full GATE CSE 2026 Set 1 paper

GATE 2026 Set 1, Q14 1 mark · MCQ
Report issue

Instructions & Addressing Modes

Question 14, GATE 2026: Match P immediate, Q indirect, R base with index, S base with offset to 1 array element, 2 pointer, 3 record field, 4 constant. The choices give different permutations of these matches.
Tap to enlarge
Your answer
Answer & solution

Official answer: B

Givens and goal

Match P immediate, Q indirect, R base with index, S base with offset to 1 array element, 2 pointer, 3 record field, 4 constant. The choices give different permutations of these matches.

Approach

Write the effective operand or effective address for each addressing mode and identify the high-level data access it implements.

Step-by-step solution

1. Immediate addressing puts the operand value directly in the instruction, such as an encoded literal 7. It naturally represents a constant, so P→4.
2. Indirect addressing obtains an operand’s address through another location or register. A pointer holds an address and is dereferenced to find the actual data, so Q→2.
3. Base-plus-index addressing computes an address from an array base and an index-dependent displacement, conceptually base+i·element_size. Varying i chooses an array element, so R→1.
4. Base-plus-fixed-offset addressing selects a field at a fixed byte displacement from the start of a record, such as record_base+offset_of_field. Thus S→3.
5. The complete mapping is (P,Q,R,S)→(4,2,1,3), option B. The key distinction is a varying index for array positions versus a fixed layout displacement for a named record field; both may ultimately use addition in the hardware.

Original paper, page 11 · Answer key