Enumerating operand choices in a datapath
Datapath & Control Unit

Answer & solution
Official answer: A, B, C
Approach: Enumerate independent multiplexer settings instead of assuming the instruction formats of a familiar processor.
Selecting RA at Mux_A and RB at Mux_B gives two register operands, so A is supported. Selecting RA and the B-side immediate, or the A-side immediate and RB, gives one register and one immediate; B is supported. Selecting the immediate input at both multiplexers gives two immediate operands, so C is supported as well.
All selected values are 32 bits and can be delivered simultaneously to the ALU, whose result goes to RZ. No data connection in the shown partial datapath forces a mux to choose a register merely because the other mux chose an immediate.
Thus select A,B,C. D is false because its word “only” excludes the other two combinations. This is a claim about the available datapath connections, not proof that a particular instruction-set encoding actually exposes every such combination.




![Question 80, GATE 2005: Single-bus CPU: MAR, MDR, IR, PC, general registers and ALU input latches S, T share the bus; ALU output returns directly to it. All widths equal; increments must use ALU. Memory read takes two cycles: address→MAR then memory→MDR. Two-word CALL Rn, sub: opcode fetch already increments PC to second word. Execute Rn←PC+1 and PC←M[PC]. Minimum execution cycles A2; B3; C4; D5.](../../../assets/questions/CS-2005-Q80-1.webp)
![Question 80, GATE 2005: Single-bus CPU: MAR, MDR, IR, PC, general registers and ALU input latches S, T share the bus; ALU output returns directly to it. All widths equal; increments must use ALU. Memory read takes two cycles: address→MAR then memory→MDR. Two-word CALL Rn, sub: opcode fetch already increments PC to second word. Execute Rn←PC+1 and PC←M[PC]. Minimum execution cycles A2; B3; C4; D5.](../../../assets/questions/CS-2005-Q80-2.webp)
![Question 80, GATE 2005: Single-bus CPU: MAR, MDR, IR, PC, general registers and ALU input latches S, T share the bus; ALU output returns directly to it. All widths equal; increments must use ALU. Memory read takes two cycles: address→MAR then memory→MDR. Two-word CALL Rn, sub: opcode fetch already increments PC to second word. Execute Rn←PC+1 and PC←M[PC]. Minimum execution cycles A2; B3; C4; D5.](../../../assets/questions/CS-2005-Q80-3.webp)


![Question 2.13, GATE 2001: An unpipelined CPU has an 8-bit bus, ALU, general registers and MDR, but 16-bit SP and MAR. Byte-select mux/demux connect SP and MAR to the bus; memory operations take two cycles; SP can decrement locally. For push r, perform M[SP]←r then SP←SP−1. How many execution cycles: 2,3,4,5? The complete datapath is linked.](../../../assets/questions/CS-2001-Q38-1.webp)











