The linker automatically links in the Thumb C library if it
detects that one or more of the objects to be linked have been built
for:
16-bit Thumb
or 32-bit Thumb, either using the --thumb option
or #pragma thumb
interworking, using the --apcs /interwork option
on architecture ARMv4T
an ARMv6-M architecture target or processor, for
example, Cortex-M1 or Cortex-M0
an ARMv7-M architecture target or processor, for
example, Cortex-M3.
Despite its name, the Thumb C library might not contain exclusively
Thumb code. If ARM instructions are available, the Thumb library
might use them to improve the performance of critical functions
such as memcpy(), memset(),
and memclr(). The bulk of the Thumb C library, however,
is coded in Thumb for the best code density.
For an ARM instruction-only build, compile with the --arm_only option.
Note
The Thumb C library used for
ARMv6-M targets contains only 16-bit Thumb code.
The Thumb C library used for ARMv7-M targets contains
only 16-bit and 32-bit Thumb code.
This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.
ARM websites use two types of cookie: (1) those that enable the site to function and perform as required; and (2) analytical cookies which anonymously track visitors only while using the site. If you are not happy with this use of these cookies please review our Privacy Policy to learn how they can be disabled. By disabling cookies some features of the site will not work.