4.5.3 Switch Statements
By default, jump tables are used to optimize switch()
statements. This can be made explicit by using the -fjump-tables
option.
The -fno-jump-tables
option prevents jump tables from being used and will
use sequences of compare sequences instead. Jump tables are usually faster to execute, but
for switch()
statements where most of the jumps are destined for the
default
label, they might produce excessive amounts of code.
Jump tables use the limited-range lpm
assembler
instruction. Always use the -fno-jump-tables
option when compiling a
bootloader for devices with more than 64 KB of program memory.