In devtools/gen-avr-lib-tree.sh we have
CFLAGS_BIG_MEMORY='-Os $(FNO_JUMP_TABLES)'
where FNO_JUMP_TABLES is resolved to -fno-jump-tables by configure.
CFLAGS_BIG_MEMORY is then used as build flags for cores and devices with
more than 64 KiB of program memory (i.e. with 3-byte PC i.e. that have
ELPM) with the exceptions of ATmega128RFR2 and ATmega1284RFR2.
Is there any benefit of still using that flag?
To all of my knowledge, -fno-jump-tables was used because avr-gcc
assumed that jump tables reside in the lower 64 KiB of flash (.progmem),
but that restriction was resolved with https://gcc.gnu.org/PR63223 which
applies to avr-gcc v4.9.2+.
PR63223 removes assumptions on the placement of jump tables altogether,
in particular there is no more the requirement that they reside in
.progmem. Jump tables are now placed in .jumptables which the linker
script locates after ordinary .text sections (even after .progmemx), and
the code in libgcc takes care of that by using the full address width
including RAMPZ as needed.
Johann