Build project without the -mcpu option

The -mcpu selection may, in some scenarios, interfere with other toolchain options. For example, building certified libraries requires a specific compliant toolchain configuration. The newest device types may not be supported by a legacy compiler, even if the core architecture is.

In these cases, it possible to build the project without implicitly providing the target derivative specific option (-mcpu) on the command line.

You can set this option under the Global options of the Project  Properties  C/C++ Build  Settings  Tool Settings. When the Do not use -mcpu option on command line option is enabled, the IDE does not put the -mcpu option into the build command.

Note, bypassing the -mcpu option leads to a failed build or other unexpected results in general. It is up to the user to manually supply additional configuration data, such as core architecture (-mtc), based on its target goal.

ide no mcpu option
Fig. 1. Do not use -mcpu option settings

By default, the IDE sets the language provider based on the CPU type selection. When you enable the Do not use -mcpu option option, the IDE chooses the language provider according to the TriCore core architecture option (-mtc). This does not affect the build process or the product, but it may cause built-in toolchain symbols being incorrectly decorated in the source code editor if mismatched.

See the mapping table below.

Tab. 1. Language provider mapping table
Target derivative Derivative option TriCore core option TriCore version

TC21XX

-mcpu=tc21xx

-mtc161

TriCore v1.6.1

TC22XX

-mcpu=tc22xx

-mtc161

TriCore v1.6.1

TC23XX

-mcpu=tc23xx

-mtc161

TriCore v1.6.1

TC26XX

-mcpu=tc26xx

-mtc161

TriCore v1.6.1

TC27XX

-mcpu=tc27xx

-mtc161

TriCore v1.6.1

TC29XX

-mcpu=tc29xx

-mtc161

TriCore v1.6.1

TC33XX

-mcpu=tc33xx

-mtc162

TriCore v1.6.2

TC35XX

-mcpu=tc35xx

-mtc162

TriCore v1.6.2

TC36XX

-mcpu=tc36xx

-mtc162

TriCore v1.6.2

TC37XX

-mcpu=tc37xx

-mtc162

TriCore v1.6.2

TC32XX

-mcpu=tc32xx

-mtc162

TriCore v1.6.2

TC38XX

-mcpu=tc38xx

-mtc162

TriCore v1.6.2

TC39XX

-mcpu=tc39xx

-mtc162

TriCore v1.6.2