Keil Logo

BL51: FUNCTION POINTERS, CODE BANKING, AND NOOVERLAY


Information in this article applies to:

  • C51 Version 7.00

QUESTION

I'm creating a large code banking application with lots of pointers to functions. I must disable variable overlaying with the NOOVERLAY directive. However, I need to use the OVERLAY directive to show the linker the relationship between functions that call use pointers to call functions in other code banks. How can I do this?

ANSWER

The LX51 Linker and the BL51 Linker shipped with C51 Version 7 and later allow you to specify the OVERLAY and NOOVERLAY directives simultaneously. When both directives are used, the linker obtains function relationship references from the OVERLAY directive. When NOOVERLAY is specified as well, the linker no longer overlays function arguments and local variables.

On the linker command link, you must first specify the segment relationships using the OVERLAY directive. Then, specify the NOOVERLAY directive.

Note that this order is required only with LX51 Version 3.51 and earlier and BL51 Version 5.01 and earlier. If you use µVision2, you must create a linker response file to specify these directives in this order. Later versions of the linker allow these directives to be specified in any order.

MORE INFORMATION

  • Refer to OVERLAY in the LX51 User's Guide.
  • Refer to NOOVERLAY in the LX51 User's Guide.

FORUM THREADS

The following Discussion Forum threads may provide information related to this topic.

Last Reviewed: Friday, September 5, 2008


Did this article provide the answer you needed?
 
Yes
No
Not Sure
 
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.