Call and immediate jump instructions on Nios II processors are limited to transferring control to addresses in the same 256MB memory segment, which may result in
relocation truncated to fit
’ errors with very large programs. The command-line option
enables the generation of trampolines that can access the entire 32-bit address space for calls outside the normal
address range. These trampolines are inserted at section boundaries, so may not themselves be reachable if an input section and its associated call trampolines are larger than 256MB.
option is enabled by default unless
is also specified. You can disable trampoline generation by using the
linker option. You can also disable this optimization locally by using the ‘
’ directive in assembly-language source files, as the linker-inserted trampolines use the
register as a temporary.
Note that the linker --relax option is independent of assembler relaxation options, and that using the GNU assembler's -relax-all option interferes with the linker's more selective call instruction relaxation.