使用 MATLAB 脚本进行 Bug Finder 分析
使用 MATLAB® M 文件检查 C/C++ 代码中是否存在缺陷
如果您使用 MATLAB 作为脚本语言,则可以从 MATLAB 运行 Polyspace®。首先,执行一次性设置,将 Polyspace 和 MATLAB 关联起来。请参阅将 Polyspace 与 MATLAB 和 Simulink 集成。
设置完成后,您可以从 MATLAB 运行所有 Polyspace 函数。需要特别说明的是,您可以设置 polyspace.Project
对象,以运行 Polyspace 分析并将结果读取到 MATLAB 表中。
类
polyspace.Project | 对 C 和 C++ 代码运行 Polyspace 分析并查看结果 |
polyspace.GenericTargetOptions | Create a generic target configuration |
polyspace.DefectsOptions | Create custom list of defects to check |
polyspace.CodingRulesOptions | Create custom list of coding rules to check |
polyspace.BugFinderResults | 从 MATLAB 读取 Polyspace Bug Finder 结果 |
属性
polyspace.Project.Configuration Properties | Customize Polyspace analysis of handwritten code with options object properties |
函数
polyspacesetup | 将 Polyspace 安装与 Simulink 集成 |
polyspaceroot | 获取 Polyspace 安装文件夹 |
polyspaceBugFinder | 从 MATLAB 中运行 Polyspace Bug Finder 分析 |
polyspaceConfigure | Create Polyspace project from your build system at the MATLAB command line |
polyspace_report | Generate reports from Polyspace analysis results |
主题
- 将 Polyspace 与 MATLAB 和 Simulink 集成
将 Polyspace 与 MATLAB 和 Simulink® 集成,以标识模型和代码中潜在的 Bug、运行时错误以及编码标准违规。
- Get Started with Polyspace Analysis by Using MATLAB
Tutorial showing how to analyze handwritten C/C++ codes by using Polyspace from the MATLAB Command Window.
- 使用 MATLAB 脚本运行 Polyspace 分析
通过 Bug Finder 或 Code Prover 使用 M 文件检查 C/C++ 代码,在桌面端或远程服务器端本地运行分析。
- Generate MATLAB Scripts from Polyspace User Interface
Create MATLAB program files for automated runs from a project configured in the Polyspace user interface.
- Visualize Bug Finder Analysis Results in MATLAB
Generate graphs from Polyspace analysis results.
- Troubleshoot Polyspace Analysis from MATLAB
Read analysis log for errors and work around the errors.