GCC Newspaper
OCTOBER 6, 2026
Date
/
Architectures
Components
Topics
News & Policy
Other
avr

Reduce unused libgcc modules for AVR target

Shrinks libgcc size for AVR by excluding unsupported or redundant modules.

This patch reduces the size of the libgcc library for the AVR target by excluding modules that handle unsupported data types or are superseded by AVR-specific implementations. This change significantly decreases the number of compiled modules, leading to smaller executables.

In Details

The AVR libgcc configuration (t-avr) is updated to exclude more modules from LIB2FUNCS_EXCLUDE. This includes modules for unsupported modes like [U]TQ, [U]TI, DF, and generic libgcc functions that have AVR-specific replacements. This optimization is applied across all 57 multilib variants, reducing the module count from over 1400 to under 1200.

For Context
libgcc
The GCC runtime library, containing support functions for various language features and operations that the compiler cannot directly generate machine code for.
AVR
A family of microcontrollers manufactured by Atmel (now Microchip Technology).
multilib
A technique used by compilers to generate multiple sets of libraries and object files that support different configurations (e.g., different CPU architectures, floating-point options) from a single source tree.
Filed Under: avrlibgccsize-optimization