avr-gcc puts data for named address space __memx into section .progmemx. The current linker script has a catch-all .progmem* located at a lower address together with data that is expected to reside in the lower 64 KiB flash segment. This is not required for __memx data so that .progmemx. can be moved to a higher address, wasting less of the small addresses.
Created attachment 10290 [details] proposed patch ld/ PR ld/21849 * scripttempl/avr.sc: Split .progmemx.* from .progmem.* and locate former at a higher address.
The master branch has been updated by Nick Clifton <nickc@sourceware.org>: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=f726cc1cb69ab0e0303209d08effb10b99007080 commit f726cc1cb69ab0e0303209d08effb10b99007080 Author: Georg-Johann Lay <gjl@gcc.gnu.org> Date: Thu Jul 27 14:17:14 2017 +0100 Move AVR .promemx.* sections into higher memory. PR ld/21849 * scripttempl/avr.sc: Split .progmemx.* from .progmem.* and locate former at a higher address.
The binutils-2_29-branch branch has been updated by Nick Clifton <nickc@sourceware.org>: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=0e84dfccb213f1258dd29492653713d5b04a2431 commit 0e84dfccb213f1258dd29492653713d5b04a2431 Author: Georg-Johann Lay <gjl@gcc.gnu.org> Date: Thu Jul 27 14:20:50 2017 +0100 Move AVR .progmemx.* sections to higher memory. PR ld/21849 * scripttempl/avr.sc: Split .progmemx.* from .progmem.* and locate former at a higher address.
Patch approved and applied.