Oracle® Solaris Studio 12.4: Overview

Exit Print View

Updated: December 2014
 
 

Code Analyzer Tool For Integrated Error Checking

    Oracle Solaris Studio Code Analyzer is a graphical tool that enables you do an integrated analysis of your code. Code Analyzer uses three types of information that you gather using other tools:

  • Static code checking, which is performed when you compile your application with the Oracle Solaris Studio C or C++ compiler and specify the –xanalyze=code option.

  • Dynamic memory access checking, which is performed when you instrument your binary with discover using the –a option, and then run the instrumented binary.

  • Code coverage checking, which is performed when you instrument your binary with uncover, run the instrumented binary, and then run Uncover with the –a option on the collected coverage data.

You can use Code Analyzer on a binary that has been prepared with any one of these tools or any combination of these tools. However, the integrated view of the three types of data offers the most revealing look into your code and enables you to create a more secure and robust application.

The following example shows how to run Code Analyzer on a binary named a.out that has been prepared previously with discover and uncover.

% code-analyzer a.out

In the following figure, Code Analyzer is displaying the issues found in the a.out binary.

image:Screen shot of Code Analyzer

For more information, see the integrated Code Analyzer help, Oracle Solaris Studio 12.4: Code Analyzer User’s Guide , and Oracle Solaris Studio 12.4: Code Analyzer Tutorial .