MTESTTF CNDF
Test MSTF Register Flag Condition
Operands
CNDF
condition to test based on MSTF flags
Opcode
LSW: 0000 0000 0000 cndf
MSW: 0111 1111 0100 0000
Description
Test the CLA floating-point condition and if true, set the MSTF[TF] flag. If the condition is
false, clear the MSTF[TF] flag. This is useful for temporarily storing a condition for later
use.
if (CNDF == true) TF = 1;
else TF = 0;
CNDF is one of the following conditions:
Encode
CNDF
Description
MSTF Flags Tested
0000
NEQ
Not equal to zero
ZF == 0
0001
EQ
Equal to zero
ZF == 1
0010
GT
Greater than zero
ZF == 0 AND NF == 0
0011
GEQ
Greater than or equal
to zero
NF == 0
0100
LT
Less than zero
NF == 1
0101
LEQ
Less than or equal to
zero
ZF == 1 OR NF == 1
1010
TF
Test flag set
TF == 1
1011
NTF
Test flag not set
TF == 0
1100
LU
Latched underflow
LUF == 1
1101
LV
Latched overflow
LVF == 1
1110
UNC
Unconditional
None
1111
Unconditional with flag
modification
None
(1)
Values not shown are reserved.
(2)
This is the default operation if no CNDF field is specified. This condition will
allow the ZF and NF flags to be modified when a conditional operation is
executed. All other conditions will not modify these flags.
Flags
This instruction modifies the following flags in the MSTF register:
Flag
TF
ZF
NF
LUF
LVF
Modified
Yes
No
No
No
No
TF = 0;
if (CNDF == true) TF = 1;
Note: If (CNDF == UNC or UNCF), the TF flag will be set to 1.
Pipeline
This is a single-cycle instruction.
Control Law Accelerator (CLA)
702
TMS320x2806x Microcontrollers
SPRUH18I – JANUARY 2011 – REVISED JUNE 2022
Copyright © 2022 Texas Instruments Incorporated
Summary of Contents for TMS320 2806 Series
Page 2: ......