Currently, local static variables are always initialized by custom code in the gsinit section.
This is much more inefficient than the mechanisms used for initialized global variables many ports use (thexinit/xiseg and initialized/initializer sections).
static local variables should be handled like global ones in that respect, giving us more efficient initialization.
Philipp
Bugs: #3015
Feature Requests: #455
Wiki: SDCC 4.3.0 Release
Wiki: SDCC 4.4.0 Release
Wiki: SDCC 4.5.0 Release
As I know, local static variables must be initialized on first function execute. I understand, it is not efficient for constant initializators, so this case can be handled as global static initialization done.