9.124 __qdbl intrinsic

This intrinsic inserts instructions equivalent to the saturating addition of an integer with itself into the instruction stream generated by the compiler. It enables you to obtain the saturating double of an integer from within your C or C++ code.

Syntax

int __qdbl(int val)
Where:
val
is the data value to be doubled.

Return value

The __qdbl intrinsic returns the saturating add of val with itself, or equivalently, __qadd(val, val).

Errors

The compiler does not recognize the __qdbl intrinsic when compiling for a target that does not support the QADD instruction. The compiler generates either a warning or an error in this case, depending on the source language:
  • In C code: Warning: #223-D: function "__qdbl" declared implicitly.
  • In C++ code: Error: #20: identifier "__qdbl" is undefined.
Related reference
9.123 __qadd intrinsic
9.125 __qsub intrinsic
Non-ConfidentialPDF file icon PDF versionARM DUI0375F
Copyright © 2007, 2008, 2011, 2012, 2014 ARM. All rights reserved.