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 />

MOV r2,#0x100<br />

LDRBT r0,[r2],#0<br />

ORR r0,r1,r0,LSL #8<br />

BX lr<br />

ENDP<br />

See also<br />

• --thumb on page 2-86<br />

• LDR and STR (User mode) on page 4-18 in the Assembler <strong>Guide</strong>.<br />

4.7.22 __memory_changed<br />

This intrinsic causes all variables that are visible outside the current function, such as<br />

variables that have pointers to them passed into or out of the function, to be written back<br />

to memory if they have been changed, and then to be read back from memory.<br />

This intrinsic also acts as a scheduling barrier.<br />

Syntax<br />

void __memory_changed(void)<br />

See also<br />

• __force_stores on page 4-74<br />

• __schedule_barrier on page 4-85.<br />

4.7.23 __nop<br />

This intrinsic inserts a NOP instruction or an equivalent code sequence into the<br />

instruction stream generated by the compiler. One NOP instruction is generated for each<br />

__nop intrinsic in the source.<br />

The compiler does not optimize-away the NOP instructions, except for normal<br />

unreachable-code elimination. The __nop intrinsic also acts as a barrier for instruction<br />

scheduling in the compiler. That is, instructions are not moved from one side of the NOP<br />

to the other as a result of optimization.<br />

Note<br />

You can use the __schedule_barrier intrinsic to insert a scheduling barrier without<br />

generating a NOP instruction.<br />

4-78 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!