Contenuto principale

La traduzione di questa pagina non è aggiornata. Fai clic qui per vedere l'ultima versione in inglese.

Analisi Bug Finder nell'interfaccia utente di Polyspace Platform

Controllare il codice C/C++ per individuare eventuali difetti nell'interfaccia utente di Polyspace® Platform

Polyspace Platform è un ambiente integrato che supporta l'analisi statica e il test dinamico del codice C/C++ con i prodotti di Polyspace. Nell'interfaccia utente di Polyspace Platform, è possibile creare un progetto, aggiungere file sorgente, configurare i checker ed eseguire un'analisi Bug Finder.

Opzioni Polyspace

espandi tutto

Informazioni di base

NomeSee name of Polyspace Platform project (Da R2024a)
AutoreSpecify author name for Polyspace Platform project (Da R2024a)
CreatoSee date and time when Polyspace Platform project was created (Da R2024a)
Ultima modificaSee date and time when Polyspace Platform project was last modified (Da R2024a)
Codifica codice sorgente (-sources-encoding)Specify the encoding of source files

File sorgente e cartelle include

Cartelle sorgente dell'applicazioneAdd source folders to Polyspace Platform project (Da R2024a)
File sorgente dell'applicazioneAdd source files to Polyspace Platform project (Da R2024a)
Percorsi includeSpecify paths to folders containing include files (Da R2023b)

Inclusioni ed esclusioni del file

Includere i pattern del nome del fileSpecify patterns for file names to be included in Polyspace Platform project (Da R2024a)
Percorsi excludeSpecify folders or files to be excluded from static analysis or testing (Da R2024a)

Variabili di ambiente

Variabili di progettoDefine environment variables for use as shorthands in Polyspace Platform project (Da R2024a)

Target e compiler

Linguaggio del codice sorgente (-lang)Specify language of source files
Versione standard C (-c-version)Specify C language standard followed in source code
Versione standard C++ (-cpp-version)Specify C++ language standard followed in source code
ProcessoreSelect the processor for the current build configuration
Toolchain di compilazione (Analisi statica)Specify the compiler that you use to build your source code for static analysis
Arrotondamento per difetto dei risultati della divisione di numeri interi negativi (-div-round-down)Specify that your compiler rounds down a negative quotient from dividing two integers (Da R2023b)
Valore di allineamento del pacchetto (-pack-alignment-value)Specify default structure packing alignment for code developed in Visual C++
Spostamento a destra su numeri interi con segno, come spostamento aritmetico (-logical-signed-right-shift)Specify that your compiler implements right shifts on signed integers as arithmetic shifts (Da R2023b)
Definizioni del preprocessore (-D)Replace macros in preprocessed code
Definizioni del preprocessore disabilitate (-U)Undefine macros in preprocessed code
Include forzati (-include)Specify files to be #include-d by every source file. (Da R2023b)
Ulteriori percorsi include (-I)Specify build-specific include paths in addition to project-wide include paths (Da R2024a)

Impostazioni ambiente

Arresto dell'analisi se un file non viene compilato (-stop-if-compile-error)Specify that a compilation error must stop the analysis
Comando/script da applicare ai file pre-elaborati (-post-preprocessing-command)Specify command or script to run on source files after preprocessing phase of analysis
Codice dal file system DOS o Windows (-dos)Consider that file paths are in MS-DOS style

Input e creazione di stub

Impostazione dei vincoli (-data-range-specifications)Constrain global variables, function inputs and return values of stubbed functions
Ignorare l'inizializzazione predefinita delle variabili globali (-no-def-init-glob)Consider global variables as uninitialized unless explicitly initialized in code
Funzioni da sostituire con stub (-functions-to-stub)Specify functions to stub during analysis
Librerie utilizzate (-library)Specify libraries that you use in your program (Da R2021a)

Multitasking

Specificare la configurazione multitasking utilizzando il fileSpecify if you want to setup multitasking configuration by using an external file. (Da R2023b)
File esterno per multitaskingSpecify which supported external file format you want to use to set up your multitasking configuration. (Da R2023b)
Configurare manualmente il multitaskingConsider that code is intended for multitasking
Attività (-entry-points)Specify functions that serve as tasks to your multitasking application
Attività cicliche (-cyclic-tasks)Specify functions that represent cyclic tasks
Interrupt (-interrupts)Specify functions that represent nonpreemptable interrupts
Disabilitazione di tutte gli interrupt (-routine-disable-interrupts -routine-enable-interrupts)Specify routines that disable and reenable interrupts.
Dettagli della sezione critica (-critical-section-begin -critical-section-end)Specify functions that begin and end critical sections
Attività temporaneamente esclusive (-temporal-exclusions-file)Specify entry point functions that cannot execute concurrently

Difetti e standard di codifica

Utilizzare file checker personalizzatiSpecify that checkers must be specified using a checkers activation XML file. (Da R2023b)
File di attivazione dei checker (-checkers-activation-file)Activate a custom combination of defects and coding rules for a Polyspace Bug Finder analysis (Da R2021a)
Utilizzare i requisiti di codice generati (-misra3-agc-mode)Check for violations of MISRA C:2012 rules and directives that apply to generated code
Utilizzare i requisiti di codice generati (-misra-c-2023-agc-mode)Check for violations of MISRA C:2023 rules and directives that apply to generated code (Da R2024a)
Calcolare le metriche del codice (-code-metrics)Compute and display code complexity metrics
Generare i risultati per le sorgenti e (-generate-results-for)Specify files on which you want analysis results
Non generare risultati per (-do-not-generate-results-for)Specify files on which you do not want analysis results

Comportamento dei checker

Tipi booleani efficaci (-boolean-types)Specify data types that coding rule checker must treat as effectively Boolean
Pragma consentiti (-allowed-pragmas)Specify pragma directives that are documented
Eseguire controlli più rigorosi considerando tutti i valori di input del sistema (-checks-using-system-input-values)Enable stricter checks and provide examples of values that lead to detected defect

Generazione di report

Generare reportSpecify whether to generate a report after the analysis
Modello di report (Code Prover o Bug Finder)Specify template for generating analysis report
Formato di output (-report-output-format)Specify output format of generated report

Impostazioni di calcolo

Limite di tempo per la verifica (-timeout)Specify a time limit on your analysis

Avanzato

Comando/script da applicare al termine della verifica del codice (-post-analysis-command)Specify command or script to be executed after analysis
AltroSpecify additional command-line flags for static analysis

Comandi di sistema

polyspace-project -diff, polyspace-project -merge(System Command) Compare and merge Polyspace Platform projects before submission to source control
polyspace-project -convert-psprj-to-workspace(System Command) Convert Polyspace project file to Polyspace Platform workspace file and project files
polyspace-project -generate-launching-script-for(System Command) Generate files needed to run static analysis on a Polyspace Platform project

Argomenti

Come iniziare

Creazione e aggiornamento del progetto

Configurazione del progetto

Controllo delle violazioni degli standard di codifica

Interfaccia utente di Polyspace Platform

Memorizzazione del file