5 ms·
Either: "jal lr, dest" or "jalr lr, offset(reg)" Both save the address of the next instruction in lr, the first is a relative branch the second is to the addre
by Taniwha 3y ago
Either: "jal lr, dest" or "jalr lr, offset(reg)"
Both save the address of the next instruction in lr, the first is a relative branch the second is to the address pointed by a register plus an offset
Use "jalr r0, 0(lr)" to return
Anything else is just syntactic sugar in the assembler to set up the reg for jalr