29.10.2014 Views

ARM Compiler toolchain v4.1 for µVision Using the Compiler

ARM Compiler toolchain v4.1 for µVision Using the Compiler

ARM Compiler toolchain v4.1 for µVision Using the Compiler

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.

<strong>Using</strong> <strong>the</strong> Inline and Embedded Assemblers of <strong>the</strong> <strong>ARM</strong> <strong>Compiler</strong><br />

7.44 __mcall_this_offset(D, f)<br />

Where D is a class type and f is a nonstatic member function defined in D or a nonvirtual base<br />

class of D.<br />

This returns <strong>the</strong> offset from <strong>the</strong> beginning of a D object to <strong>the</strong> start of <strong>the</strong> base in which f is<br />

defined. This is <strong>the</strong> this adjustment necessary when making a call to f with a pointer to a D. It<br />

is ei<strong>the</strong>r zero if f is found in D or <strong>the</strong> same as __offsetof_base(D,B), where B is a nonvirtual base<br />

class of D that contains f.<br />

If __mcall_this_offset(D,f) is used when f is found in a virtual base class of D it returns an<br />

arbitrary value designed to cause an assembly error if used. This is so that such invalid uses of<br />

__mcall_this_offset can occur in sections of assembly code that are to be skipped.<br />

7.44.1 See also<br />

Tasks<br />

• Calling a nonvirtual member function on page 7-54<br />

• Calling a virtual member function on page 7-55.<br />

Concepts<br />

• <strong>Compiler</strong>-supported keywords <strong>for</strong> calling class member functions in embedded assembler<br />

on page 7-47.<br />

<strong>ARM</strong> DUI 0375C Copyright © 2007-2008, 2011 <strong>ARM</strong>. All rights reserved. 7-51<br />

ID061811<br />

Non-Confidential

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

Saved successfully!

Ooh no, something went wrong!