Main Content

Artifacts and Results Generated by Polyspace Platform Projects

When you build a project, check C/C++ code for defects or run-time errors, or run tests in the Polyspace Platform user interface, Polyspace® generates artifacts, such as log files, and results. Unless you specify otherwise, Polyspace saves these files in a polyspace_artifacts folder and a results folder that are in the same location as the .psprjx project file. This topic lists the generated files and describes how to handle them when working with version control systems.

Polyspace Artifacts Folder

Parsing code or building a project with Polyspace Test™ generates log files and other artifacts in the polyspace_artifacts folder that is in the same location as the project file. To specify a different location, use the option Artifacts directory (Polyspace Test).

The artifacts folder contains subfolders with log files for parse and build actions that you perform on the project. For instance, if you parse the code and then build the project, Polyspace Test generates a parse log named PolyspaceTest_analysis_date_time and a build log named PolyspaceTest_build_date_time, where date_time is the timestamp of the action. You can access these parse and build log files from the Polyspace Platform user interface using the View logs link in the Logs pane.

Depending on the actions you perform on the project, the artifacts folder may also contain these subfolders:

  • analysis — Information created from parsing code in a project

  • codegen — Code generated from graphical tests

  • build — Build logs and artifacts generated from the build process

  • buildcov — Logs and artifacts generated from code coverage results.

  • buildexec — Logs and artifacts generated from execution time profiling results.

  • buildsan — Logs and artifacts generated from sanitizer profiling results.

  • buildstack — Logs and artifacts generated from memory use profiling results.

Polyspace Results Folder

Polyspace generates results from static analysis and dynamic testing in a results folder.

Results Folder Location

When you run static analysis or tests in a project for the first time, Polyspace creates a folder that contains all of your project results. There are two settings that determine how Polyspace stores your results:

  • The Parent results folder location setting allows you to specify the parent result folder. If you do not specify a location, Polyspace saves the results in a subfolder of the project folder named projectNameResults. Within this subfolder, Polyspace creates subfolders for each type of result:

    • Defects for Polyspace Bug Finder™ results

    • RTE for Polyspace Code Prover™ results

    • Tests for Polyspace Test results

  • If you select Keep results from all runs, Polyspace keeps results from all static analysis and testing runs. The results from each run are stored in a timestamped run_date_time subfolder within the appropriate Defects, RTE, or Tests folder.

    To save disk space and keep results from only the most recent run, clear this checkbox. When you clear this Keep results from all runs check box, Polyspace stores the results in a subfolder named run in the Defects, RTE, or Tests folder. For example, you can find the latest Polyspace Bug Finder results in: projectName/projectNameResults/Defects/run.

To view or change these settings, open the Polyspace Platform Settings and navigate to General > Folders.

The files and folders are the same whether you run the analysis from the user interface or the command line.

Results Folder Contents After Performing Static Analysis

Running static analysis on a Polyspace Platform project generates these files and folders:

  • Polyspace_release_project_date-time.log — Log file associated with each analysis. The filename includes this information:

    • release — Polyspace release version the analysis was run in.

    • project — The default value is polyspace. If you use the -prog option with the polyspace-bug-finder or polyspace-code-prover (Polyspace Code Prover) commands, project is the project name you specify.

    • date-time — Date and time the analysis was run.

    To open the log file for a static analysis result from the Polyspace Platform user interface, right-click Issues or RTE in the Results pane and select Open Run Log.

  • ps_results.psbf or ps_results.pscp — Encrypted file containing your Polyspace Bug Finder or Polyspace Code Prover results. Open this file in the Polyspace Platform user interface to view the results.

  • ps_sources.db — Non-encrypted database file listing source files and macros.

  • drs-template.xml — Template generated for specifying data range specifications (DRS). For more information, see Specify External Constraints for Polyspace Analysis.

  • ps_comments.db — Encrypted database file containing your comments and justifications.

  • comments_bak — Subfolder used to import comments between results.

  • .status and .settings — Folders that store files required to relaunch the analysis.

  • Polyspace-Doc — Folder that stores any report that Polyspace generates. Generated reports have names of the form ProjectName_ReportType. For example, a developer report in the project myProject in PDF format has the name myProject_Developer.pdf.

  • command — Folder that stores a launchingCommand script and supporting files that you can use to rerun the analysis with the same options from the command line.

Results Folder Contents After Running Tests

Running the tests in a Polyspace Platform project generates these files and folders:

  • ps_test.pstestr — Encrypted file containing your Polyspace Test results. Open this file in the Polyspace Platform user interface to view the results.

  • PolyspaceTest_run_date_time — A timestamped log file containing information about the testing and profiling run.

    To locate the log file for a test result from within the Polyspace Platform user interface, use the View logs link next to Run Logs in the Logs pane. Alternatively, in the Results pane, right-click Tests and select Show in Explorer. Then, open the log file named PolyspaceTest_run_date_time.

If you ran tests with profiling enabled, Polyspace also generates these files and folders:

  • A .psprof file — Code profiling results. Open this file in the Polyspace Platform user interface to view your results.

  • A .psprof.filter file — File containing justifications, with the same name as its associated .psprof file.

  • codecov-data-files — Subfolder that contains code profiling artifacts.

Handling Generated Files in Version Control

When submitting files to a version control system, omit the Polyspace artifacts and results. If you are using Git™, create a .gitignore file to ignore these folders of generated files.

# For Polyspace Test: Ignore the folder 'polyspace_artifacts' at any level
**/polyspace_artifacts/

# Ignore any folder starting with ‘run’ that is a child of a Defects, RTE or Tests folder
**/Defects/run*/
**/RTE/run*/
**/Tests/run*/

For more information on working with version control, see Submit Polyspace Files to Version Control.

See Also

(Polyspace Code Prover)

Topics