IFc

IFc

Conditionally Execute a Group or Subgroup (PREFIX) IFc

Operation

Assembler Syntax

If T == 0,

then execute group/subgroup

IFF group or subgroup of instructions

 

else treat as NOP

 

If T == 1,

then execute group/subgroup

IFT group or subgroup of instructions

 

else treat as NOP

 

execute group/subgroup unconditionally

IFA group or subgroup of instructions

Description

These instructions add conditional control over a group or subgroup of instructions in a VLES.

IFF

Execute the group or subgroup if T is equal to zero (condition is false). If T is equal to one (condition is true), the group or subgroup is treated as a NOP. This instruction can be used in conjunction with IFT to form an if/else clause.

IFT

Execute the group or subgroup if T is equal to one (condition is true). If T is equal to zero (condition is false), the group or subgroup is treated as a NOP. This instruction can be used in conjunction with IFF to form an if/else clause.

IFA

Always execute the group or subgroup. This instruction may be used in conjunction with IFT or IFF to split a VLES group into conditional and unconditional subgroups, where IFA must be the last subgroup in the VLES.

The following combinations of these instructions can be used:

IFT

group

 

 

; execute group if T is set

IFF

group

 

 

; execute group if T is clear

IFA

group

 

 

; execute group unconditionally

IFT

subgroup1

IFA

subgroup2

; execute subgroup1 if T is set,

 

 

 

 

; execute subgroup2 unconditionally

IFF

subgroup1

IFA

subgroup2

; execute subgroup1 if T is clear,

 

 

 

 

; execute subgroup2 unconditionally

IFT

subgroup1

IFF

subgroup2

; execute subgroup1 if T is set,

 

 

 

 

; execute subgroup2 if T is clear

Notes: 1. The instructions in the subgroups can be conditional (e.g., TFRT, JF), which adds finer control.

2.The “IFA group” is the same as not using IFc. That is, unconditional execution of the VLES.

3.The detailed use of IFc is defined by Section 7.2, “VLES Grouping Semantics,” and programming rule G.P.7 in Section 7.5.3, “Prefix Grouping Rules.”

A-176

SC140 DSP Core Reference Manual

Page 490
Image 490
Freescale Semiconductor SC140 Conditionally Execute a Group or Subgroup Prefix IFc, If T == Then execute group/subgroup