Texas Instruments TMS320C28x Reference Manual page 525

Dsp cpu and instruction set
Table of Contents

Advertisement

XB *AL
XB *AL
SYNTAX OPTIONS
XB *AL
Operands
*AL
Description
Flags and
Modes
Repeat
Example
; Branch to subroutines in SwitchTable selected by Switch
; value.
; This example only works for code located
; program space:
SwitchTable:
.word
.word
MOVL
MOVZ
MOV
XB
SwitchReturn:
Switch0:
XB
Switch1:
XB
6-368
Indirect program-memory addressing using register AL, can only access
high 64K of program space range (0x3F0000 to 0x3FFFFF)
Unconditional indirect branch by loading the low 16 bits of PC with the
contents of register AL and forcing the upper 6 bits of the PC to 0x3F:
PC = 0x3F:AL;
Note:
This branch instruction can only branch to a location located in the upper 64K range of
program space (0x3F0000 to 0x3FFFFF).
None
This instruction is not repeatable. If this instruction follows the RPT
instruction, it resets the repeat counter (RPTC) and executes only once.
Switch0
Switch1
.
.
XAR2,#SwitchTable
AR0,@Switch
AL,*+XAR2[AR0]
*AL
.
.
.
SwitchReturn,UNC
.
.
SwitchReturn,UNC
C2 xLP Source-Compatible Indirect Branch
OPCODE
0101 0110 0001 0100
; Switch address table:
; Switch0 address
; Switch1 address
; XAR2 = pointer to SwitchTable
; AR0
= Switch index
; AL = SwitchTable[Switch]
; Indirect branch using AL
; Subroutine 0:
; Return: branch
; Subroutine 1:
; Return: branch
OBJMODE
RPT
1
in upper 64K of
CYC
7

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the TMS320C28x and is the answer not in the manual?

Subscribe to Our Youtube Channel

Table of Contents

Save PDF