09.12.2012 Views

Cortex-A8 Technical Reference Manual - ARM Information Center

Cortex-A8 Technical Reference Manual - ARM Information Center

Cortex-A8 Technical Reference Manual - ARM Information Center

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Instruction<br />

type<br />

Arithmetic CDP<br />

Non-arithmetic<br />

CDP<br />

NEON and VFP Programmers Model<br />

exception. For the non-arithmetic CDP instructions, FABS, FNEG, and FCPY, NaNs are<br />

copied, with a change of sign if specified in the instructions, without causing the Invalid<br />

Operation exception.<br />

• In default NaN mode, NaNs are handled completely within the hardware. SNaNs in an<br />

arithmetic CDP operation set the IOC flag, FPSCR[0], to 1. NaN handling by data transfer<br />

and non-arithmetic CDP instructions is the same as in full-compliance mode. Arithmetic<br />

CDP instructions involving NaN operands return the default NaN regardless of the<br />

fractions of any NaN operands.<br />

Table 13-14 summarizes the effects of NaN operands on instruction execution.<br />

Default<br />

NaN<br />

mode<br />

Comparisons<br />

Comparison results modify condition code flags in the FPSCR Register. The FMSTAT<br />

instruction transfers the current condition code flags in the FPSCR Register to the CPSR<br />

Register. See the <strong>ARM</strong> Architecture <strong>Reference</strong> <strong>Manual</strong> for more information. The condition<br />

code flags used are chosen so that subsequent conditional execution of <strong>ARM</strong> instructions can<br />

test the predicates defined in the IEEE 754 standard.<br />

The VFP coprocessor handles all comparisons of numeric and reserved values in hardware,<br />

generating the appropriate condition code depending on whether the result is less than, equal to,<br />

or greater than.<br />

The VFP coprocessor supports:<br />

Table 13-14 QNaN and SNaN handling<br />

With QNaN operand With SNaN operand<br />

Off The QNaN or one of the QNaN operands, if<br />

there is more than one, is returned<br />

according to the rules given in the <strong>ARM</strong><br />

Architecture <strong>Reference</strong> <strong>Manual</strong>.<br />

IOC a set to 1. The SNaN is quieted and the<br />

result NaN is determined by the rules given<br />

in the <strong>ARM</strong> Architecture <strong>Reference</strong><br />

<strong>Manual</strong>.<br />

On Default NaN returns. IOC set to 1. Default NaN returns.<br />

Off<br />

On<br />

NaN passes to destination with sign changed as appropriate.<br />

FCMP(Z) - Unordered compare. IOC set to 1. Unordered compare.<br />

FCMPE(Z) - IOC set to 1. Unordered compare. IOC set to 1. Unordered compare.<br />

Load/store<br />

Off<br />

On<br />

a. IOC is the Invalid Operation exception flag, FPSCR[0].<br />

All NaNs transferred.<br />

Compare operations<br />

The compare operations are FCMPS, FCMPZS, FCMPD, and FCMPZD.<br />

A compare instruction involving a QNaN produces an unordered result. An SNaN<br />

produces an unordered result and generates an Invalid Operation exception.<br />

Compare with exception operations<br />

The compare with exception operations are FCMPES, FCMPEZS, FCMPED, and FCMPEZD.<br />

<strong>ARM</strong> DDI 0344K Copyright © 2006-2010 <strong>ARM</strong> Limited. All rights reserved. 13-18<br />

ID060510 Non-Confidential

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!