Joerg Wunsch schrieb:
As Georg-Johann Lay wrote:
If that static is not function-static, then __flash can be used:
Thanks for that, Johann.
I tried to come up with a __flash-based implementation myself,
but didn't get it to work.
Maybe your "recipe" would be worth an entry into the avr-libc FAQ?
Dunno if that's actually specified or just works by accident. What's
really strange is that it doesn't work for locals, and there is no
technical reason for that.
Maybe it had just been overlooked when ASes were added to gcc, as the
first AS targets didn't go as far as avr (iirc they didn't even need
statics as it was all about using specific instructions for
FWIF there's also a mention at
AVR-libc-dev mailing list