
June 1997
179
ADVANCE DATA BOOK v2.0
FLOATING-POINT INSTRUCTION SET
CL-PS7500FE
System-on-a-Chip for Internet Appliance
WFS,RFS,WFC, and RFC
efgh
these bits are reserved and should be zero.
Constants
Constants cannot be specified in the Fm field for the FIX instruction, as there is no point FIXing a known
value into an ARM integer register; it would be quicker to use a MOV instruction.
19.3.1
Compare Operations
NOTE:
These are special cases of the general CPRT instruction, with Rd = 15 and L/S = 1.
<CMF|CNF|CMFE|CNFE>{cond} Fn, Fm
abc
i
efgh
operation
constant ROM/Fm (see
Section 19.2
)
are reserved and should be ‘0’
Compares
Compares are provided with and without the exception that could arise if the numbers are unordered.
When testing IEEE predicates, the CMF instruction should be used to test for equality (that is, when a
BEQ or BNE is used afterwards) or to test for unorderedness (in the V flag). The CMFE instruction should
be used for all other tests (BGT, BGE, BLT, and BLE afterwards). CMFE produces an exception if the num-
bers are unordered (whenever at least one operand is a NaN). CMF only produces an exception when at
least one operand is a signalling NaN.
The ARM flags N, Z, C, and V refer to
Table 19-4
after compares.
NOTE:
That when two numbers are not equal N and C are not necessarily opposites: if the result is unordered they
are both false.
31
28
27
24
23
22
21
20
19
16
15
12
11
8
7
4
3
0
cond
1110
abc
1
e Fn
1111
0001
fgh1
i Fm
abc
Mnemonic
Description
Operation
100
CMF
Compare floating
compare Fn with Fm
101
CNF
Compare negated floating
compare Fn with -Fm
110
CMFE
Compare floating with exception
compare Fn with Fm
111
CNFE
Compare negated floating with exception
compare Fn with -Fm
Table 19-4. Flag Settings When the AC Bit in the FPSR is Clear
Flag
Description
Example
N
Less Than
Fn less than Fm (or -Fm)
Z
Equal
C
Greater Than or Equal
Fn greater than or equal to Fm
V
Unordered