This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

a problem in using overlayable variables

I have a project which include a source file sub.c. In Sub.c I wrote a lot of subroutines independently with each other. In each subroutin I define several local variables. The variables in these subroutines should be overlayable between different subroutines. But it is not like that. The linker always declares error when the summary of variables in all these subroutines is too large. It seems the variables are not overlayable. But in .lst file, the variables are overlayable.
Pls analyse that for me. Thanks

Parents
  • Though the linker overlays local variables to maximize usage of available space, this does not give you infinite storage; you can still exceed available resources.

    Try relocating some of your less often-used variables to idata or xdata (if available on your target), or analyze your list and m51 files to see where you might be able to optimize your memory usage.

Reply
  • Though the linker overlays local variables to maximize usage of available space, this does not give you infinite storage; you can still exceed available resources.

    Try relocating some of your less often-used variables to idata or xdata (if available on your target), or analyze your list and m51 files to see where you might be able to optimize your memory usage.

Children