29.10.2014 Views

ARM Compiler toolchain v4.1 for µVision Using the Compiler

ARM Compiler toolchain v4.1 for µVision Using the Compiler

ARM Compiler toolchain v4.1 for µVision Using the Compiler

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Getting started with <strong>the</strong> <strong>Compiler</strong><br />

3.19 Minimizing compilation build time with a single armcc invocation<br />

The following type of script incurs multiple loads and unloads of <strong>the</strong> compiler and multiple<br />

license checkouts:<br />

armcc file1.c ...<br />

armcc file2.c ...<br />

armcc file3.c ...<br />

Instead, you can try modifying your script to compile multiple files within a single invocation<br />

of armcc. For example, armcc file1.c file2.c file3.c ...<br />

For convenience, you can also list all your .c files in a single via file invoked with armcc -via<br />

sources.txt.<br />

Although this mechanism can dramatically reduce license checkouts and loading and unloading<br />

of <strong>the</strong> compiler to give significant improvements in build time, <strong>the</strong> following limitations apply:<br />

• All files are compiled with <strong>the</strong> same options.<br />

• Converting existing build systems could be difficult.<br />

• Usability depends on source file structure and dependencies.<br />

• An IDE might be unable to report which file had compilation errors.<br />

• After detecting an error, <strong>the</strong> compiler does not compile subsequent files.<br />

• Compiling <strong>the</strong>se files at optimization level -O3 enables multifile compilation, which<br />

might increase build times. Use --no_multifile to disable multifile compilation.<br />

3.19.1 See also<br />

Tasks<br />

• How to minimize compilation build time on page 3-26.<br />

Concepts<br />

Introducing <strong>the</strong> <strong>ARM</strong> <strong>Compiler</strong> <strong>toolchain</strong>:<br />

• Licensed features of <strong>the</strong> <strong>toolchain</strong> on page 2-8<br />

Reference<br />

<strong>Compiler</strong> Reference:<br />

• --multifile, --no_multifile on page 3-67<br />

• -Onum on page 3-71<br />

• --via=filename on page 3-95.<br />

<strong>ARM</strong> DUI 0375C Copyright © 2007-2008, 2011 <strong>ARM</strong>. All rights reserved. 3-28<br />

ID061811<br />

Non-Confidential

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!