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

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

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

Compiler-specific Features<br />

Errors<br />

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

does not support the LDREXD instruction. The compiler generates either a warning or an<br />

error in this case.<br />

The __ldrexd intrinsic only supports access to doubleword data. The compiler generates<br />

an error if you specify an access width that is not supported.<br />

See also<br />

• __ldrex on page 4-84<br />

• __strex on page 4-101<br />

• __strexd on page 4-102<br />

• LDREX and STREX on page 4-36 in the Assembler Guide.<br />

4.7.16 __ldrt<br />

This intrinsic inserts an assembly language instruction of the form LDR{size}T into the<br />

instruction stream generated by the compiler. It enables you to load data from memory<br />

in your C or C++ code using an LDRT instruction.<br />

Syntax<br />

unsigned int __ldrt(const volatile void *ptr)<br />

Where:<br />

ptr<br />

Points to the address of the data to be loaded frommemory. To specify the<br />

size of the data to be loaded, cast the parameter to an appropriate integral<br />

type.<br />

Table 4-10 Access widths supported by the __ldrt intrinsic<br />

Instruction a<br />

Size of data loaded<br />

C cast<br />

LDRSBT signed byte (signed char *)<br />

LDRBT unsigned byte (char *)<br />

LDRSHT signed halfword (signed short int *)<br />

LDRHT unsigned halfword (short int *)<br />

LDRT word (int *)<br />

a. Or equivalent.<br />

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

ID101213<br />

Non-Confidential,

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

Saved successfully!

Ooh no, something went wrong!