|
|
Instruction set
Unconditional jump
|
|
The relative branch commands calculate the address of the next instruction adding an instruction's parameter (called bias) to current value of program counter. So processor skips several instructions or returns over several ones.
Except conditional branches, MMIX has two special unconditional relative jump instructions. Command with code F0 goes forward (to greater address) using positive bias. Another command (F1) go backward and use negative bias.
The difference of jump commands in MMIX from branches, described before, is also in the length of displacement: branches use 16-bit bias (see format 3) but jumps contains 24-bit bias (format 4).
Examples:
- instruction JMP 000002 will skip 2 instructions; note that it means 4*2=8 byte!
(for example if branch instruction has address 100, next command will have address 100+4*2=108)
- JMPB FFFFFE - all the same as previous, but the displasement is negative: -2 instructions backward
(from 100 to F8)
Related topics:
"MMIX basics" page
|
(C) 2003, Evgeny Eremin. rEd-MMI project documentation
|
|