$proc_profiling

Activate Uniface profiling, or check whether it is already enabled.

Return = $proc_profiling

$proc_profiling = Expression

set | reset  $proc_profiling

Parameters

Parameters
Parameter Data Type Description
Expression Boolean An expression that evaluates to 1 (true) or 0(false); for example, $proc_profiling = 1 to enable ProcScript tracing, or $proc_profiling = !$proc_profiling to toggle between enabling and disabling ProcScript profiling.

Return Values

The function $proc_profiling returns:

  • 1 if ProcScript profiling is currently enabled
  • 0 if ProcScript profiling is currently not enabled

Use

Allowed in all component types.

Description

Caution: ProcScript profiling has a significant impact upon performance and generates large log files. It should only be used when trying to debug a performance problem, preferably in a development or test environment.

You can enable and disable ProcScript profiling for the whole application using the $PROC_PROFILING assignment setting, or selectively in ProcScript using $proc_profiling. The ProcScript function overrides the assignment setting.

Setting ProcScript profiling in ProcScript enables you to limit ProcScript tracing to modules where you suspect a problem, but it is only feasible in a development or testing environment. Before deploying the application, you should remove ProcScript tracing commands from the application.

When profiling is enabled, profiling information is directed to the Message Frame (or message log file) as a Uniface list. You can specify a different log file using the $PROC_LOG_FILE assignment setting, and a different separator using the $PROC_PROFILING_SEPARATOR assignment setting.

For more information, see ProcScript Profiling and Tracing.

Related Topics