3 Downloads
Updated 7 Jul 2023

Polyspace Stack Flow Viewer

Polyspace Stack Flow Viewer is a Perl script showing the stack usage of a C or C++ program throughout the call tree of this program. It can be then used to help developers identify potential stack overflow issues or better understand the stack usage of C/C++ programs.

Usage

The tool will merge an export file (in tsv format) of a Polyspace® Code Prover™ results and a report in HTML format created using the report template CallHierarchy.rpt to produce an HTML file showing the stack usage using the call hierarchy of functions.

The stack usage metrics computed by Polyspace is shown by a range of the minimum and maximum stack usage. Please note that when the stack cannot be computed, a ? will be given instead.

Installation

Perl should be installed on the platform where the tool will be used.

If the script is used under Windows, first edit the script stack_flow_viewer.bat to change the value of the variable PATH_PERL, to specify the path to your Perl installation at the second line by modifying the variable PATH_PERL so it contains the absolute path to the bin folder of your Perl installation.

Under Linux, set the execution rights for stack_flow_viewer.sh:

 chmod u+x stack_flow_viewer.sh

Calling the tool

Under Windows, launch:

 stack_flow_viewer.bat <export_file> <html_report_file>

Under Linux, launch:

 ./stack_flow_viewer.sh <export_file> <html_report_file>

Example:

 stack_flow_viewer.sh Result_List_cpp.txt cpp_example.html

The tool will generate an HTML file named output.html.

License

The license for Polyspace Stack Flow Viewer is available in the LICENSE.TXT file in this GitHub repository.

Community Support

MATLAB Central

Copyright 2023 The MathWorks, Inc.

Cite As

Alexandre De Barros (2024). Polyspace Stack Flow Viewer (https://github.com/mathworks/Polyspace-Stack-Flow-Viewer/releases/tag/v1.1), GitHub. Retrieved .

MATLAB Release Compatibility
Created with R2023a
Compatible with any release
Platform Compatibility
Windows macOS Linux
Tags Add Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
1.1.0.0

See release notes for this release on GitHub: https://github.com/mathworks/Polyspace-Stack-Flow-Viewer/releases/tag/v1.1

1.0

To view or report issues in this GitHub add-on, visit the GitHub Repository.
To view or report issues in this GitHub add-on, visit the GitHub Repository.