-qfunctrace

Category

Error checking and debugging

@PROCESS

None.

Purpose

Traces entry and exit points of procedures in your program. If your program contains C++ compilation units, this option also traces C++ catch blocks.

Syntax

Read syntax diagramSkip visual syntax diagram
   .--- -qnofunctrace--------------------------------------.   
>>-+--- -qfunctrace----+---------------------------------+-+---><
                       |          .-:------------------. |     
                       |          V                    | |     
                       '-+- + -+----+-procedure_name-+-+-'     
                         '- - -'    +-module_name----+         
                                    '-submodule_name-'         

Defaults

-qnofunctrace

Parameters

+
Instructs the compiler to trace the specified program, procedures, or module procedures. All their internal procedures are traced by default.
-
Instructs the compiler not to trace the specified program, procedures, module procedures, or any of their internal procedures.
procedure_name
The name of a program, external procedure, or module procedure. The name is case sensitive when -qmixed is in effect. BIND(C) binding labels and mangled module procedure names are allowed, but they must have the correct case. If -qextname is in effect, procedure_name is the name of the procedure without the additional underscore.
module_name
The name of a module. The name is case sensitive when -qmixed is in effect.
Fortran 2008 begins
submodule_name
The name of a submodule. The name is case sensitive when -qmixed is in effect.
Fortran 2008 ends

Usage

-qfunctrace enables tracing for all procedures in your program. -qnofunctrace disables tracing that was enabled by -qfunctrace.

The -qfunctrace+ and -qfunctrace- suboptions enable tracing for a specific list of procedures and are not affected by -qnofunctrace. The list of procedures is cumulative. When a module procedure and its containing module Fortran 2008 beginsor submoduleFortran 2008 ends are both specified, the procedure specification takes precedence.

This option inserts calls to the tracing procedures that you have defined. These procedures must be provided at the link step. For details about the interface of tracing procedures, as well as when they are called, see the Tracing procedures in your code section in the XL Fortran Optimization and Programming Guide.

Examples

The following table provides some examples of using the -qfunctrace option to achieve different purposes.

Purpose Usage example
Tracing all procedures -qfunctrace
Tracing procedures x, y, and z -qfunctrace+x:y:z
Tracing all procedures except x -qfunctrace -qfunctrace-x or -qfunctrace-x -qfunctrace
Tracing only procedures x and y -qfunctrace+x -qfunctrace+y or -qfunctrace+x -qnofunctrace -qfunctrace+y
Tracing only procedure y -qfunctrace+y -qnofunctrace or -qfunctrace+y
Tracing all the module procedures, except procedure x, in module y -qfunctrace-x -qfunctrace+y or -qfunctrace+y -qfunctrace-x

Related information