13.07.2015 Views

TASKING VX-toolset for ARM User Guide

TASKING VX-toolset for ARM User Guide

TASKING VX-toolset for ARM User Guide

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Tool OptionsC compiler option: --cpu (-C)Menu entry1. Expand C/C++ Build and select Processor.2. From the Processor Selection list, make a selection by Architecture, Core or one of themanufacturers.Command line syntax--cpu=architecture-CarchitectureYou can specify the following architectures:<strong>ARM</strong>v6M<strong>ARM</strong>v7M<strong>ARM</strong>v7EM<strong>ARM</strong>v7RCompile <strong>for</strong> <strong>ARM</strong>v6-M architectureCompile <strong>for</strong> <strong>ARM</strong>v7-M architectureCompile <strong>for</strong> <strong>ARM</strong>v7E-M architectureCompile <strong>for</strong> <strong>ARM</strong>v7-R architectureDescriptionWith this option you specify the <strong>ARM</strong> architecture <strong>for</strong> which you create your application. The <strong>ARM</strong> targetsupports more than one architecture and there<strong>for</strong>e you need to specify <strong>for</strong> which architecture the compilershould compile. The architecture determines which instructions are valid and which are not.You choose one of the following architectures: <strong>ARM</strong>v6-M, <strong>ARM</strong>v7-M, <strong>ARM</strong>v7E-M or <strong>ARM</strong>v7-R. Thecompiler sets the Thumb instruction set implicitly (option --thumb).The macro __CPU_arch__ is defined in the C source file. The arch is converted to uppercase.When you call the compiler from the command line, make sure you specify the same core type to theassembler to avoid conflicts!ExampleTo compile the file test.c <strong>for</strong> the <strong>ARM</strong>v7E-M processor type, enter the following on the command line:carm --cpu=<strong>ARM</strong>v7EM test.cThe compiler compiles <strong>for</strong> the chosen processor type.Related in<strong>for</strong>mationControl program option --cpu (Select architecture)Assembler option --cpu (Select architecture)305

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

Saved successfully!

Ooh no, something went wrong!