Jump to content
Sign in to follow this  
djulien

Need A Way To Force Functions Into Specific Page

Recommended Posts

When a program spans pages, for optimal performance functions must be carefully distributed between code pages to avoid excessive page selects. Currently, a given function can be forced to a specific address using "@<address>", but when there are many functions this is tedious because it takes many repeated compiles and checking the .map file each time in order to choose the correct address.

 

It would be very helpful to be able to tell the linker "put all code after this point into page ###". This would allow the code to be partitioned according to page# a lot easier. For example, allow a statement such as:

#pragma location push <address>

to be placed between functions to tell the linker to put the code after that into the designated page, and something like:

#pragma location pop

to tell it to put the code back into whichever page it was using before that.

 

(This would be somewhat analogous to the psect statement in MPLINK).

 

don

Edited by djulien

Share this post


Link to post
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...