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

create a 'new root' in the c51 linker.

i'm attempting to opimise my xdata usage on an 8051 eWarp project.

i'm working with a large memory model.

when i view my linker file i see multiple new roots eg:

*** NEW ROOT ********************************

VPIPINTERRUPT_STATSISR/VPIPINTERRUPT ----- ----- ----- ----- ----- -----
+--> ?PR?FPALU_SAVECONTEXT?FPALU
+--> ?PR?EXPSTATSENGINEMANAGER_EXTRACTMEAN...
+--> ?PR?WBSTATSENGINEMANAGER_EXTRACTMEANS...
+--> ?PR?EXPOSURECONTROL_MAIN?EXPOSURECONTROL
+--> ?PR?_WHITEBALANCE_UPDATECONTROLS?WHIT...
+--> ?PR?INPUTPROCESSOR_CALCULATEALLCHANNE...
+--> ?PR?FPALU_RESTORECONTEXT?FPALU

*** NEW ROOT ********************************

VPIPINTERRUPT_SOF_EOF_ISR/VPIPINTERRUPT ----- ----- ----- ----- ----- -----
+--> ?PR?FPALU_SAVECONTEXT?FPALU
+--> ?PR?EXPSTATSENGINEMANAGER_SETUPEXPOSU...
+--> ?PR?WBSTATSENGINEMANAGER_SETUPWHITEBA...
+--> ?PR?INPUTPROCESSOR_SETUPALLCHANNELS?I...
+--> ?PR?_FLASHGUNMANAGER_SETGPIO?FLASHGUN...
+--> ?PR?_EXPOSURECONTROL_CALCULATETOTALIN...
+--> ?PR?_EXPSENSOR_GETANALOGGAINFROMCODED...
+--> ?PR?_EXPOSURECONTROL_UPDATECURRENTEXP...
+--> ?PR?_FLASHGUNMANAGER_CLEARGPIO?FLASHG...
+--> ?PR?FPALU_RESTORECONTEXT?FPALU

obviously the fns on different roots are not overlayed.

however since i know that my interrupts are running at the same priority could these call trees not be merged into one? this would give me a large saving in ram due to the increased overlaying which would occur.

is there a low level directive that can be used to force this to occur?
i realise that the overlay directive is a powerful tool for this kind of thing, but i can't see how i can make it do what i want.

can anybody help?

thanks,

robert

Parents
  • is there a low level directive that can be used to force this to occur?

    "OVERLAY", as you say.

    How about assigning all of the ISR functions to be "called" by just one of them? Perhaps a dummy top-level function with no auto usage?

    Each ISR priority is effectively a new context, needing a new root for the call tree, in addition to the main routine.

Reply
  • is there a low level directive that can be used to force this to occur?

    "OVERLAY", as you say.

    How about assigning all of the ISR functions to be "called" by just one of them? Perhaps a dummy top-level function with no auto usage?

    Each ISR priority is effectively a new context, needing a new root for the call tree, in addition to the main routine.

Children
No data