9.121 --tailreorder, --no_tailreorder

Moves tail calling sections immediately before their target, if possible, to optimize the branch instruction at the end of a section.


A tail calling section is a section that contains a branch instruction at the end of the section. The branch must have a relocation that targets a function at the start of a section.


The default is --no_tailreorder.


The linker:
  • Can only move one tail calling section for each tail call target. If there are multiple tail calls to a single section, the tail calling section with an identical section name is moved before the target. If no section name is found in the tail calling section that has a matching name, then the linker moves the first section it encounters.
  • Cannot move a tail calling section out of its execution region.
  • Does not move tail calling sections before inline veneers.
Related concepts
4.11 Linker reordering of tail calling sections
4.10 About branches that optimize to a NOP
Related reference
9.12 --branchnop, --no_branchnop
Non-ConfidentialPDF file icon PDF versionARM DUI0377G
Copyright © 2007, 2008, 2011, 2012, 2014, 2015 ARM. All rights reserved.