REGISTERBANK

Abbreviation

RB

Arguments

A number between 0 and 3 enclosed in parentheses.

Default

REGISTERBANK (0)

Description

The REGISTERBANK directive selects which register bank to use for subsequent functions declared in the source file. Resulting code may use the absolute form of register access when the absolute register number can be computed. The using function attribute supersedes the effects of the REGISTERBANK directive.

NOTES

Unlike the using function attribute, the REGISTERBANK control does not switch the register bank.

Functions that return a value to the caller, must always use the same register bank as the caller. If the register banks are not the same, return values may be returned in registers of the wrong register bank.

The REGISTERBANK directive may appear more than once in a source program; however, it is ignored if used within a function declaration.

Example


#pragma rb(3)