04.01.2015 Views

RealView Compilation Tools - ARM Information Center

RealView Compilation Tools - ARM Information Center

RealView Compilation Tools - ARM Information Center

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

Compiler-specific Features<br />

Return value<br />

The __clz intrinsic returns the number of leading zeros in val.<br />

See also<br />

• Other builtin functions on page 4-197<br />

• CLZ on page 4-54 in the Assembler Guide.<br />

4.7.5 __current_pc<br />

This intrinsic enables you to determine the current value of the program counter at the<br />

point in your program where the intrinsic is used.<br />

Syntax<br />

unsigned int __current_pc(void)<br />

Return value<br />

The __current_pc intrinsic returns the current value of the program counter at the point<br />

in the program where the intrinsic is used.<br />

See also<br />

• __current_sp<br />

• __return_address on page 4-95<br />

• Legacy inline assembler that accesses sp, lr, or pc on page 7-27 in the Compiler<br />

User Guide.<br />

4.7.6 __current_sp<br />

This intrinsic returns the value of the stack pointer at the current point in your program.<br />

Syntax<br />

unsigned int __current_sp(void)<br />

Return value<br />

The __current_sp intrinsic returns the current value of the stack pointer at the point in<br />

the program where the intrinsic is used.<br />

4-78 Copyright © 2007-2010 <strong>ARM</strong>. All rights reserved. <strong>ARM</strong> DUI 0348C<br />

Non-Confidential,<br />

ID101213

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

Saved successfully!

Ooh no, something went wrong!