问题
In MIPS, a 32-bit jump instruction consists of 6-bits for the opcode and 26-bits for the target (destination) address that we want to set the program counter to.
However, it is possible to set the program counter to a 28-bit target address. How is this possible if we can only fit 26-bits in the jump instruction?
回答1:
Instructions on MIPS are always 4-byte aligned, so the low 2 bits of any valid target address can only be zero. Thus, the 26 bits specified in jump instructions are always implicitly left shifted of 2 positions, hence setting the low 28 bits of the PC.
来源:https://stackoverflow.com/questions/42219553/in-mips-why-can-a-jump-instruction-set-the-program-counter-to-a-28-bit-target-a