Chapter 7 Branch Instruction; Branch Instruction With Delay Slot; Operation Of Branch Instruction With Delay Slot - Fujitsu MB91460 SERIES FR60 User Manual

32-bit microcontroller
Table of Contents

Advertisement

Chapter 7
Branch Instruction
FR60 can instruct the operation with and without delay slot for branch instruction.

1. Branch Instruction with Delay Slot

• Branch instruction with delay slot
JMP:D @Ri
CALL:D label12
BRA:D label9
BNO:D label9
BC:D label9
BNC:D label9
BV:D label9
BNV:D label9
BLE:D label9
BGT:D label9

2. Operation of Branch Instruction with Delay Slot

Operation with delay slot executes the instruction located in the next address where a branch instruction exists
(referred to as delay slot) and then branches before executing branched instructions.
Since it executes delay slot instruction before branch operation, apparent execution rate becomes 1 cycle.
Instead, if delay slot has no valid instruction, NOP instruction must be entered.
• Example
;
Sequence of instruction
ADD
BRA:D
MOV
...
LABEL : ST
In conditional branch instruction, regardless of whether branch parameter is approved or not, instructions
located in delay slot are executed.
In delay branch instruction, execution sequence of some instructions seems opposite, however, it only applies
to updating process on the PC. Any other operation (register update/look-up) is executed in the order of
description.
CALL:D @Ri
BEQ:D label9
BN:D
label9
BLT:D label9
BLS:D label9
R1
R2
;
LABEL
; Branch instruction
R2
R3
; Delay slot ...... To be executed before the branch.
R3
@R4 ; Branched instruction
RET:D
BNE:D label9
BP:D label9
BGE:D label9
BHI:D label9

Chapter 7 Branch Instruction

1.Branch Instruction with Delay Slot
129

Advertisement

Table of Contents
loading

This manual is also suitable for:

Fr60Mb91460 series

Table of Contents