On 28.03.2013 23:42, Masur Jonathan wrote:
> Ok,
> therefore using automatic bankswitching should be done with caution, as 
> it could potentially result in a ridiculous number of unnecessary BBR 
> writes - say if I access a lot of variables in bankswitched area and 
> call functions that doesn't touch BBR.

Well, we could do the following:

Have a syntax for annotating function declarations with information on
which bank will be active at function return (or at least make it
possible to specify that the function doesn't change the active bank).
This could then be used for all the functions in the standard library.
And the information could be deduced automatically for functions in the
same .c file that have been seen before by the compiler.

I thought about having something like this for registers before: When
the compiler knows that calling f() doesn't overwrite register de, we
know that it doesn't have to be saved over the call.

I'll open feature requests for these, so they won't be forgotten.

Philipp

------------------------------------------------------------------------------
Own the Future-Intel(R) Level Up Game Demo Contest 2013
Rise to greatness in Intel's independent game demo contest. Compete 
for recognition, cash, and the chance to get your game on Steam. 
$5K grand prize plus 10 genre and skill prizes. Submit your demo 
by 6/6/13. http://altfarm.mediaplex.com/ad/ck/12124-176961-30367-2
_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user

Reply via email to