Sun Studio 12: Fortran Programming Guide

5.1.4.2 -Xlist and its Suboptions

Combine suboptions according to the following rules:

Example: Each of these two command lines performs the same task:


demo% f95  -Xlistc  -Xlist  any.f

demo% f95 - Xlistc  any.f

The following table shows the reports generated by these basic -Xlist suboptions alone:

Table 5–1 Basic Xlist Suboptions

Generated Report  

Option  

Errors, listing, cross-reference 

–Xlist

Errors only 

–XlistE

Errors and source listing only 

–XlistL

Errors and cross-reference table only

–XlistX

Errors and call graph only

–Xlistc

The following table shows all -Xlist suboptions.

Table 5–2 Complete List of -Xlist Suboptions

Option  

Action  

–Xlist (no suboption)

Shows errors, listing, and cross-reference table 

–Xlistc

Shows call graphs and errors

Used alone, -Xlistc does not show a listing or cross-reference. It produces the call graph in a tree form, using printable characters. If some subroutines are not called from MAIN, more than one graph is shown. Each BLOCKDATA is printed separately with no connection to MAIN.

The default is not to show the call graph.

–XlistE

Shows errors

Used alone, -XlistE shows only cross-routine errors and does not show a listing or a cross-reference.

–Xlisterr[nnn]

Suppresses error nnn in the verification report

Use -Xlisterr to suppress a numbered error message from the listing or cross-reference.

For example: -Xlisterr338 suppresses error message 338. To suppress additional specific errors, use this option repeatedly. If nnn is not specified, all error messages are suppressed.

–Xlistf

Produces output faster 

Use -Xlistf to produce source file listings and a cross-checking report and to check sources without full compilation.

–Xlisth

Shows errors from cross-checking stop compilation 

With -Xlisth, compilation stops if errors are detected while cross-checking the program. In this case, the report is redirected to stdout instead of the *.lst file.

–XlistI

Lists and cross-checks include files

If -XlistI is the only suboption used, include files are shown or scanned along with the standard -Xlist output (line numbered listing, error messages, and a cross-reference table).

Listing—If the listing is not suppressed, then the include files are listed in place. Files are listed as often as they are included. The files are: Source files, #include files, INCLUDE files

Cross-Reference Table—If the cross reference table is not suppressed, the following files are all scanned while the cross reference table is generated: Source files, #include files, INCLUDE files

The default is not to show include files.

–XlistL

Shows the listing and errors

Use -XlistL to produce only a listing and a list of cross routine errors. This suboption by itself does not show a cross reference table. The default is to show the listing and cross reference table

–Xlistln

Sets page breaks 

Use -Xlistl to set the page length to something other than the default page size. For example, -Xlistl45 sets the page length to 45 lines. The default is 66.

With n=0 (-Xlistl0) this option shows listings and cross-references with no page breaks for easier on-screen viewing.

-XlistMP

(SPARC) Check consistency of OpenMP directives

Use -XlistMP to report on any inconsistencies in the OpenMP directives specified in the source code file. See also the OpenMP API User’s Guide for details.

–Xlisto name

Specify the -Xlist output report file

Use -Xlisto to specify the generated report output file. (A space between o and name is required.) With -Xlisto name, the output is to name and not to file.lst.

To display directly to the screen, use the option: -Xlisto /dev/tty

–Xlists

Suppresses unreferenced symbols from cross-reference 

Use -Xlists to suppress from the cross reference table any identifiers defined in the include files but not referenced in the source files.

This suboption has no effect if the suboption -XlistI is used.

The default is not to show the occurrences in #include or INCLUDE files.

–Xlistvn

Sets checking “strictness” level 

n is 1,2, 3, or 4. The default is 2 (–Xlistv2):

  • –Xlistv1

    Shows the cross-checked information of all names in summary form only, with no line numbers. This is the lowest level of checking strictness—syntax errors only.

  • –Xlistv2

    Shows cross-checked information with summaries and line numbers. This is the default level of checking strictness and includes argument inconsistency errors and variable usage errors.

  • –Xlistv3

    Shows cross-checking with summaries, line numbers, and common block maps. This is a high level of checking strictness and includes errors caused by incorrect usage of data types in common blocks in different subprograms.

  • –Xlistv4

    Shows cross-checking with summaries, line numbers, common block maps, and equivalence block maps. This is the strictest level of checking with maximum error detection.

–Xlistw[nnn]

Sets the width of output lines 

Use -Xlistw to set the width of the output line. For example, -Xlistw132 sets the page width to 132 columns. The default is 79.

–Xlistwar[nnn]

Suppresses warning nnn in the report

Use -Xlistwar to suppress a specific warning message from the output reports. If nnn is not specified, then all warning messages are suppressed from printing. For example, -Xlistwar338 suppresses warning message number 338. To suppress more than one, but not all warnings, use this option repeatedly.

–XlistX

Shows just the cross-reference table and errors 

-XlistX produces a cross reference table and cross routine error list but no source listing.