Trace SAF API calls and times¶
SAF_TRACING
is a symbol defined in init.c.
Synopsis:
-
SAF_TRACING
¶
Description: This is a string valued environment variable used to control API call tracing in SAF. It may be set to
any one of the values described below. Note that API call tracing is logged to the same file specified
by SAF__ERROR_REPORTING
. However, if SAF__ERROR_REPORTING
is set to “none” and SAF__TRACING
is not also
“none”, SAF will log its API tracing to stderr. Currently, SAF only logs entrances to SAF API calls, not
exits.
Note: Since the bulk of SAF’s API is collective, only processor 0 actually prints any trace information.
1 | none
|
This is the default. It means that no API tracing will be generated.
1 | times
|
This setting will record the cumulative amount of time spent in saf_read_xxx
calls and saf_write_xxx
calls
as compared to the total time between calls to saf_init and saf_final. The times recorded are wall clock
seconds. Entrances to functions WILL
NOT
be reported. However, during saf_final, the cumulative timers
for time spent in reads and writes will be reported.
1 | public
|
Public API calls will be logged to whatever file SAF is also reporting errors to.
1 | public,times
|
Same as “public” but SAF will also output wall clock times since the last API call was entered. SAF
will report the delta since the last call and the absolute time, starting from 0. The times reported
are WALL
CLOCK
seconds, not CPU
seconds. Thus, if there are other activities causing SAF to run more slowly
then it will be reflected in the times SAF reports.
1 | public,private
|
Both public and private API calls are logged.
1 | public,private,times
|
Both public and private API calls are logged along with timing information.
Finally, if SAF__TRACING
is set to a valid value other than “none”, SAF will also invoke HDF5’s tracing
facilities. However, HDF5’s tracing facilities WILL
NOT
take effect unless the environment var H5_DEBUG
is
also defined in the environment. Thus, HDF5’s tracing can be turned on/off separately by setting or unsetting
the H5_DEBUG
environment variable.
See Also:
- saf_final: 4.2: Finalize access to the library
- saf_init: 4.3: Initialize the library
- Environment: Introduction for current chapter