Main Content

Target and Compiler

Target processor type, compiler behavior

To match your run-time environment, specify the target and compiler options. The analysis uses these options to determine variable sizes, language extensions and compiler-specific behavior. If you still get compilation errors, you can work around specific errors with options from the Macros and Environment Settings category.

Polyspace Options

expand all

Source code language (-lang)Specify language of source files
C standard version (-c-version)Specify C language standard followed in source code
C++ standard version (-cpp-version)Specify C++ language standard followed in source code

Required

Compiler (-compiler)Specify the compiler that you use to build your source code
Target processor type (-target)Specify size of data types and endianness by selecting a predefined target processor
Generic target optionsSpecify size of data types and endianness by creating your own target processor

Optional

Management of size_t (-size-t-type-is)Specify the underlying data type of size_t
Management of wchar_t (-wchar-t-type-is)Specify the underlying data type of wchar_t
Block char16/32_t types (-no-uliterals)Disable Polyspace definitions for char16_t or char32_t
Sfr type support (-sfr-types)Specify sizes of sfr types for code developed with Keil or IAR compilers
Pack alignment value (-pack-alignment-value)Specify default structure packing alignment for code developed in Visual C++
Ignore pragma pack directives (-ignore-pragma-pack)Ignore #pragma pack directives
Division round down (-div-round-down)Round down quotients from division or modulus of negative numbers instead of rounding up
Enum type definition (-enum-type-definition)Specify how to represent an enum with a base type
Signed right shift (-logical-signed-right-shift)Specify how to treat the sign bit for logical right shifts on signed variables

Topics

Getting Started

Emulating Your Compiler

Language Standards and Extensions