Follow-up Comment #8, patch #6352 (project avr-libc): > They don't use the ELPM instruction rather, incorrectly, > the LPM instruction.
The very problem is that AVR with > 64k flash is a segmented architecture and it's not easy to handle them correctly. For example, ELPM Z+ might change RAMPZ so that this instruction is not of much use. The root problem is the ABI and that it does not disallow crossing section boundaries, i.e. 64k boundaries. No data must cross such boundaries and if ELPM Z+ shall be used to get efficient code (users like small/fast/low-ISR-overhead code) the last byte of each segment must be kept free. Any other approach will lead to very inefficent code and/or strage artifacts. The alternative is to take away RAMPZ from the compiler altogether and let the user set it appropriately, but the fact that crossing section boundaries does not work smooth won't go away with it, either. _______________________________________________________ Reply to this item at: <http://savannah.nongnu.org/patch/?6352> _______________________________________________ Nachricht geschickt von/durch Savannah http://savannah.nongnu.org/ _______________________________________________ AVR-libc-dev mailing list AVR-libc-dev@nongnu.org https://lists.nongnu.org/mailman/listinfo/avr-libc-dev