Keeping modules
In this section:
If a module is linked as an object file, it is always kept. That is, it will contribute to the linked application. However, if a module is part of a library, it is included only if it is symbolically referred to from other parts of the application. This is true, even if the library module contains a root symbol. To assure that such a library module is always included, use iarchive to extract the module from the library, see The IAR Archive Tool—iarchive.
For information about included and excluded modules, inspect the log file (the command line option ‑‑log modules).
For more information about modules, see Modules and sections.