HP Code Advisor C.02.25 User Guide (5900-1864, August 2012)

6 Generating reports
Cadvise either stores the diagnostic messages in the PDB or outputs them into the stderr. To
analyze these diagnostic messages, you can generate a report using the cadvise report command.
Cadvise report provides multiple options for filtering the diagnostic messages stored in the log
files. These reports can also be viewed and saved as HTML files. Using these options, you can
view a selected set of diagnostic messages. The cadvise reports can be generated from the following:
The PDB
Cadvise builds that use the -pdb option store the diagnostic messages in the program
database. The following command generates report from the PDB:
cadvise report <report-options> -pdb pdbdir
The log files
Cadvise builds that do not use the -pdb option, output them into stderr. You can redirect
these to a log file for later analysis. The following command generates the report from log
files:
cadvise report <report-options> logfile
6.1 Report generation options table
You can use the following options to generate reports:
Prints the summary information of all messages in the log file.“-summary” (page 28)
Prints the summary information for each source file.“-file_summary” (page 28)
Prints the summary information for each function having diagnostics
in source file.
“-func_summary” (page 28)
Prints all the messages in the log file.“-all” (page 29)
Displays the reports in HTML.“-html[=<dir>]” (page 29)
Generates the specified cadvise reports in XML format.“-xml[=<filename>]” (page 30)
Prints only those diagnostics with specified diagnostic numbers,
N1,N2..Nn.
“-diag N1,N2,N3,...,Nn (page 30)
Prints the messages with severity greater than or equal to (>=) to
N.
“-severity N” (page 31)
Suppresses diagnostics or metrics from source files that have any
of the specified strings in the filename path.
“-exclude <string1:string2:...:stringN>” (page 31)
Generates diagnostics or metrics from source files that contain the
any of the specified string in the file name path. Messages from
any other files are suppressed.
“-include <string1:string2:...:stringN>” (page 32)
Prints program complexity data for all or selected source files.“+metrics (page 32)
Print only those messages that are related to migration, such as
endian and 32-bit to 64-bit migration related diagnostics.
“-migration (page 39)
Generates report only for source files that make up the module
<name>.
“-module <name>” (page 33)
Suppresses the report header in cadvise reports.“-noheader (page 34)
Enables you to modify the severity of diagnostic DNn to SLn.“-chseverity
<DN1:SL1,DN2:SL2,...,DNn:SLn>” (page 34)
6.1 Report generation options table 27