29.12.2014 Views

RealView Compilation Tools Compiler Reference Guide - ARM ...

RealView Compilation Tools Compiler Reference Guide - ARM ...

RealView Compilation Tools Compiler Reference Guide - ARM ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Compiler</strong>-specific Features<br />

Where:<br />

val<br />

is a double-precision floating-point value.<br />

Return value<br />

The __sqrt intrinsic returns the square root of val as a double.<br />

Errors<br />

The compiler does not recognize the __sqrt intrinsic when compiling for a target that is<br />

not equipped with a VFP coprocessor. The compiler generates either a warning or an<br />

error in this case.<br />

See also<br />

• __sqrtf<br />

• VABS, VNEG, and VSQRT on page 5-89 in the Assembler <strong>Guide</strong>.<br />

4.7.37 __sqrtf<br />

This intrinsic is a single-precision version of the __sqrtf intrinsic. It is functionally<br />

equivalent to __sqrt, except that:<br />

• it takes an argument of type float instead of an argument of type double<br />

• it returns a float value instead of a double value.<br />

See also<br />

• __sqrt on page 4-87<br />

• VABS, VNEG, and VSQRT on page 5-89 in the Assembler <strong>Guide</strong>.<br />

4.7.38 __ssat<br />

This intrinsic inserts an SSAT instruction into the instruction stream generated by the<br />

compiler. It enables you to saturate a signed value from within your C or C++ code.<br />

Syntax<br />

int __ssat(int val, unsigned int sat)<br />

Where:<br />

val<br />

sat<br />

Is the value to be saturated.<br />

Is the bit position to saturate to.<br />

4-88 Copyright © 2007, 2010 <strong>ARM</strong> Limited. All rights reserved. <strong>ARM</strong> DUI 0348A<br />

Non-Confidential

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

Saved successfully!

Ooh no, something went wrong!