I know that it might be similar to any other R type instruction, but it’s not shown anywhere.
Probably not shown anywhere because all R-Type instructions share the same datapath.
XOR is an R-Type instruction — there is no difference with other R-Type instructions on datapath.
What do all R-Type instructions do for datapath? They fetch values from the register file based on
rt register numbers in those respective fields in the instruction, and forward those values to the ALU. They take the ALU output and redirect that back to the registers to write that result to the
rd register number. (And they instruct the processor to increment the program counter for sequential execution.)
There is single control signal (i.e. not datapath) difference that the
ALU Control outputs a value that tells the ALU to do the
XOR operation instead of some other ALU operation, like
or. The ALU Control realizes that the ALUOp (signal from main Control) merely indicates R-Type instruction and thus the ALU Control decodes the
func field instruction bits into that indicator to the ALU to do
The selection of the control signal value is generally not shown (diagrammed), but rather the values are usually found in some table that augments the datapath & control signal diagram.
CLICK HERE to find out more related problems solutions.