TASKING Compiler (-compiler tasking
)
Specify the Altium TASKING compiler
Description
Specify tasking
for Compiler
(-compiler)
if you compile your code using the Altium® TASKING compiler. By specifying your compiler, you can avoid compilation
errors from syntax that is not part of the Standard but comes from language
extensions.
Then, specify your target processor type. If you select tasking
for
Compiler, in the user interface of the Polyspace® desktop products, you see only the processors allowed for the TASKING
compiler. Your choice of target processor determines the size of fundamental data types,
the endianness of the target machine and certain keyword definitions.
If you specify the tasking
compiler, you must specify the
path to your compiler header files. See Provide Standard Library Headers for Polyspace Analysis.
The software supports different versions of the TASKING compiler, depending on the target:
TriCore: 6.x and older versions
C166: 4.x and older versions
ARM: 5.x and older versions
RH850: 2.x and older versions
Settings
The targets use the following default sizes in bits for the fundamental types. Unlike targets for other compilers, you do not see these sizes in the user interface.
Target | char | short | int | long | long long | float | double | long double | ptr | Default sign of char | Endianness | Alignment |
---|---|---|---|---|---|---|---|---|---|---|---|---|
tricore | 8 | 16 | 32 | 32 | 64 | 32 | 64 | 64 | 32 | signed | Little | 32 |
c166 | 8 | 16 | 16 | 32 | 64 | 32 | 64 | 64 | 32 | signed | Little | 16 |
rh850 | 8 | 16 | 32 | 32 | 64 | 32 | 64 | 64 | 32 | signed | Little | 64 |
arm | 8 | 16 | 32 | 32 | 64 | 32 | 64 | 64 | 32 | signed | Big | 64 |
For the TASKING compiler, the wchar_t
is not a
keyword. The headers <wchar.h>
or cwchar
can
provide typedef
for wchar_t
.
Your compiler specification also determines the values of many compiler-specific
macros. In case you want to know how Polyspace defines a specific macro, use the option -dump-preprocessing-info
.
To override the macro definition, use the option
Preprocessor definitions (-D)
.To undefine a macro, use the option
Disabled preprocessor definitions (-U)
.
Tips
Polyspace does not support some constructs specific to the TASKING compiler.
For the list of unsupported constructs, see
codeprover_limitations.pdf
in
. Here,polyspaceroot
\polyspace\verifier\code_prover_desktop
is the Polyspace installation folder, for instance,polyspaceroot
C:\Program Files\Polyspace\R2019a
.The CPU used is TC1793. If you use a different CPU, set the following analysis options in your project:
Disabled preprocessor definitions (-U)
: Undefine the macro__CPU_TC1793B__
.Preprocessor definitions (-D)
: Define the macro__CPU__
. Enter__CPU__=
, wherexxx
xxx
is the name of your CPU.Additionally, define the equivalent of the macro
__CPU_TC1793B__
for your CPU. For instance, enter__CPU_TC1793A__
.
Instead of manually specifying your compiler, if you trace your build command (makefile), Polyspace can detect your CPU and add the required definitions in your project.
For some errors related to TASKING compiler-specific constructs, see solutions in Fix Polyspace Compilation Errors Related to TASKING Compiler.
If you use Polyspace as You Code extensions in IDEs, enter this option in an analysis options file. See options file.
Command-Line Information
Parameter: -compiler
tasking -target |
Value: tricore |
c166 | rh850 | arm |
Default: tricore |
Example (Bug Finder): polyspace-bug-finder
-compiler tasking -target tricore |
Example (Code Prover): polyspace-code-prover
-compiler tasking -target tricore |
Example (Bug Finder Server):
polyspace-bug-finder-server -compiler tasking -target
tricore |
Example (Code Prover
Server):
polyspace-code-prover-server
-compiler tasking -target tricore |
Version History
Introduced in R2017a