4.1.5. Linker generated veneers

Veneers are small code segments that are automatically inserted by the linker if a branch involves:

The veneer becomes the target of the original branch, that then branches to the target address.

The linker can reuse a veneer generated for a previous call for subsequent calls to the same function, provided they can be reached from both sections.

For more details on interworking with veneers, see:

Types of veneer

Veneers can be:


Can have an optional state change.


Performs only a state change.


Performs only a state change, but is added to the start of the function that is being veneered.

Veneer$$Code sections

The linker creates one input section called Veneer$$Code for each veneer. You can place veneer code in a scatter-loading description file using *(Veneer$$Code). However, the linker only places veneer code there if it safe to do so.

It might not be possible for a veneer input section to be assigned to the region because of problems with address range or limitations on the size of execution regions. If the veneer cannot be added to the specified region, it is added to the execution region containing the relocated input section that generated the veneer.

See RealView Compilation Tools v3.0 Linker and Utilities Guide for more details.

Minimizing the use of veneers

You can minimize the use of veneers by:

  • structuring the memory map to keep called functions within range of the caller

  • encouraging sharing of veneers by keeping calling functions within range

  • minimizing state changes.

Copyright © 2002-2006 ARM Limited. All rights reserved.ARM DUI 0203G