gtpp1m1jProgram Development Support Reference

Customizing Trace Information

The C function trace environment can be customized by using user exits.

User Exits

CP user exits are available to give C users flexibility to customize the C function trace environment, initialize storage after the user trace area storage is allocated, and insert additional trace data into the user data area. The C function trace user exits are as follows.

User Exit
Description

 CDEB 
Trace environment customization. This user exit is called only once for each ECB, when C function trace is entered for the first time. At this user exit, you can customize the C function trace environment. For example, you can use the ENATC macro to activate or deactivate C function trace breakpoints and use the SETTC macro to set C function trace table size, user area size, and additional trace options (such as STACK and STATIC).

 CEXP 
User trace area initialization. This user exit is called only once for each ECB, when a C function trace is entered for the first time. At this user exit you can initialize the contents of any C function trace user area. You must have previously issued a SETTC macro to specify a C function trace user area size so that storage can be allocated prior to calling this user exit. For example, you can issue the SETTC macro in the CDEB user exit; if activated, the CDEB user exit is called before the CEXP user exit is called.

 CTRC 
Trace user data. This user exit is used each time a C function trace breakpoint is encountered. At this user exit you can insert additional user trace data for the current trace entry.

The address of the user area is stored in the ICID_UTAA field in the CID. The user area must have been allocated previously by issuing the SETTC macro.

Note:
It is your responsibility to handle data formatting of the C function trace user area at dump time. The routine AFECTRU in CFMCC is called to format the user trace area when the breakpoints are traced. This routine simply branches back to the caller. If you have created a C function trace user area and want the C function trace user area output to be contained in a dump, you must provide code for the AFECTRU routine to format and print the C function trace user area.

See the TPF System Installation Support Reference for a complete description of these user exits.