2.17.4 Effect of --multifile on compilation build time

When compiling with --multifile, the compiler might generate code with additional optimizations by compiling across several source files to produce a single object file. These additional cross-source optimizations can increase compilation time.

Conversely, if there is little additional optimization to apply, and only small amounts of code to check for possible optimizations, then using --multifile to generate a single object file instead of several might reduce compilation time as a result of time recovered from creating (opening and closing) multiple object files.


  • In RVCT 4.0, if you compile with -O3, --multifile is enabled by default.
  • In ARM Compiler 4.1 and later, --multifile is disabled by default, regardless of the optimization level.
Related concepts
2.17.1 Compilation build time
Related tasks
2.17.2 Minimizing compilation build time
Related reference
7.115 --multifile, --no_multifile
7.120 -Onum
Related information
Licensed features of ARM Compiler
Non-ConfidentialPDF file icon PDF versionARM DUI0375F
Copyright © 2007, 2008, 2011, 2012, 2014 ARM. All rights reserved.